Closed ZZromanZZ closed 8 years ago
@ZZromanZZ how many files do you sync? What about the size? @mickaelperrin do you have an idea here, ho to extend that?
We have to implement the way to increase the inotify limit for fswatch as I did with unison.
If you want to resolve it manually:
sudo sysctl -w kern.maxfilesperproc=NBFILES
sudo sysctl -w kern.maxfiles=NBFILES
However I ran ulimit -n
in the same process of starting the unison watcher. Maybe the above commands will be sufficient. If not, we will need to patch to add the ulimit -n NBFILE && fswatch ...
in docker-sync.
Mmmm, but wait... which version of docker-sync are you using ? In your config you have unison
but you are talking about fswatch
.
If you are using the latest docker-sync
, there is a simple max_inotify_watches
to add in the docker-config.yml file. See https://github.com/EugenMayer/docker-sync/blob/c4e9f21bc4c6510e8186e25765a1f786e31ad470/example/docker-sync.yml#L75
I set max_inotify_watches
and it works as expected.
I am sorry for unnecessary issue.
@ZZromanZZ great it worked, thanks @mickaelperrin for the hint!
I haven't noticed performance degradation.
sudo su -c 'echo 262144 > /proc/sys/fs/inotify/max_user_watches'
Hi, currently I'm dealing with problem with fswatch:
Fatal error: Server: Filesystem watcher error: cannot add a watcher: system limit reached
Increasing ulimit (-n and -u) in host system does not work.
Environment: Docker Toolbox (Virtualbox) OS X Yosemite 10.10.5 Docker-sync: current master branch (cd70ac6)
Docker-sync.yml: