jeffjose / tget

tget is wget for torrents
MIT License
622 stars 51 forks source link

Question: what happens when computer is shut down? #8

Open Integralist opened 5 years ago

Integralist commented 5 years ago

Heya 👋

Thanks for releasing this software, it seems to work well enough for basic requirements but one thing I was unclear on was how things were handled when the laptop has to shutdown?

I've downloaded 94% of a torrent, its seeders have since gone offline and I'll need to shut down my computer so I presume the 94% of downloaded content will be lost as the torrent itself is stored in the ephemeral /tmp directory and so any packets/chunks (not sure what the terminology is for downloading files via peer network like a torrent is) downloaded are likely to be lost also.

Is that the case or is this package able to pick up from where it left off? Is there a way to save the downloaded data before it gets lost (even if it's a manual process)?

Similarly, if I was to open a new shell and run the same tget command for the same magnet link would the next shell start from the beginning, or worse override the existing shell's progress?

Thanks for any insight you can give me.

jeffjose commented 5 years ago

I just updated the new version that might answer the first question you have, specifically what happens when you resume a download.

Say you start a download, it has completed 10%, and you stop the download by Ctrl-C. Next time you start the download (from the same directory), the progress bar will start from 10% to better reflect what is going on. If it isnt clear -- tget will resume download.

If you were to run two instances of tget, things are a little different. It is similar to asking what happens if I run two cp commands in two terminals. I'd assume, they would overwrite each other.