User not logged in - login - register
Home Calendar Books School Tool Photo Gallery Message Boards Users Statistics Advertise Site Info
go to bottom | |
 Message Boards » » SSH and Unix question Page [1]  
Novicane
All American
15413 Posts
user info
edit post

Suppose i SSH into a sever and run a process.

How can I keep this process running after I log out of SSH?

10/3/2007 4:21:57 PM

joe17669
All American
22728 Posts
user info
edit post

i think it depends on the process

you can try adding an & after the command and that will put it in the background. I dunno if it will stay open or not when you close out of SSH

10/3/2007 4:24:59 PM

YOMAMA
Suspended
6218 Posts
user info
edit post

use "SCREEN"

10/3/2007 4:38:44 PM

MiGZ
All American
2314 Posts
user info
edit post

the process will die immediately when you log out, even if you put it in the background via &

Issue a nohup command and it will run until completion regardless of whether you log out or not.



nohup process_name.ksh &

10/3/2007 4:41:33 PM

Novicane
All American
15413 Posts
user info
edit post

got it

had to put the directory

nohup ./process&

no space with ambersand.

10/3/2007 5:14:18 PM

mellocj
All American
1872 Posts
user info
edit post

you can also use screen.

type "screen". then you will be in a shell, start the process. then type CTRL-A + D (hold down control, hit A, then release both and hit D) to detach. then you can login later and type CTRL-A + R to reattach

10/3/2007 9:55:14 PM

skokiaan
All American
26447 Posts
user info
edit post

nohup ftw

10/3/2007 11:04:09 PM

smoothcrim
Universal Magnetic!
18955 Posts
user info
edit post

Quote :
"use "SCREEN""

screen is badass

10/4/2007 12:47:01 AM

 Message Boards » Tech Talk » SSH and Unix question Page [1]  
go to top | |
Admin Options : move topic | lock topic

© 2024 by The Wolf Web - All Rights Reserved.
The material located at this site is not endorsed, sponsored or provided by or on behalf of North Carolina State University.
Powered by CrazyWeb v2.38 - our disclaimer.