1

I am facing problem in executing a command Using SSH.

my req: 1. open a ssh connection using IP (example: 125.230.200.80)

Login ssh [Documentation] Connecting to SSH and login close all connections open connection ${SSH_IP} port=22 timeout=10 login ${USERNAME} ${PASSWORD} delay=10 seconds

  1. I want to execute a command in a particular directory of that server. Directory: /export/home/IKBAL/Simulator Command: ./send 1 1 hostsocket S I have used below comamnd EXECUTE COMMAND /export/home/IKBAL/Simulator/./send 1 1 hostsocket S

    How can i view the full command output or store the command output in a file ?

1 Answers1

0

What you're looking for is the returned value of Execute Command, e.g. with this construct:

${output}=    Execute Command    /export/home/IKBAL/Simulator/./send 1 1 hostsocket S

, ${output}'s value will be the standard output of the send command. Then you can work with it as any normal Robotframework variable.

Todor Minakov
  • 19,097
  • 3
  • 55
  • 60