Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Listener doesn't recognize changes on samba share since v1.0 #125

Closed
mkoentopf opened this issue Jun 19, 2013 · 17 comments
Closed

Listener doesn't recognize changes on samba share since v1.0 #125

mkoentopf opened this issue Jun 19, 2013 · 17 comments
Milestone

Comments

@mkoentopf
Copy link

Hi there,
I've a setting on a linux node with mounted samba shares (from windows).
I use listen to watch for new files in a hot folder (on the samba share).
Until the version 0.7.3 there was no problem. Since version 1.0.0 it doesn't work.
Tests with local folders on the node were successful, with a samba share folder not.
Any ideas?

Thx, Matthias

@thibaudgg
Copy link
Member

rb-inotify has been included after 0.7.3 and is now automatically used, maybe you need to force_polling to make it works with samba.

@mkoentopf
Copy link
Author

I've tried it with :force_polling => true. No success.

@thibaudgg
Copy link
Member

Mmm, I don't see what could have cause that. The logic have mostly stay the same between 0.7.3 and 1.0.0.

Maybe you could already try with the completely rewritten v2.0 branch, it's only works with polling at the moment and the DSL has been a little bit simplified but example.rb should work.

@mkoentopf
Copy link
Author

Cool. I'll try v2.0 when I'm back from my holidays.
I'll let you know.
Thanks for your help,
Matthias

@webwurst
Copy link

Polling does work for me on a samba-share with v2.0.
When will the linux-adapter be ready for using on that branch?

@thibaudgg
Copy link
Member

@webwurst great news, linux/os x adapter are next on my list, so it should be soon (1-2 weeks).

@webwurst
Copy link

Cool! 👍

When watching several hundred files polling does not work well.
It seems not to react at all, although cpu-usage ist constantly quiet high.

Is it possible to get some debug-infos to see what's going on?

Will be happy to test the linux-adapter :)

@thibaudgg
Copy link
Member

@webwurst polling could be quite cpu-intensive with a lot of files, try to ignore some path if possible. There is no debug info implemented at the moment, PR is welcome!
I'll start darwin=adapter now, I'll ping you when linux-adapter is ready to be tested.

@thibaudgg
Copy link
Member

@webwurst just update v2.0 branch with first version of linux-adapter, could you give it a try please? There's still some issues on jruby & rbx https://travis-ci.org/guard/listen be warned!

@webwurst
Copy link

webwurst commented Jul 1, 2013

@thibaudgg thx!
Works fine for me so far 👍

I noticed one thing: Whenever i stop the listener via ctrl+c it gives me Couldn't cleanly terminate all actors in 10 seconds!.
Even if nothing has happened on the file-system.

@thibaudgg
Copy link
Member

Yeah, I need to take care of stopping cleanly Celluloid actor.

@mkoentopf
Copy link
Author

I've tested the v2.0 branch of listen with (and without) a samba share on a linux node.
The good news is: They behave the same with or without the samba share.
With force_polling it is a little bit strange. If I touch a new file it's ok, but if I use echo 'bla' > test.txt I've got double messages with this code : l = Listen.to('/home/test', :force_polling => true){ |modified, added, removed| puts "modified #{modified.inspect}"; puts "added #{added.inspect}";} l.start.
The linux adapter crashes if stop the listener and if I add a new file both fields modified and added are filled.

@thibaudgg
Copy link
Member

@mkoentopf which ruby are you using?

@mkoentopf
Copy link
Author

Hi, I'm using ruby-1.9.3-p429

@thibaudgg
Copy link
Member

interesting because spec pass on that platform for file addition on travis

as you can see it's still a work in progress, thanks for your feedback!

@mkoentopf
Copy link
Author

Yes, the test with touch is working, but if I do this: echo 'bla' > test.txt, then I've got a double message.

@thibaudgg
Copy link
Member

Nice, I'll add a spec and fix that. Thanks!

thibaudgg added a commit that referenced this issue Sep 8, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants