On Sep 9, 2008, at 6:10 AM, Michal Suchanek wrote: > Since you are using popen anyway you can just have your ruby process > print it's PID when it starts, and read it in your terminator. > > HTH correct. this is basically how systemu does it, which you could use similarly to this require 'thread' q = Queue.new systemu command do |pid| q.push pid end pid = q.pop this bizzare syntax will capture the pid but *also* wait for the process do start. all it's doing is reading from a pipe so your solution seems fine. cheers. a @ http://codeforpeople.com/ -- we can deny everything, except that we have the possibility of being better. simply reflect on that. h.h. the 14th dalai lama