« When using RAID 5, why is the HD light on all the time.Extra Packages I usually install »

HOWTO:Make the SWAP Space Span 3 disks With Stripping.

07/07/08

Permalink 10:17:41 am, by richard Email , 249 words   English (GB)
Categories: Ubuntu Linux, Filing Systems, Installation and Configuration

HOWTO:Make the SWAP Space Span 3 disks With Stripping.

Once the system is installed do not forget to configure the priority of the swap spaces. If the priority is set correctly then all your swap spaces will be used as it they are stripped making it faster.

...

To see the current swap space setup use the command :

command:
swapon -s

The last column "Priority should be the same for all three areas or you will not see the performance gain. In /etc/fstab for the three swap mount lines replace the none with swap and add pri=1, to the sw. As in:-

Example /etc/fstab entry
UUID=34a54a33-3b43-f53d45345 swap swap pri=1,sw 0 0

You can stop and start the swap space with :-

command:

swapon -a  


swapoff -a

I found this gem of information, but have lost the original link. I think it was from the Ubuntu formus. Thanks .

If you end up getting a corrupt swap space you can reinitialise it with the following:

Example commands:

sudo swapoff /dev/device 


sudo mkswap -v1 /dev/device 
sudo swapon /dev/device 

You can also add a label so you can mount with something like this:

Example /etc/fstab entry

LABEL=swap1 swap swap pri=1,sw 0 0  


LABEL=swap2 swap swap pri=1,sw 0 0  
LABEL=swap3 swap swap pri=1,sw 0 0

To use labels on swap partitions you need to turn off the swap area add the label and turn it back on

Example commands:

sudo swapoff -a  


sudo mkswap -L swap1 /dev/sda2  
sudo mkswap -L swap2 /dev/sdb2  
sudo swapon -a
Tags: spanning, swap

No feedback yet

Here are a collection of Mini-HOWTOs some of which are too short even for that grand title. I keep them around as it is easier to remember where to look these up that to remember the content of the mini-HOWTO

Search

Contents

powered by b2evolution