Fedora Linux Support Community & Resources Center
  #1  
Old 14th April 2011, 07:36 AM
Majara Offline
Registered User
 
Join Date: Dec 2010
Location: Burgos-Spain
Posts: 78
linuxfedorafirefox
F14, GParted and lvm2

ˇHola!

In the partition where F14 is installed, GParted shows a traffic danger sign. The explanation is "Logical Volume Management is not yet supported".

I should like to change lvm2 file system to ext 4. The /boot partition is ext4.

How can I do it?

Saludos
Reply With Quote
  #2  
Old 14th April 2011, 10:41 AM
markkuk Offline
Registered User
 
Join Date: Apr 2005
Location: Finland
Posts: 5,075
windows_xp_2003firefox
Re: F14, GParted and lvm2

LVM isn't a file system, it's a Logical Volume Management system. The file systems on logical volumes are ext4 by default.
If you want to use basic partitions instead of LVM you need to re-install your system.
Reply With Quote
  #3  
Old 14th April 2011, 01:27 PM
stoat Offline
Registered User
 
Join Date: Jun 2006
Posts: 7,550
linuxfedorafirefox
Re: F14, GParted and lvm2

Just for fun one time, I "cloned" an LVM system to a single ordinary ext3 root partition. The LVM physical volume contained logical volumes for root and swap. I used simple tar commands to copy the files from the root logical volume to a newly created ext3 partition. I ignored the swap logical volume and simply created a new ordinary swap partition. I also copied the files of the LVM system's separate boot partition to the /boot directory of the new root partition so the whole thing would be in a single root partition. The usual things were edited after cloning (/etc/fstab, /boot/grub/grub.conf, etc.). The GRUB boot loader was re-installed. The initial ramdisk files were recreated. And I forced an SELinux relabel. The system booted and worked normally in the ext3 partition. Everything was done from linux rescue with a Fedora DVD. So, if a system such as the one in the first post is valuable for some reason and therefore worth the effort, then it is possible to move it to standard partitions. It's not the same as "converting", but almost. Probably safer, too, even if converting was possible because the old system remains intact until after the new cloned system is up.

P.S.: I may have done this for "fun", but not everybody will think it's fun. I wouldn't try this unless you are very highly motivated against LVM for some reason and the system is highly valuable for some reason. If you're just thinking "it would've been nice the other way", then do that next time. For now, test drive LVM. Find out everything you can about it. You may even like it. That's what I did. But for me and my simple home systems, it turns out to be an unnecessary layer of complexity over the filesystem. I stopped installing Fedora with LVM.
Reply With Quote
  #4  
Old 16th April 2011, 08:38 AM
Majara Offline
Registered User
 
Join Date: Dec 2010
Location: Burgos-Spain
Posts: 78
linuxfedorafirefox
Re: F14, GParted and lvm2

ˇHola!
Before re-install the system I shall try to "clone" it.
Just I had prepared a partition in ext3 to install another distro, but I shall use it for this matter.

The information I get from GParted is attached. As you can see GParted doesn't understand LVM.
The boot partition is in /dev/hda6 (hd0,5) with 500MB (355MB free).

I shall copy all the files of the actual filesystem to the new partition and I shall modify the grub.conf. If it doesn't go I shall use the re-install option.

Really I don't like LVM as it could not interchange files with another not LVM distro and because it doesn't agree with GParted.

Saludos.
Attached Thumbnails
Click image for larger version

Name:	Pantallazo-Información acerca de -dev-sda7.png
Views:	498
Size:	35.2 KB
ID:	20926  
Reply With Quote
  #5  
Old 16th April 2011, 12:49 PM
smr54 Offline
Registered User
 
Join Date: Jan 2010
Posts: 5,391
linuxchrome
Re: F14, GParted and lvm2

Can gparted now extend a root partition while it's online? (I haven't used it in awhile.)

One of LVM's advantages is also a bit of a weakness if you're not using RAID. It can span a partition across multiple drives, but that also gives multiple points of failure, and if a drive goes bad, it's harder to recover data from an LVM. There are tools that do it, but last time it happened to me on a machine that had neither RAID nor regular backup, the only tool I found just recovered thousands of files with numbers, so finding the ones I needed became quite difficult. Think I gave up (had it been an important install, I would have had backups.)

On the other hand, it's quite useful when using NAS or SAN--for example, on a machine working as an iscsi server, you can expand the LUN on the SAN and quickly expand the LVM, all from command line--once you get used to the commands, it's quite simple, but like everything else, when you don't know it, it seems complex.

It's worth learning about them if you're going to be a sysadmin. Not sure if btfs is aimed at replacing their functionality, but even if it is, it's not ready, as far as I know, for real production use. If you're just using Linux as a work station, then you are almost certainly better off without them, as gparted can enable to do most of what you'd need.

I'm not sure why Fedora, a distribution that feels its target user is too inexperienced to be root, uses it by default, probably a legacy from RH, which is aimed more at the enterprise--hence the "Enterprise" in its name.
Reply With Quote
  #6  
