bash - SSH doesnt exit from command line -


I run a shell script on another server and thus a shell script nohup ./script.sh 1 & Gt; / Dev / zero2> 2 & Amp; 1 & amp;

Then type exit to exit the server even though it is just hanging. Server is Solaris.

How can I get rid of hanging properly?

Thank you.

I think this script has been running for a long time. In this case, you will have to separate the process from the terminal which you want to stop while terminating your SSH session.

Actually you have already done the work by handing both stdout and stderr to / dev / null , But you do not do this for stdin

The case of I used the test:

SH localhost Noah sleep 10m & amp; gt; / Dev / null & amp; ^ D # Bracket

While

  SH localhost nyupup sleep 10m & gt; / Dev / null & lt; / Dev / null & amp; ^ D # Exit  

I recommend using the excellent gnu screen which will make this service available to you.

Oh, and do you have to run the script directly and do not think within a shell? I.e .:

ssh user @ host script.sh

Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -