zeldor.biz

Linux, programming and more

Copyright © 2025
Log in

Create Swap

December 29, 2010 by Igor Drobot Leave a Comment

I decide me to use LVM for the most server that I have, its very flexible and you can every time resize and shrink your partitions.

Use swap area as LVM was a little bit tricky:
Create a swap partition with parted or your favorite one.

1
2
3
4
5
# -L flag creates a label for your device
mkswap -L swap /dev/vdc1
swapon -a
cat /etc/fstab
LABEL=swap      none            swap    sw              0       0

# -L flag creates a label for your device mkswap -L swap /dev/vdc1 swapon -a cat /etc/fstab LABEL=swap none swap sw 0 0

Filed Under: Linux Tagged With: label, LVM, partition, swap

Yeaaah Cookie! We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.Ok