LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 10-16-2001, 11:11 AM   #1
Steave
Member
 
Registered: Jul 2001
Location: Braunschweig, Germany
Distribution: Suse 7.2
Posts: 184

Rep: Reputation: 30
Question ftp-download as background process?


Hi everybody!

Does anyone know a way to achieve the following:

I want to download a file from a friends computer. Since this will take somewhat longer I wondered if I could just tell my router to download the file, so my workstation doesn't need to run.
The only way I can work on the router is with ssh. So I can't just open an ftp-session and let it run forever, since it will be killed when I shut down my workstation and as such the ssh-session is stopped. I would need to have it run nohup. But then I can't do all the interactive input like loggin in and requesting the file by hand.
How do I automate this?

Thanx in advance! Steave.
 
Old 10-16-2001, 03:06 PM   #2
webtoe
Member
 
Registered: Apr 2001
Location: Cambridge, England
Distribution: Slackware 10, Fedora Core 3, Mac OS X
Posts: 617

Rep: Reputation: 30
Question search

have you searched the forum?
im sure that there has been tons of these sort of questions asked before (keeping a program alive from a telnet/ssh prompt after logging off)

Alex
 
Old 10-17-2001, 02:59 AM   #3
lensmanseye
LQ Newbie
 
Registered: May 2001
Posts: 2

Rep: Reputation: 0
The wget program (which is included in the Mandrake distro, so I would imagine comes with the SuSE one) is a wonderful download program.

It handles ftp and http programs and can be left in the background while it does it stuff. Furthermore, if you have it as a foreground activity when your ssh-session is terminated (say by an overzealous ISP), the download will carry on until it gets all of it.

The program can also handle recursive downloads as well.

The only problem is that, for non-anonymous ftp access, it does require your username and password to be passed to the command prompt.
 
Old 10-17-2001, 04:58 AM   #4
dorward
Member
 
Registered: Sep 2001
Distribution: Gentoo
Posts: 760

Rep: Reputation: 31
Use Screen!

Use screen (man screen)

Code:
ssh ...
screen
ftp ...
Ctrl+A, Ctrl+D
exit
Then at a later stage

Code:
ssh ...
screen -x
and you should find your session with the ftp client still running (assuming that the download didn't finish a while ago and the remote server closed the connection, in which case you will have the file available to scp).
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
really background a process Henster Linux - Newbie 1 07-01-2005 05:29 AM
how to run any binary in background - background process tej Linux - Newbie 1 08-16-2004 12:27 AM
Background Process mojozoox Linux - General 1 08-26-2003 02:16 PM
Background process h8r Linux - Newbie 5 01-13-2003 04:21 PM
background process gurra Programming 9 09-30-2001 01:31 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 02:57 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration