Multiplay Labs

tech hits and tips from Multiplay

Archive for September, 2015

When tail -f doesn’t on FreeBSD

without comments

So when you’re debugging a problem and using tail -f my.log the last thing you expect to find is the debugging you’re looking for simply isn’t there.

Well that’s what I had today and it turned out that tail -f wasn’t working!

After much digging I found that kqueue write events would never fire for files > 2GB due to use of int for file offset comparison in event checking code.

This was introduced by introduction EVFILT_VNODE for all filesystems over 10 years ago by r147198

I fixed it with r287886 but it was definitely one of those WTF moments when I first discovered tail -f was the cause of my debugging info not being displayed.

Written by Dilbert

September 17th, 2015 at 2:08 am

Posted in FreeBSD