[Lxc-users] tail -f (inotify) not working in container?
Papp Tamas
tompos at martos.bme.hu
Tue Feb 26 20:03:12 UTC 2013
On 02/26/2013 07:36 PM, Dan Kegel wrote:
>
> Oddly, tail -f doesn't seem to be working properly inside my container.
> It displays ten lines, and then sits forever. ^C and running it again
> shows a more up to date ten lines, but then sits forever.
>
> strace shows:
> ...
> inotify_init() = 4
> inotify_add_watch(4, "err.log",
> IN_MODIFY|IN_ATTRIB|IN_DELETE_SELF|IN_MOVE_SELF) = 1
> fstat(3, {st_mode=S_IFREG|0664, st_size=380103, ...}) = 0
> read(4,
>
> This is ubuntu 12.04.1.
>
> Anyone run into this before? I see a few lxc/inotify problem reports,
> but nothing that seems related.
I had a very little bit similar problem. There was a message:
tail: inotify cannot be used, reverting to polling: Too many open files
And actually it worked.
I increased the value of /proc/sys/fs/inotify/max_user_watches.
You may have similar issue.
tamas
More information about the lxc-users
mailing list