OpenWrt Forum Archive

Topic: Best download method?

The content of this topic has been archived on 4 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I wanted to use my router to download some random files (no torrents or dcc) so i connected using ssh and
used wget to start downloading. But when i disconnected my ssh session, the download was aborted also.
I guess this is because my session is closed. Is there a workaround for this?
Any other download methods or sugesstions are welcome.

Thanks a lot!

Cypher wrote:

or without "screen":
wget --example http://examplehost.com/example.dat > /dev/null 2>&1 &

Thanks! This works great.
I don't understand this magic: > /dev/null 2>&1 & can you explain this?
I do get /dev/null but not the > and 2>&1 &
Thanks again.

(Last edited by mrx on 15 Jun 2008, 12:21)

Hi,
on Linux systems

 
> /dev/null

redirects the standard output messages of a command to null and

 
2>&1

redirects the standard error messages to the standard output.

So if you use both, all your output of the command will be disabled


Cypher wrote:

or without "screen":
wget --example http://examplehost.com/example.dat > /dev/null 2>&1 &

Are you sure this works ? In my opinion, a command running in backgroud will not survive if you close the ssh session.

Tex

Thanks for the explanation!

I started to download a cd image that way and after closing my ssh connection and reconnecting the download was still running.
So this seems to work yes.

Tex-Twil wrote:
Cypher wrote:

or without "screen":
wget --example http://examplehost.com/example.dat > /dev/null 2>&1 &

Are you sure this works ? In my opinion, a command running in backgroud will not survive if you close the ssh session.

I use this with kismet_server and its running after closing the SSH session. wink

The discussion might have continued from here.