From: Brian Candler Date: 2009-08-27T00:01:06+09:00 Subject: Re: Global Mutex? Aryk Grosz wrote: > Is there any thing in ruby that acts as a global mutex? Between multiple processes on the same machine: I'd suggest using File#flock on a local file (this probably won't work over NFS) with File::LOCK_EX. You can include File::LOCK_NB if you want to test the lock but not block if someone else has it. Between multiple processes on multiple machines: probably run a DRb server one one machine which has a local mutex and yields back to the caller. -- Posted via http://www.ruby-forum.com/.