Wikipedia:Reference desk/Archives/Computing/2011 April 22

Computing desk
< April 21 << Mar | April | May >> April 23 >
Welcome to the Wikipedia Computing Reference Desk Archives
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


April 22 edit

Shared internet connection bandwidth management problem edit

I live in a residence with 8 other members all sharing one unreliable, low-bandwidth internet connection (either 512 kbps or 1024 kbps down, uplink unknown). We all are constantly downloading videos and music which saturates the internet connection and causes latency to skyrocket, and interactive tasks like ssh or loading a web page timeout or take forever (several minutes per page load). Besides changing our behavior or getting faster interent service, what solutions are there to throttle/shape/manage the traffic so the internet connection quality remains "usable" for everyone?

I’m thinking about something I can load on a Linux based box with two Ethernet ports that sits between the cable modem and router+switch. I need to find a solution that requires no effort on the users’ part (such as reconfiguring their computers/software) other than some kind of initial device registration on the network, and so forth. Condensation333 (talk) 02:58, 22 April 2011 (UTC)[reply]

From your description it sounds like you are exceeding the total capacity of your connection, so no software fix is possible. I suggest you limit each person to a scheduled half hour of downloads per day. That should make the network unusable for anything else for only 4 hours day. Outside that time, if should be usable by all (except for downloading, of course). StuRat (talk) 05:44, 22 April 2011 (UTC)[reply]
Obviously there are software solutions to managing bandwidth and quality of service. Like I said I'm trying to find a solution that doesn't rely on users (and the politics required) to actually do anything on their end. There must be a slew of linux router distros, but doing research via google on a 2500 ms latency internet connection is one of the ultimate tests of patience. Condensation333 (talk) 06:20, 22 April 2011 (UTC)[reply]
I think you're talking about giving mass downloads a lower priority than, say, loading (small) web pages or sending (small) e-mails. That could help, but only if your total daily capacity is far more than you are using, and it doesn't sound like this is the case. This would delay the mass downloads until there's no other traffic, which is essentially doing what I suggested before, but would have the added annoyance of having downloads start and stop, potentially for hours. StuRat (talk) 06:47, 22 April 2011 (UTC)[reply]
I'm thinking I want to give each current user a slice of total bandwidth. Two current users get it split 50%/50%, 5 get it split into fifths. So I guess a dynamic cap of sorts. That way users are evenly throttled instead of all competing for max available bandwidth and saturating the connection, driving latency through the roof. Now, in conjunction with that, it would be nice to prioritize/throttle bulk transfers like bittorrent, iTunes, large http downloads, etc. to basically halt or trickle when someone hops on and browses the web or uses ssh or anything else interactive. When it already takes days to download anything large, having it delayed a few extra hours isn't even noticeable. It would be easy to identify users by IP, but I don't know what software to use to easily shape traffic like I want to. Condensation333 (talk) 07:39, 22 April 2011 (UTC)[reply]
Your first option would likely make things even worse. This is a form of hoarding, meaning keeping an excess of a scarce resource, even when you don't immediately need it yourself. In your example, if there were 5 people online, 4 of whom were doing minor things, say taking up only 10% of the bandwidth in total, this means that the 5th person doing a download would be restricted to 20% of the bandwidth, instead of the 90% that's available, slowing him to a crawl. The other 70% of the bandwidth would be wasted. This is an attribute of hoarding, it leads to inefficient distribution of resources. The prioritization scheme might help, but probably not enough to solve the problem. Also, I should ask, have you considered upgrading your Internet service ? For an extra few dollars a month each, you could probably solve the problem that way. StuRat (talk) 08:10, 22 April 2011 (UTC)[reply]
I'm with StuRat, if there's 8 of you, the cost per person of getting a faster more reliable connection is likely to be trivial against the benefits. If you can't get your connection upgraded due to techinical limitations then I don't know how you can resolve this - trying to coordinate downloads between 8 people is tricky, unless you have 1 person who doesn't download and everyone else is restricted to 1 day per week. Exxolon (talk) 11:32, 22 April 2011 (UTC)[reply]
I'm in west Africa, and like I said we have no option of getting a faster or better connection. Bandwidth is insanely expensive and unreliable here, even with the WACS and other undersea fiber cables recently laid. Condensation333 (talk) 18:27, 22 April 2011 (UTC)[reply]
After some more research it looks like prioritization is actually what I need to look in to. I need to figure out how anyone else in the world (businesses, colleges, etc.) manage bandwidth when there are a large number of users sharing one connection. The actual speed of bulk downloads aren't a concern. It's managing all the connections so the internet connection as a whole doesn't become saturated and causing latency to go from the baseline 350ms to 2500~10000ms. I think the hardest part is classifying traffic, especially when using encryption over non standard ports, just like ISPs have to do to manage P2P file sharing. That's what I'm currently looking at finding some software for. Condensation333 (talk) 18:27, 22 April 2011 (UTC)[reply]
m0n0wall has traffic shaping as do most software-OS firewall/router distros like pfSense and also the Linux ones. I think most of these popular ones are in our list (other then the FreeBSD ones I've mentioned a look at the list tells me ClearOS, SmoothWall are two you might also want to look at it's been a while since I've looked in to software-OS firewall/router distros) . I've never used these in a relatively hostile environment (I use m0n0wall in a benign environment) but they may work, at the very least giving some priority to TCP acks should help things. You will need to work out how much your maximum upload and download is for maximum efficiency though. Note that you should set these up to function as your router, you can still use any router as a switch and a wireless access point but the routing functions become unnecessary. Note also that most of these are designed to sit on a stand alone box, you could perhaps hack one to work with an existing box doing other things or also run one under VMware but I wouldn't recommend it except while choosing what to use (many may have live CD/DVDs). Other then just trying those which seem to fit your bill, I would specifically look in to the traffic shaping component if you are having problems choosing. If you have 8 users, you can easily buy an old computer or even a new nettop without each person spending too much I would hope. Nil Einne (talk) 12:05, 22 April 2011 (UTC)[reply]
Thanks these are actually what I've been looking at today. I'm now looking at finding a distro which main featureset is traffic management, or figuring out what software these distros are using for these tasks so I can look further into it. Condensation333 (talk) 18:27, 22 April 2011 (UTC)[reply]

Upgrading laptop hard drive edit

I'm suffering from information overload, so... I came here. I need to upgrade my laptop's hard drive. Unfortunately, there is no way to replace some of the software on it without spending quite a bit of money, assuming I can even figure out how to backup the settings. I have a desktop I can plug one hard at a time into. Is it enough to just copy every byte manually off one drive onto the desktop, and then onto the new drive? Or do I need some sort of software that works from the boot menu? Much obliged in advance. Mxvxnyxvxn (talk) 05:08, 22 April 2011 (UTC)[reply]

No, that will cause you licensing and linking problems. You need to plug both hard drives in at the same time and "disk copy" the entire drive over. Or, if you can just get some big USB flash drives/pen drives, maybe they can provide the extra capacity and you can stick with the current hard drive. (I would also suggest an external USB hard drive, but presumably you want more portability than that.) Use the external devices for data (like pics, movies, etc.), and leave the operating system on the original hard drive. This all assumes that the original hard drive still works fine, but is just too small. This should save you lots of money, assuming you planned to have a professional install the new hard drive (and it's easy to ruin your laptop if you do it yourself). StuRat (talk) 05:25, 22 April 2011 (UTC)[reply]
I can't plug in both without some molex-to-sata or sata-to-usb converters(and I'm currently in the desert of computer parts- I was lucky to find someone who sold bare drives!) ... Can I use something like EASUS using a external drive as an intermediary, and copy the image from there onto the blank one? Mxvxnyxvxn (talk) 06:12, 22 April 2011 (UTC)[reply]
That could work, but some software may still detect that it's on a new hard drive and complain about licensing. How much capacity does your current HD have and how much more capacity do you need ? StuRat (talk) 06:32, 22 April 2011 (UTC)[reply]
I have a 120, and I need at least triple that. I was planning to get somewhere between 320 and 640.Mxvxnyxvxn (talk) 06:42, 22 April 2011 (UTC)[reply]
Would an additional plug-in external USB hard drive be totally unacceptable ? It certainly would be inexpensive and simpler, although admittedly it makes the laptop slightly less portable. StuRat (talk) 06:50, 22 April 2011 (UTC)[reply]
I don't see why you couldn't dd everything to a file on the desktop's hard disk, if you have the space, and then dd it back from the file to the new disk. The only potential problem I think would be if for some reason the new hard disk requires more drivers than the laptop's installed OS currently has installed.
http://mark.koli.ch/2009/05/howto-whole-disk-backups-with-dd-gzip-and-p7zip.html
¦ Reisio (talk) 06:28, 22 April 2011 (UTC)[reply]
Unfortunately, I have no experience with Unix. Mxvxnyxvxn (talk) 06:44, 22 April 2011 (UTC)[reply]
You don't need any, the commands are all there on the page I linked. There's even dd for Windows (which would allow you to continue using your ordinary [presumably Windows] desktop OS while you do this), though the device selection syntax changes slightly (see download page). ¦ Reisio (talk) 07:29, 22 April 2011 (UTC)[reply]


Don't letim fool ya! Every time someone says "you could do it in Linux with like 1 command" that means you will spend a weekend booting into Linux, the next week on IRC channels figuring out things they assumed you would have already known, and the third week undoing everything you've done, giving up, and on a whim doing one more quick Google search, downloading a piece of Windows shareware from 1997 that does it in three clicks, and being done with it. 188.157.230.192 (talk) —Preceding undated comment added 10:03, 22 April 2011 (UTC).[reply]
Stu- short answer, yes, It would be a huge pain to deal with an external. And the truth is, I don't expect the important programs to complain about licensing, and the rest aren't as important. Reisio- Even though you are probably right, I'm a bit nervous to try it before attempting my original plan, but in Stu's worse-case scenario, I will give it a shot. Worse comes to worse, I can use the extra drive inside my desktop and switch it with the external I am currently using as backup. 188- There are whole communities of us that don't assume computer illiteracy until proven.
Thanks, guys. Prompt and spot on, as always. I love the reference desk. Mxvxnyxvxn (talk) 11:16, 22 April 2011 (UTC)[reply]
Disk cloning and List of disk cloning software will probably help if you don't want to try using dd. Norton Ghost is an example that I've used a lot. It can save the bit image of your hard disk to a file (compressed, if you'd like). Personally I've only cloned drives that were both connected at the same time to the computer, but you ought to be able to (a) clone disk to a file, (b) swap hard disks, and (c) copy file to the new hard disk. Then Ghost should be able to expand the size of your new hard disk's partition so you can actually use all that extra space. Again, I've personally only done this when both drives were connected; but I suspect this will work for you. Comet Tuttle (talk) 16:38, 22 April 2011 (UTC)[reply]

I suggest:

  • Buy new drive. Remove old drive from laptop. Plug both old and new drives into desktop, using USB adapter if necessary.
  • Make partition on new drive the same size as system partition on the old drive. Use partition copy (dd or equivalent, I think "Ghost" may be the corresponding windows program) to copy system partition from old drive to new drive.
  • Make additional partition for the remainder of the new drive, for your user files. Copy those over with file copy rather than partition copy.
  • See if new drive works in laptop including booting, operation of important programs, etc.
  • Note that you haven't written anything to old drive during this operation. Put old drive away someplace safe so you have it as an additional data backup in case something non-obvious has gone wrong that you discover later. 69.111.194.167 (talk) 18:47, 23 April 2011 (UTC)[reply]

Can I play this game on a modern pc? Kittybrewster 08:33, 22 April 2011 (UTC)[reply]

The DOS version should work on DOSbox. Very likely the other versions would work too using some emulator although you may need ROMs and/or OSes for some of these emulators in the first place in addition to the game for that system. Nil Einne (talk) 11:27, 22 April 2011 (UTC)[reply]

Sikuli edit

I'm using Sikuli and would like to simply set a script to loop. I can't for the life of me find instructions on how to do this. Any advice? ╟─TreasuryTagChancellor of the Duchy of Lancaster─╢ 10:24, 22 April 2011 (UTC)[reply]

A python developer could probably tell you a thousand different ways and the advantage/disadvantage of each (in fact I've used several myself in my simple Sikuli scripts) but for a simple infinite loop "while True:" with appropriate indenting of the rest of the script should work. See also [1] or any discussion on looping in Python. Nil Einne (talk) 11:47, 22 April 2011 (UTC)[reply]

education edit

i want to know the high scope engineering courses — Preceding unsigned comment added by Jagan.sankaran (talkcontribs) 12:08, 22 April 2011 (UTC)[reply]

This will differ depending on the school and the exact type of engineering you are interested in. Most universities probably have course listings and descriptions on their web sites. Assuming you are interested in software engineering (since you posted this on our Computing desk), I googled MIT computer science and found my way to this page, which has links to the course descriptions for MIT's computer science degrees. Comet Tuttle (talk) 16:34, 22 April 2011 (UTC)[reply]
On the other hand, if "high scope" was intended to mean "material that is relevant across a broad range of engineering topics," you might want to take a look at material related to:
  • industrial engineering - the study of how to manage large systems and projects
  • control theory - the mathematical study of how to make a technology system do exactly what you want it to do
  • optimization theory - the mathematical study of how to find the provably-correct answer to a quantitative question
  • engineering economics - the study of how to finance and control the costs in engineering projects
  • systems theory - which ranges from very fuzzy high-level things to very numerical, quantitative analysis.
And, of course, you will need to have a solid grounding in the more applied disciplines of modern mathematics - calculus, differential equations, linear algebra, and computer programming. Nimur (talk) 17:26, 22 April 2011 (UTC)[reply]

Cannot save in Microsoft Word edit

I use Microsoft Word to write long documents (including a lot of graphics and formulae). Very often, maybe once a day, when I try to save a document (Ctrl+S), the "Save As" dialog appears (which is unexpected, since the document is already saved as a file). And, then, no matter if I choose to overwrite the existing file, or to save as a new file, which are my only options, it fails with error message "A file error occurred" [translated from Swedish: "Ett filfel uppstod"]. Thus, I cannot save the document anymore! Is there any cure? I have experienced this problem since Word 2007. Now I use Word 2010. --Andreas Rejbrand (talk) 12:58, 22 April 2011 (UTC)[reply]

Some clarification:
This has happened for a very long time, and with many different documents. And on different computers. My hypothesis is that Word is buggy, and that formulae and/or Word illustrations sometimes "mess up" the document so that it cannot be saved any more. I just removed all equations and illustrations from the file, and then it was possible to save it. But when I undo (so that the equations and illustrations come back), I can no longer save. We are talking about many, many hours of work, so I am a bit annoyed... --Andreas Rejbrand (talk) 15:07, 22 April 2011 (UTC)[reply]
That's pretty horrible. Does the same error occur when you attempt to save it as a different format of document? On a different hard disk? Comet Tuttle (talk) 16:28, 22 April 2011 (UTC)[reply]
Well, I haven't tried any other format, because any conversion from DOCX would make the equations uneditable, and there are hundreds of them! I have tried all disks there are, and the problem is the same. But I did solve the problem. I went through all the equations and illustrations, one by one: I deleted the equation/illustration and tried to save. It turned out to be a single illustration that was the problem, namely this one. So I removed it and redraw the image from scratch. And then I saved it. [At the very least, it would have been polite if Word had pinpointed this illustration for me instead of giving me a nonsense error message!] --Andreas Rejbrand (talk) 18:39, 22 April 2011 (UTC)[reply]
  Resolved
Nearly everybody I know who has tried it advises against writing long, technical documents in Word. Most advocate LaTeX instead. This advice may be to late if you are already this far down, of course. --Stephan Schulz (talk) 07:41, 23 April 2011 (UTC)[reply]
One useful technique when dealing with a large document that has been edited many times is to copy the entire contents into a new document; doing this removes the accumulated crap built up through all those previous edits and makes the document file smaller. It is also a good idea to go through the styles used by the document and restrict the number of styles used to just a few (Normal, body, 4 levels of headers, and a few that are specialised to your work). For example, you will probably find several versions of body text with the only variation being millimetre changes in indentation or tab positions, or a couple of paragraphs with a different font size; these could be merged into just one body text style. Astronaut (talk) 08:26, 24 April 2011 (UTC)[reply]
Oh, I got great control over my styles! I got four headers, body text, Chapter Header, Chapter Subheader, Theorem Header, Theorem Body, Example Header, and Example Body, and almost every character in the document belongs to any one of these (exceptions include figure captions, footnotes, etc.). I am that pedantic that millimetre changes in indentation don't occur in my documents! Regarding the 'crap buildup', quite apparently, this is an issue. But it isn't fun to move to another document, since you can't simply Ctrl+A, Ctrl+C, Ctrl+V: this will not copy headers, footers, the bibliography (?), etc. I'll just hope that the next verson of Word is more robust! After all, the formulae editor isn't nearly as buggy in 2010 as it was in 2007. --Andreas Rejbrand (talk) 16:41, 24 April 2011 (UTC)[reply]

internet street cabinets edit

Approximately how wide of an area and how many houses are covered by one of these internet street cabinets in the UK? pic —Preceding unsigned comment added by 174.103.209.253 (talk) 19:43, 22 April 2011 (UTC)[reply]

It appears to be a fiber cabinet. According to fiber to the x, there is a range of fiber architectures, each serving a different size area from one fiber cabinet. The largest-area architecture, fiber to the node, says "The area served by the cabinet is usually less than 1,500 m in radius and can contain several hundred customers." So I guess those are the typical maximums. If you're thinking of a certain provider or region, we may be able to find more specific numbers. --Bavi H (talk) 01:55, 23 April 2011 (UTC)[reply]

Firefox 4 URL popup edit

Using Firefox 4, when I mouse over a link, a small popup appears in the lower left displaying the URL. However, if I have the find bar open, this popup appears in the lower right. Is there any way to make it always appear in the lower left? I am not looking to restore the status bar via the "Status-4-Evar" add-on; I only want the mouseover popup to be consistent. - SigmaEpsilonΣΕ 23:53, 22 April 2011 (UTC)[reply]

If you just want consistency and don't much care what the consistent behavior is, Status-4-Evar has the option to display the link target in place of the current URL in the address bar (in a different, selectable color). I've been using that and I'm happy with it. When I set the display location back to "Popup", the popup always shows up in the bottom right, with or without the find bar open. I don't know whether this is Status-4-Evar's influence or something else. -- BenRG (talk) 08:52, 23 April 2011 (UTC)[reply]
I downloaded Status-4-Evar and set the "Show links in:" option to "Popup". Unlike your experience, this causes the exact same behavior as without the add-on. - SigmaEpsilonΣΕ 18:57, 23 April 2011 (UTC)[reply]

Adding this to your userChrome.css should take care of it:

statuspanel {
	right: auto !important;
	left: 0 !important;
}
.statuspanel-label:-moz-locale-dir(rtl):not([mirror]),
.statuspanel-label:-moz-locale-dir(ltr)[mirror] {
	border-left-style: none !important;
	border-top-left-radius: 0 !important;
	margin-left: 0 !important;
	border-right-style: solid !important;
	border-top-right-radius: .3em !important;
	margin-right: 1em !important;
}

¦ Reisio (talk) 16:44, 24 April 2011 (UTC)[reply]