Old 16th April 2011, 02:14 PM
stoat Offline
Registered User
 
Join Date: Jun 2006
Posts: 7,550
linuxfedorafirefox
Re: F14, GParted and lvm2

Quote:
Originally Posted by Majara

I shall copy all the files of the actual filesystem to the new partition and I shall modify the grub.conf. If it doesn't go I shall use the re-install option.
Very well. But you also will have to edit /etc/fstab, recreate the initial ram filesystem files in /boot, and force an SELinux relabel. Here is a sort of outline of the steps that I used to move everything in a Fedora 11 LVM system into a single new ext3 partition (FWIW, no promises). You will have to modify them as needed. My LVM system had only root and swap logical volumes. Yours might also have one for home or others. You don't have to move the boot partition. And so on. You will need to know how to move the contents of an entire filesystem with a utility such as cp, rsync, tar, or cpio (don't use dd for this). You will need to know how to use mkinitrd or dracut.
  1. Create and format the ext3 destination partition.
  2. Create and format a swap partition (if another one doesn't already exist).
  3. Reboot into linux rescue or another Linux system (I did everything below in linux rescue with the F11 DVD).
  4. Mount the LVM root logical volume.
  5. Mount the ext3 destination partition.
  6. Copy the root logical volume to the ext3 destination partition (cp, rsync, tar, cpio etc.). If you have other logical volumes such as /home, then mount and copy it to the /home directory of the new partition, and so on. Ignore the swap logical partition.
  7. Mount the LVM system's boot partition.
  8. Copy it to the /boot directory of the still mounted ext3 destination partition.
  9. Re-install the cloned system's GRUB in the master boot record.
  10. Edit grub.conf for the new drive & partition numbers, and for the new root partition information, and to add "/boot" to the command paths.
  11. Edit /etc/fstab for the new UUIDs and/or device names and the new swap.
  12. Recreate the initial ramdisk with mkinitrd (F11 and earlier) or initial ram filesystem with dracut (F12 and later).
  13. Reboot.
  14. If the gdm login fails after cloning an operating system, then force an SELinux relabel by rebooting and appending the autorelabel kernel boot parameter.
No promises.
Reply With Quote
  #7  
Old 16th April 2011, 04:47 PM
Majara Offline
Registered User
 
Join Date: Dec 2010
Location: Burgos-Spain
Posts: 78
linuxfedorafirefox
Re: F14, GParted and lvm2

ˇHola!
My knowledges about linux/fedora are yet too fragiles to apply your excellent explanations. I shall study them later until the complete understanding. Thank you all very much.

Finally I have installed in another partition a complete F14.PAE. It starts well, but when I try to edit grub.conf I get:
Quote:
[root@Aitaenxp grub]# gedit menu.lst

(gedit:3178): EggSMClient-WARNING **: Failed to connect to the session manager: None of the authentication protocols specified are supported

**
GLib-GIO:ERROR:gdbusconnection.c:2270:initable_init: assertion failed: (connection->initialization_error == NULL)
Abortado (`core' generado)
[root@Aitaenxp grub]# uname -r
2.6.35.12-88.fc14.i686.PAE
I have removed and installed gedit, without no results. I cannot access to the partition where I copied my home files....
Help!

Saludos
Reply With Quote
  #8  
Old 16th April 2011, 10:29 PM
stoat Offline
Registered User
 
Join Date: Jun 2006
Posts: 7,550
linuxfedorafirefox
Re: F14, GParted and lvm2

Try either of these...
Code:
su -
gedit /boot/grub/grub.conf
The dash in the su command is important.

Or, if you have sudo configured...
Code:
sudo gedit /boot/grub/grub.conf
P.S.: That cloning business is sort of an advanced project. I only wanted to mention that it is possible.
Reply With Quote
  #9  
Old 17th April 2011, 06:07 AM
Majara Offline
Registered User
 
Join Date: Dec 2010
Location: Burgos-Spain
Posts: 78
linuxfedorafirefox
Re: F14, GParted and lvm2

ˇHola!
Exactly, the dash has solved the problem. I can modify the grub.conf file.

I don't close the thread as solved until formatting the LVM partition as ext3 or ext4. I shall report on here.

Thank you.
Reply With Quote
  #10  
Old 17th April 2011, 02:31 PM
stoat Offline
Registered User
 
Join Date: Jun 2006
Posts: 7,550
linuxfedorafirefox
Re: F14, GParted and lvm2

If you don't want LVM when you re-install, then you can choose the partitioning option "Create custom layout" and install Fedora in ordinary type 83 Linux partitions. It's what I do, anyway.
Reply With Quote
  #11  
Old 20th April 2011, 07:37 AM
Majara Offline
Registered User
 
Join Date: Dec 2010
Location: Burgos-Spain
Posts: 78
linuxfedorafirefox
Re: F14, GParted and lvm2

Hola!

I'm writing from a Live CD Fedora14. I spoiled all the ancient system.

I have two hard disk. The first had these partitions:
Primary sda1, and extended sda2 with 3 logical sda5(Fat32), sda6(ext4, /boot) and sda7(lvm2)
In the second hd there are 2 Fat 32 partitions and 2 ext3, in one of which is installed the Fedora.PAE I was using before the disaster.

I could not format the lvm2 partition with GParted nor with fdisk, always there was an error message. Finally I decided to do it with the hd Administrator of XP. I marked sda 7 to format NTFS with the idea of change it to ext3 from Fedora, but it formatted sda6 and sda7. Now, at start I only see a black window with the grub>.

I attach here the list of partitions detected for F14 Live in my first hd:

Quote:
[liveuser@localhost ~]$ su -c 'fdisk -l'
omitting empty partition (6)

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xe57de57d

Device Boot Start End Blocks Id System
/dev/sda1 * 63 65898629 32949283+ c W95 FAT32 (LBA)
/dev/sda2 65898630 234436544 84268957+ f W95 Ext'd (LBA)
/dev/sda5 65898693 164136104 49118706 b W95 FAT32
/dev/sda6 165163071 234436544 34636737 7 HPFS/NTFS
As you can see the ancient sda6 and sda7 are now one sda6. The only thing is on it is:
Quote:
[liveuser@localhost ~]$ su -c 'mkdir /mnt/particion'
[liveuser@localhost ~]$ su -c 'mount /dev/sda6 /mnt/particion'
[liveuser@localhost ~]$ ls /mnt/particion
System Volume Information
What can I do?
Must I open a new thread?

Saludos

P.S. At least LVM2 has been erased!

Last edited by Majara; 20th April 2011 at 10:09 AM.
Reply With Quote
  #12  
Old 20th April 2011, 11:32 AM
markkuk Offline
Registered User
 
Join Date: Apr 2005
Location: Finland
Posts: 5,075
windows_xp_2003firefox
Re: F14, GParted and lvm2

Delete /dev/sda6, then run the Fedora installer and create new ex4 partitions in the free space.
Reply With Quote
  #13  
Old 20th April 2011, 05:44 PM
japafi Offline
Registered User
 
Join Date: Mar 2010
Posts: 87
linuxfirefox
Re: F14, GParted and lvm2

Quote:
Originally Posted by stoat View Post
[*]Reboot into linux rescue or another Linux system (I did everything below in linux rescue with the F11 DVD).
[*]Mount the LVM root logical volume.
[*]Mount the ext3 destination partition.
[*]Copy the root logical volume to the ext3 destination partition (cp, rsync, tar, cpio etc.). If you have other logical volumes such as /home, then mount and copy it to the /home directory of the new partition, and so on. Ignore the swap logical partition.
[*]Mount the LVM system's boot partition.
[*]Copy it to the /boot directory of the still mounted ext3 destination partition.
Just curious:
What's the benefit from getting rid of separate /boot partition by copying it to part of root?
Reply With Quote
  #14  
Old 20th April 2011, 06:07 PM
stoat Offline
Registered User
 
Join Date: Jun 2006
Posts: 7,550
linuxfedorafirefox
Re: F14, GParted and lvm2

None really. That was an optional part of the project. I just prefer no extra separate partitions for any of the system directories. The LVM system required a separate boot partition.
Reply With Quote
  #15  
Old 21st April 2011, 12:32 AM
Majara Offline
Registered User
 
Join Date: Dec 2010
Location: Burgos-Spain
Posts: 78
linuxfedorafirefox
Re: F14, GParted and lvm2

Hola!
Markkuk, if I have well undestood I must do:
parted rm /dev/sda6
and then install Fedora, but from a Live CD or from a normal instalation DVD?

Saludos.

P.S.
Finally I have used as root:
#cfdisk /dev/sda
I have created 3 logical partitions, type Linux(83)
500 MB, 2GB and 32 GB(approx.)
Then I have installed a normal F14 DVD installer and the partition mount points as follow:
/boot, swap and /.
F14 is now installed and I can access to Windows.

Problem SOLVED.

Thank you very much everybody.

ˇHasta la vista!

Last edited by Majara; 21st April 2011 at 05:47 PM.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
unable to re-read sda when gparted i start gparted penduleum Using Fedora 8 10th February 2010 04:33 PM
lvm2-2.02-57-1 SlowJet Fedora 13 Development Branch 3 15th January 2010 01:09 AM
LVM2 for F12 - on F11 SlowJet Alpha, Beta & Snapshots Discussions (Fedora 11 Only) 0 22nd May 2009 10:29 PM
Can't use gparted on LVM2 filesystem? nick623 Using Fedora 33 15th September 2007 08:25 AM
Lvm2 Fc3 rudedog830 Using Fedora 0 11th January 2005 12:39 AM


Current GMT-time: 15:47 (Wednesday, 23-04-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat