From: geo ssscripting Date: 2009-09-08T01:58:24+09:00 Subject: Re: Executing system commands in threads under Ruby 1.8.6 Here's the rewrite using IO.popen: threads = [] (1..254).each do |i| puts "pinging #{i}" threads << Thread.new { content = "" IO.popen("ping 192.168.0.#{i}") do |io| io.each { |l| content << l } end content } end threads.each do |t| t.join puts t.value end This doesn't behave different. My Ruby -v outputs this : ruby 1.8.6 (2008-08-11 patchlevel 287) [i386-mswin32] I'm running Windows XP. -- Posted via http://www.ruby-forum.com/.