remote login using Linux

April 14, 2013 at 19:25:32
Specs: Linux
I've this problem using the soft-keys of the program if I use the script file i created.

The script file:

#! /bin/bash

xhost +
ssh hostname
read -e password
export DISPLAY=hostname:0;
/usr/program/program.sh 3 hostname;

The above command is the same if I open a Terminal and key the above command, I'll be able to use the soft-keys (eg F1 - password, etc) of the software "program"

But, if I use the shell script above, I'm not able to use the software soft-keys I've pre-defined.

Any help?


See More: remote login using Linux

Report •

#1
April 21, 2013 at 22:30:15
I'm not sure I understand what your script is doing. You turn off access control, run SSH, do something you haven't put in your script, logout, then store user input in the variable password you don't do anything with, then export a variable on your host, and then run some other script on your host computer.

I think your problem is that you need to use expect.


Report •

#2
May 7, 2013 at 00:25:49
Function of the script:

To remotely login to another PC and open a program, the function key was defined in the program, but i can't use it after executing the script above.

Any help?


Report •
Related Solutions


Ask Question