LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-04-2011, 03:58 AM   #1
drManhattan
Member
 
Registered: Aug 2010
Location: Warsaw, Poland
Distribution: Ubuntu 10.04 LTS on IBM Lenovo R61e, RHEL5-6,SLES10-11
Posts: 262

Rep: Reputation: 1
swap on LVM


Hi

I wonder whether to place swap partition on LVM or on standard fdisk partition which will not be in LVM.

What is better and more often used on production ?

thx for help.
 
Old 08-04-2011, 04:51 AM   #2
mpapet
Member
 
Registered: Nov 2003
Location: Los Angeles
Distribution: debian
Posts: 536

Rep: Reputation: 71
Quote:
Originally Posted by drManhattan View Post
Hi

I wonder whether to place swap partition on LVM or on standard fdisk partition which will not be in LVM.

What is better and more often used on production ?

thx for help.
For production, swap is on a RAID1,5,etc. You don't have to do that though. You can have multiple swap partitions and set priority on each of them. From there, the kernel manages swap.
 
Old 08-04-2011, 05:07 AM   #3
drManhattan
Member
 
Registered: Aug 2010
Location: Warsaw, Poland
Distribution: Ubuntu 10.04 LTS on IBM Lenovo R61e, RHEL5-6,SLES10-11
Posts: 262

Original Poster
Rep: Reputation: 1
But whether create pv volume and then lv volume with swap (e.g. /dev/mapper/root_vg-swap_lv)or use clean fdisk partition for swap (e.g. /dev/sda3 swap) ?
 
Old 08-04-2011, 03:23 PM   #4
mpapet
Member
 
Registered: Nov 2003
Location: Los Angeles
Distribution: debian
Posts: 536

Rep: Reputation: 71
Quote:
Originally Posted by drManhattan View Post
But whether create pv volume and then lv volume with swap (e.g. /dev/mapper/root_vg-swap_lv)or use clean fdisk partition for swap (e.g. /dev/sda3 swap) ?
I like things simple. I would use fdisk to make your swap partitions and fstab to use and assign priority. To be clear, there's no right answer. IMHO, an LVM for swap is more to possibly go wrong.
 
Old 08-04-2011, 03:39 PM   #5
Fantasio
Member
 
Registered: Nov 2007
Location: Vinsobres - Drome - France
Distribution: SuSE Linux 11.3
Posts: 152

Rep: Reputation: 19
If you really need more swap

I think swap on lvm is not the best deal you can do. In the case where the swap partition is too small, use a file to increase it.
theorically, if the swap is used than your system memory is too low and you have poor performances.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to swap one hard drive with another when using LVM? martdj Linux - Newbie 3 08-04-2011 05:17 AM
[SOLVED] Forgot Swap on lvm install on Slackware 13.1 BoydRice Slackware 4 06-04-2010 07:23 AM
Anyway to config crash/diskdump with an LVM Swap? epoh Linux - Server 1 09-09-2009 10:16 AM
Resizing Swap in LVM on Fedora 6 tnine9 Fedora 2 03-03-2007 12:12 PM
How to increase swap size in LVM? Akhran Debian 1 04-04-2006 09:47 AM


All times are GMT -5. The time now is 02:26 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration