Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 07-31-2009, 03:09 PM   #1
Registered: Apr 2008
Posts: 155
Blog Entries: 2

Rep: Reputation: 15
convert linux to LVM

Hi All,

i have install Centos 5.3 Linux newly and copied some data. Now i want to change all linux partition into LVM. Is it possible to do that and if i do that , would data be damaged? seem there is an partition type 8e for lvm but not sure about how far the data remain intact?

The following partition type

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 14036 112639747+ 83 Linux
/dev/sda3 14037 15056 8193150 83 Linux
/dev/sda4 15057 17849 22434772+ 5 Extended
/dev/sda5 15057 16076 8193118+ 83 Linux
/dev/sda6 16077 16331 2048256 83 Linux
/dev/sda7 16332 16586 2048256 83 Linux
/dev/sda8 16587 17849 10145016 8e Linux LVM

Disk /dev/sdb: 146.8 GB, 146815733760 bytes
255 heads, 63 sectors/track, 17849 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 17210 138239293+ 83 Linux
/dev/sdb2 17211 17849 5132767+ 8e Linux LVM

Old 07-31-2009, 07:19 PM   #2
John VV
LQ Muse
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,183

Rep: Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505Reputation: 2505
unless this is a SERVER I would not bother with LVM ( Logical Volume Manager) it is WHY more hassle than it is worth for a home system

the only way to do it , change the ext3 to LVM , is to 100% reformat the drive( or the partitions ) to lvm

would data be damaged?
unless it is backed up to a backup drive or dvd then YES it will be 100% gone

Last edited by John VV; 07-31-2009 at 07:21 PM.
Old 08-01-2009, 01:13 AM   #3
LQ 5k Club
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,576
Blog Entries: 31

Rep: Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195
Hello linuxguy08

Conversion is a manual process.

/boot cannot be on an LVM volume and there is little or no benefit in putting swap on an LVM volume. Unless / is large and has changing data you need to back up regularly, there is little benefit in putting it on an LVM volume and some cost in administrative inconvenience.

For the rest there are reasons for and against. The "for"s are more relevant on a high-availability system. The "against"s are administrative complexity.

On a system where down-time is acceptable the major benefit is being able to take snapshots for backing up. If you have data that needs to be consistent across several files and you want to update that data during backup then that's essential.

If you want to be able to re-size file systems while they are mounted then, to take advantage of LVM's ability to change partition sizes on the fly, you need to use a file system that can be re-sized on the fly. Not ext3.

It looks like you have several file systems already, one of which is 112 GB. That's not going to fit in the 15 GB you have configured for LVM use! So you would need some free space to give to LVM before you could convert all your file systems -- or copy off to backup, take the space for LVM and copy back.




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
LXer: Xen: How to Convert An Image-Based Guest To An LVM-Based Guest LXer Syndicated Linux News 0 04-19-2009 04:00 PM
ext3 (mounted) to lvm convert matters Slackware 1 05-29-2007 02:13 AM
want to convert LVM physical volume to ext3 or vfs nikhil_damu Fedora 2 12-14-2005 11:16 PM
Convert LVM volumes to primary partitions? MHouse Linux - Software 0 02-03-2005 10:34 PM
How to convert partition to LVM? TheOther1 Linux - General 0 01-04-2004 12:29 PM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 04:38 PM.

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