On Thursday 23,August,2012 03:34 PM, Bob Proulx wrote: > lina wrote: >> Once I used the wget to download one file from debian repository, on >> another terminal I with to use the wget to get another file at the same >> time from the same repository. > > And if you needed both files then that seems fine to me. > >> I was discouraged to do that, and was also told that, two wget >> downloading would deduce the downloading speed, I should have waited one >> finished before download another one. > > *Should* is too strong. It doesn't hurt anything to download two > files at the same time. Or three. A hundred is probably too many > though. But really there isn't any difference in the overall results > >> It's happened two years ago, but I still remembered that suggestions. >> Even later in my life I still download two or more at the same time. > > Sure. I often have multiple things happening at the same time. It is > why I use a multitasking operating system. > >> Here my question is that, is it true that open two wget will affect the >> downloading speed? better one by one, just suspect it. > > Let's assume you have a 1.0 Mbit/s download connection. Because it > makes the math easier. And assume you need a 1.0 Mbyte file. With no > other overhead it will take aproximately 10 seconds to download. > > Now let's assume that you download two of those files at the same > time. You still only have 1.0Mbit/s download speed. But now you are > downloading 2.0Mbytes of data in total. Obviously the total download > will take aproximately 20 seconds to download. > > If you ran them sequentually then the first one would finish in 10 > seconds and then the second one would start and it would finish 10 > seconds later. So it would take 20 seconds in total for both to > download both of those files. > > If you ran them both at the same time then neither would be able to > get the full 1.0Mbit/s download speed. It should balance out between > them and each would get about 0.5Mbit/s download speed. Which would > double the amount of time each would take. Each would take about 20 > seconds to download those files but both are running at the same > time. So once again it would take 20 seconds in total for both to > download those files. No difference! > > Now if you needed *one* of those files first then you would download > it first and not start any of the others until you had what you needed > first. You would prioritize. You would get the high priority items > first. Because then in 10 seconds you would have something you needed > first. You would hold off the lower priority items that could wait to > get the ones that you wanted soonest. > > Hopefully all of that makes sense and enables you to do whatever makes > the most sense at that moment in time. If the bottleneck in speed is > your local network connection to the Internet then you would whatever > you wanted to make your task easiest. > > Now here is a twist. This is a obtuse thing but useful to know about. > If the bottleneck is competition with other people then the situation > is different. Let's say you are working at a small business or school > or coffee shop along with nine other people for ten total people > downloading things. There is still a 1.0Mbit/s download capacity. > But now ten people are using it. So you are only getting 0.1Mbit/s > download speed. Getting that 1.0Mbyte file now takes 100 seconds > instead of 10 seconds. Because nine others, all ten of you in total, > are all downloading all at the same time and the system is sharing the > bandwidth across all of you. So now it takes 100 seconds. > > Now here is the twist. If you can split that file up into nine parts > and then start nine downloads in parallel you will get the total > 1Mbyte file downloaded in 50 seconds. That is now twice as fast as > the 100 second case! The system doesn't know about users. The system > knows about download connections. If you have nine downloads going at > once but your nine other coworkers each have one that is 18 total > downloads going at once. The system will share the bandwidth across > all 18 of those. But 9 of those are yours and 9 belong to the rest of > your coworkers. So you are getting half of the available bandwidth > and starving your coworkers out of their fair share. > > Better if you split the file into 27 parts and ran 27 downloads in > parallel then you would have 27 and your coworkers would have 9 and > you would have 27/(27+9)=3/4 of the bandwidth and they would have > 9/(27+9)=1/4 of the bandwidth. You would be able to download a > 10Mbyte file in 13.3 seconds. The system divides bandwidth up between > the connections so if you have more connections then you get more > bandwidth. You could keep going with this but at some point the > overhead prevents further progress. This is what some file download > manager programs do. This is part of what makes bittorrent so > effective. > > Meanwhile your coworkers might be a little bit upset that you were > starving them out. In response they might start doing the same thing > and running a parallel download manager. This becomes an "arms race" > with all sides trying to get more than their fair share at the expense > of others. Now if everyone in your group all did the same thing then > the result is that you would be right back where you started before, > with 1/10 of the bandwidth of the ten of you in the group. > > I hope this was interesting and useful.
Indeed, very interesting explaination, and now I start to understand why some "download manager" software are banned here. Thanks Bob for your time. Best regards, > > Bob -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/5035df79.7080...@gmail.com