Archive for October 17th, 2008

Well, at least I got a lot of traffic out of the deal…

Friday, October 17th, 2008

That’s the most hits I’ve ever had in a day, and I’ve already hit more than average for a day only this morning…

Update on my swapping woes

Friday, October 17th, 2008

I feel a bit embarrased about the ranting and complaining about Linux yesterday, ’cause as it turned out and as suggested by most of the commenters, on Linux you actually have the tools to fix the system when it is broken.

And broken it was, but only on my box.

The comment that sent me down the path to solving the problem was this one:

Marc Paradise Says:

You can reduce linux’s annoying tendency to swap out too fast:

Here are some instructions on how to do this for ubuntu:

http://ubuntuforums.org/showpost.php?p=1255511&postcount=43

See, at the time I thought my problem was that the system was swapping way too much, to the point where I couldn’t get in contact with it.  That is how it behaved.  It would run out of RAM, the disk would be spinning, it would slow down to the point where I couldn’t interact with the machine.

So reducing swapping might crash some programs if they run out of memory, but at least I would be able to interact with the system.

Sounded like just the thing to go for.

Well, when I followed the instructions I came to this command, with this troubling error:

$ sudo swapoff -a
swapoff: cannot canonicalize /dev/disk/by-uuid/d00bfdb4-c541-4d56-8448-b0a13ce352a8: No such file or directory

Ups, something is wrong here.  Could it be that the system doesn’t know where the swap partition is?  I checked the system monitor and to my horror found that it uses 0 bytes of swap, even when I am trying to fill up the RAM with all the applications I can fire up.

Yep, something is wrong here.

I googled for “swapoff: cannot canonicalize” — I find that googling the error message usually leads me to the answer faster than actually thinking about it — and then I hit this thread: http://ubuntuforums.org/showthread.php?t=802398

I followed the advice there and update /etc/fstab and viola, my swapping is back up (well, after running swapon -a).

If I stress the system now, of course some tools slow down as they are swapped out, but the behaviour is no where near what it was earlier.

Why the symptoms earlier looked like swapping rather than crashing applications I don’t know, but I don’t really care either.  I’m just happy to have a stable system back.

Sorry for ranting, Linux, in the end you came through for me :)