Hi Can anyone help me on ssh .. i want a script to run ssh when system restart/reboot but it should run in back ground. i dnt want any terminal. i just want generate port via ssh. For log in i will use ssh keys.
thanks Sameed
On Tue, Apr 13, 2010 at 10:37 PM, Sameed Ahmed sameed@ymail.com wrote:
Hi Can anyone help me on ssh .. i want a script to run ssh when system restart/reboot but it should run in back ground. i dnt want any terminal. i just want generate port via ssh. For log in i will use ssh keys.
I am not sure what exactly you want to do. But from what I understand, you could start screen in the background and run ssh inside that. You can then attach that screen session to your terminal whenever you want to use it. I had done something similar with rtorrent some time ago. See http://mehulved.wordpress.com/2008/07/16/start-rtorrent-using-init-scripts/
Put That in the Directory "/etc/init.d/" First create a shell script in the same dir that backgrounds the process name is "name.sh"...in shell file do the following... #!/bin/bash ./aaa & # Assuimg that ur script name is 'aaa' save it and make this file executable... and run the following # update-rc.d name.sh defaults PS: There are many more other ways...
On Tue, Apr 13, 2010 at 10:37 PM, Sameed Ahmed sameed@ymail.com wrote:
Hi Can anyone help me on ssh .. i want a script to run ssh when system restart/reboot but it should run in back ground. i dnt want any terminal. i just want generate port via ssh. For log in i will use ssh keys.
thanks Sameed