vagrant-notify-forwarder icon indicating copy to clipboard operation
vagrant-notify-forwarder copied to clipboard

Notification forwarding not working, getting error message after vagrant up

Open googol opened this issue 9 years ago • 5 comments

I'm getting the following error message right after booting the vagrant box with vagrant up:

terminate called after throwing an instance of 'std::runtime_error'
  what():  Could not add watch

Any ideas what could be causing this? Or how to investigate?

I'm currently running Ubuntu 14.04 on both the host and the guest, vagrant 1.7.4.

googol avatar Mar 17 '16 22:03 googol

Thanks to #7, this might be solved if you were using either relative or ~ paths. Could you please upgrade to 0.4.0 and try again?

mhallin avatar May 06 '16 18:05 mhallin

This is working for me now for the most part. The only issue I'm having is editing with vim. If I have nodemon running on the host, all saves will trigger an update, but if nodemon is inside a vagrant box it only triggers when I save and exit (:wq). Other things seem to trigger always, like git checkout etc. So not sure where the problem lies with this latest problem

googol avatar May 26 '16 18:05 googol

I am on Ubuntu 16.10 and vagrant 1.8.5 with notify-forwarder version 0.5.0 and I am still getting this. Is there a problem with multiple synced folder?

Here is a my config:

Vagrant.configure(2) do |config|
  config.vm.box_url = "https://personalcloud.net/s/kmd5bHdjakdKAxQ0/download"
  config.vm.box = "ubuntu1604"
  config.vm.hostname = "dev.project.local"

  config.vm.network "forwarded_port", guest: 8000, host: 8000, auto_correct: true

  config.vm.network "private_network", ip: "192.168.68.63"
  config.ssh.forward_agent = true

  config.vm.synced_folder "/home/daniel/workspace/projects/project/", "/home/vagrant/project/"
  config.vm.synced_folder "/home/daniel/workspace/core", "/home/vagrant/project/"

  config.vm.provider "virtualbox" do |vb|
      vb.memory = "4096"
  end
  config.vm.provision "file", source: "~/.ssh/id_rsa.pub", destination: "~/.ssh/me.pub"
end

dada-engineer avatar Nov 17 '16 07:11 dada-engineer

For those who are facing the same issue, you may need to increase your maximum number of watches. See man inotify ; /max_user_watches for more information.

gilbsgilbs avatar Nov 20 '17 16:11 gilbsgilbs

Same issue with /proc/sys/fs/inotify/max_user_watches = 524288...

Shared folder mounted as nfs:

  config.vm.synced_folder ".", "/vagrant", type: "nfs",
    mount_options: ["rw", "vers=3", "tcp"],
    linux__nfs_options: ["rw", "no_subtree_check", "all_squash", "async"]

mightydes avatar Jun 09 '18 10:06 mightydes