From: 90kts Date: 2008-07-28T17:44:42+09:00 Subject: Re: net-ssh and remote shell Your code example works with net-shh 1.1.2 but not 2.0.3 For this sort of thing I prefer to use the .exec method and store all output in an array: require 'rubygems' require 'needle' require 'net/ssh' session=Net::SSH.start("localhost", "90kts", :password=>"**************") cmd = 'ls -lart' out = [] out = session.exec!(cmd).split(/\n/) puts out Hope that helps =)