LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-01-2004, 02:46 PM   #1
abboq
LQ Newbie
 
Registered: Sep 2003
Posts: 2

Rep: Reputation: 0
Keeping a process running after shell logout


Is it possible to start a process and keep it running even after logging out of a remote shell? I'd like to login remotely, start an FTP download onto the machine, and then log out remotely, with the file transfer continuing. Is there a way to do this?

Thanks for any help you can provide.
 
Old 09-01-2004, 03:00 PM   #2
keegan
Member
 
Registered: Jan 2004
Distribution: Redhat WS and VectorLinux
Posts: 41

Rep: Reputation: 15
Im not sure if screen works with ftp, but, for example, if you wanted to run a python script called 'myscript.py' you would use:

screen python myscript.py

it would run, the once you want to logout, use

ctrl+a ctrl+d

to get out of it.

man screen
 
Old 09-01-2004, 03:03 PM   #3
mikedeatworld
Member
 
Registered: Nov 2003
Location: Farmington Michigan
Distribution: UBUNTU - Slackware - SuSE 9.1 - Knoppix - Fedora
Posts: 828

Rep: Reputation: 30
Try

"command"& --without quotes
 
Old 09-01-2004, 03:28 PM   #4
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
The & will put it into the background, but it still dies when you log out, to stop that, use:

nohup <command> &

This will put the process in the background and tell it to ignore the terminal hangup when you log out.
 
Old 09-01-2004, 04:16 PM   #5
Salpula
Member
 
Registered: Feb 2004
Location: Philadelphia, PA
Distribution: FC3 i386 & PPC
Posts: 36

Rep: Reputation: 15
Lightbulb Try this

I THINK that if you put an ampersand (&) at the end it puts it in the background, so you can at least continue using the shell while its running, I am not positive if it will continue to run in the background after you log out.

EDIT: I should have refreshed the thread before replying. . .

Last edited by Salpula; 09-01-2004 at 04:19 PM.
 
Old 09-01-2004, 05:58 PM   #6
mikedeatworld
Member
 
Registered: Nov 2003
Location: Farmington Michigan
Distribution: UBUNTU - Slackware - SuSE 9.1 - Knoppix - Fedora
Posts: 828

Rep: Reputation: 30
true...my bad
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
HELP: running process in bg and logout and persist... woes :S kevingpo Fedora 1 09-09-2005 01:10 AM
running in background hangs on shell logout pfaendtner Linux - Newbie 5 03-25-2005 10:34 AM
Keeping a process running after disconnect steyr Linux - General 2 02-25-2004 06:03 AM
keeping volume settings on logout rdanda Slackware 1 04-12-2003 02:32 PM
How to determine whether a PROCESS is running, by a SHELL program? yuzuohong Linux - General 4 01-21-2003 08:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:18 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration