Hi

I have a setup where i have to send command to linux boxes.

I installed Ruby 1.9.2 and latest version of needle, net-sftp and net-
ssh.

routine is like --

def issueCommandInOKBox(okMachine="", command="", expectedLog="",
expectedResult="PASS", user="k1", passwd="1")
    puts "    issueCommandInOKBox: okMachine=#{okMachine}"
    puts "    issueCommandInOKBox: command=#{command}"
    puts "    issueCommandInOKBox: expectedLog=#{expectedLog}"
    puts "    issueCommandInOKBox: expectedResult=#{expectedResult}"
    puts "    issueCommandInOKBox: user=#{user}"
    puts "    issueCommandInOKBox: passwd=#{passwd}"

    returnValue = true
    Net::SSH.start( okMachine, user, passwd, :paranoid => false) do |
session|

    shell = session.shell.sync
    puts "    Should print home directory:"
    out = shell.pwd
        p out.stdout

    puts "    Should print response logs after executing commmand:"

    out = shell.send_command command
        p out.stdout
    $outputofissueCommandInOKBox = out.stdout
    #puts "------- #{out.stdout}"
    $_ = out.stdout



This is working fine when i have Ruby 1.8 and watir 1.6.5 with needle
1.1.0 and other netssh and netsftp.

But now when i upgraded, this fails.

I can do ssh using putty to these boxes, but through script it is
fialing.

Any help how i  can have this working?

Bhavesh

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

Reply via email to