本文发表在 rolia.net 枫下论坛----------------------------------------------------------------------
eagle_no1's comments:
I launched the process , loop , which runs forever untill it's killed.
and made it runing on background with command cntl-z; bg
on one terminal
----------------------------------------------------------------------
and do following steps the another terminal:
[s@localhost s]$ ps -aef | grep loop
s 2217 2191 0 19:12 pts/2 00:00:00 ./loop
s 2219 2111 0 19:13 pts/1 00:00:00 grep loop
[s@localhost s]$ nohup "2217"
nohup: appending output to `nohup.out'
[s@localhost s]$ ps -aef | grep loop
s 2217 2191 0 19:12 pts/2 00:00:00 ./loop
s 2223 2111 0 19:13 pts/1 00:00:00 grep loop
-----------------------------------------------------------------------
eagle_no1's comments:
here I close the terminal on which I launched the process loop and do follow step
on this terminal;
please notice the parrent's ID and tty name of process loop.
it's still there!!
------------------------------------------------------------------------
[s@localhost s]$ ps -aef | grep loop
s 2217 1 0 19:12 ? 00:00:00 ./loop
s 2225 2111 0 19:13 pts/1 00:00:00 grep loop更多精彩文章及讨论,请光临枫下论坛 rolia.net
eagle_no1's comments:
I launched the process , loop , which runs forever untill it's killed.
and made it runing on background with command cntl-z; bg
on one terminal
----------------------------------------------------------------------
and do following steps the another terminal:
[s@localhost s]$ ps -aef | grep loop
s 2217 2191 0 19:12 pts/2 00:00:00 ./loop
s 2219 2111 0 19:13 pts/1 00:00:00 grep loop
[s@localhost s]$ nohup "2217"
nohup: appending output to `nohup.out'
[s@localhost s]$ ps -aef | grep loop
s 2217 2191 0 19:12 pts/2 00:00:00 ./loop
s 2223 2111 0 19:13 pts/1 00:00:00 grep loop
-----------------------------------------------------------------------
eagle_no1's comments:
here I close the terminal on which I launched the process loop and do follow step
on this terminal;
please notice the parrent's ID and tty name of process loop.
it's still there!!
------------------------------------------------------------------------
[s@localhost s]$ ps -aef | grep loop
s 2217 1 0 19:12 ? 00:00:00 ./loop
s 2225 2111 0 19:13 pts/1 00:00:00 grep loop更多精彩文章及讨论,请光临枫下论坛 rolia.net