You are not logged in.

#1 2008-11-05 22:47:25

richs-lxh
Member
Registered: 2008-08-23
Posts: 76

Performance Issues? Check your Swap - It may have a faulty uuid

Well, one of my friends noticed this problem on another distro, so another mate of mine checked his Arch install and found that when you issue a

free -m

swap was zero.

After comparing the swap partition uuid via

sudo blkid

with /etc/fstab, it was clear that the uuid's were different.

I also checked my Arch install and found the same problem. No swap.

Basically you edit /etc/fstab, add the uuid which is shown from

sudo blkid

and then reboot, or issue

swapon -a

You should now have swap and running

free -m

will also show that swap is no longer zero, but the amount you have allocated.

I thought i'd post, just in case anybody is having performance problems.

richs-lxh

PS: The thread is here if anybody wants to read it:
Having trouble???....check your SWAP!

Last edited by richs-lxh (2008-11-09 23:39:46)

Offline

#2 2008-11-06 00:50:21

merlin
Member
From: Maine
Registered: 2008-10-06
Posts: 12

Re: Performance Issues? Check your Swap - It may have a faulty uuid

As an additional point. I have Arch installed as my primary work machine on a laptop. I decided to dual boot it with another distro (Ubuntu) which shares the swap partition. After installing Ubuntu, the uuid of the swap space had changed and hibernate would not work on the Arch side. The blkid command is a useful one and I had hibernate working again on Arch in no time.
Interestingly, the Arch side and the Ubuntu side share a mounted partition I call /archive (used for common data), however, the uuid of this partition did not change when I installed Ubuntu. Relative to the swap file, could this be a bug in the Ubuntu installer?

Offline

#3 2008-11-06 02:12:10

imag1narynumber
Member
From: Connecticut
Registered: 2008-07-23
Posts: 56

Re: Performance Issues? Check your Swap - It may have a faulty uuid

Mine lists 4102 free, but I've never seen swap used.  Doesn't show as being mounted, either.  But the UUID is correct.

Offline

#4 2008-11-06 02:16:45

creslin
Member
Registered: 2008-10-04
Posts: 241

Re: Performance Issues? Check your Swap - It may have a faulty uuid

merlin wrote:

After installing Ubuntu, the uuid of the swap space had changed and hibernate would not work on the Arch side. The blkid command is a useful one and I had hibernate working again on Arch in no time.
Interestingly, the Arch side and the Ubuntu side share a mounted partition I call /archive (used for common data), however, the uuid of this partition did not change when I installed Ubuntu. Relative to the swap file, could this be a bug in the Ubuntu installer?

UUIDs only change after formats, and the "Format this partition" option is grayed out for swap partitions in the ubuntu installer.  I just tried some intrepid test installs and it left the swap UUID alone for me.

Last edited by creslin (2008-11-06 03:05:10)


ARCH|awesome3.0 powered by Pentium M 750 | 512MB DDR2-533 | Radeon X300 M
The journey is the reward.

Offline

#5 2008-11-06 02:21:36

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,222
Website

Re: Performance Issues? Check your Swap - It may have a faulty uuid

richs-lxh wrote:

Basically you edit /etc/fstab, add the uuid which is shown from

sudo blkid

and then reboot.

No need to reboot - just do `swapon -a`

imag1narynumber wrote:

Doesn't show as being mounted, either.

Have a look at the output of `swapon -s`

Offline

#6 2008-11-09 16:14:38

richs-lxh
Member
Registered: 2008-08-23
Posts: 76

Re: Performance Issues? Check your Swap - It may have a faulty uuid

AurGlass wrote:

I'm not sure why you would be looking in /etc/mtab (or /proc/mounts) for your swap partitions.  I've never seen them listed there.

Yup. That was a mistake and has been amended, thanks for pointing it out.

As fukawi2 mentioned, `swapon -s` or `cat /proc/swaps` will tell you whether your swap partitions are active.

I have added your suggestion to my post, thanks.

Anyway, this post was an alert for anybody who performs regular distro tests or swap formats, not a lesson in swap partition finding. tongue But thanks for the input, it's always good to show that there is always more than one way to skin a cat.

As it happens, quite a few people I know have confirmed this problem on Debian, derivatives, and Arch. So at least we have saved a few "Why is [insert distro] so slow?" posts.

richs-lxh

Last edited by richs-lxh (2008-11-09 23:27:13)

Offline

#7 2008-11-09 23:37:27

richs-lxh
Member
Registered: 2008-08-23
Posts: 76

Re: Performance Issues? Check your Swap - It may have a faulty uuid

Thanks to AurGlass and fukawi2 for the tips/corrections. They have now been amended to my blog post:

4. sudo swap on, or swapon as root
As was suggested by fukawi2 on the Arch Linux Forums
"No need to reboot - just do `swapon -a`"

UPDATE: There was a mistake regarding mtab in this post which has now been amended thanks to AurGlass at the Arch Linux Forums

Warning: Ubuntu/Arch Linux Slowdown? Check Your Swap

A few people have found that after installing other distros, and reformatting partitions and swap they did find the uuid had indeed changed, leaving them without an active swap partition. So at least this post solved the problem for them.

richs-lxh

Last edited by richs-lxh (2008-11-09 23:47:48)

Offline

#8 2008-11-10 17:20:34

richs-lxh
Member
Registered: 2008-08-23
Posts: 76

Re: Performance Issues? Check your Swap - It may have a faulty uuid

Just as a follow up, has anybody here (who regularly installs other distros or changes/formats swap/partitions) noticed any problem with other distros other than Arch and Ubuntu?

It would be interesting to see if this affects others.

richs-lxh

Offline

#9 2009-12-19 11:52:17

richs-lxh
Member
Registered: 2008-08-23
Posts: 76

Re: Performance Issues? Check your Swap - It may have a faulty uuid

Just popped back to say that the swap UUID still needs to be corrected if you install a second distro dual-booting with Ubuntu. I found the same thing happen with Fedora, Mint and Arch.

Basically Ubuntu slowed down to a halt, (not a very powerful laptop), and when I used blkid I saw the different UUID for swap.

I'll probably get my ass kicked for digging up an old thread, but the problem still happens on distros which use the UUID system, so I thought it was relevant. If not, just bin this thread.

As merlin pointed out earlier, I think this maybe a problem with the Ubuntu installer.

Thanks

rich

Last edited by richs-lxh (2009-12-19 11:55:00)

Offline

Board footer

Powered by FluxBB