LVM-Howto [Was : what are the restrictions onbootablepartitions?]

neil neilcuk at aol.com
Fri Apr 30 09:43:12 UTC 2004



ow.mun.heng at wdc.com wrote:

>  
>
>>-----Original Message-----
>>From: neil [mailto:neilcuk at aol.com]
>>Sent: Friday, April 30, 2004 5:26 PM
>>To: For users of Fedora Core releases
>>Subject: Re: LVM-Howto [Was : what are the restrictions
>>onbootablepartitions?]
>>
>>
>>
>>
>>ow.mun.heng at wdc.com wrote:
>>
>>    
>>
>>> 
>>>
>>>      
>>>
>>>>-----Original Message-----
>>>>From: neil [mailto:neilcuk at aol.com]
>>>>
>>>>
>>>>mr700 at globalnet.bg wrote:
>>>>
>>>>   
>>>>
>>>>        
>>>>
>>>>>On Friday 30 April 2004 05:11, Ow Mun Heng wrote:
>>>>>
>>>>>
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>>>>-----Original Message-----
>>>>>>>From: neil [mailto:neilcuk at aol.com]
>>>>>>>Sent: Thursday, April 29, 2004 10:35 PM
>>>>>>>To: For users of Fedora Core releases
>>>>>>>Subject: Re: what are the restrictions on bootable partitions?
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>rpjday at mindspring.com wrote:
>>>>>>>
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>what are the restrictions on where i can install another 
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>linux distro
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>onto my fedora core (actually, FC2-t3) system so that grub 
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>can find it?
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>(even though this is a test version of fedora, this 
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>question actually
>>>>   
>>>>
>>>>        
>>>>
>>>>>>>>refers to FC distros in general.)
>>>>>>>>
>>>>>>>>
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>There are no restrictions other than the boot loader (grub) 
>>>>>>>must be able 
>>>>>>>to read the boot partition.
>>>>>>>
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>typically, for historical reasons, even when i use LVM, i 
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>create a small
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>primary, ext3 filesystem for /boot, and use LVM for the rest 
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>of the drive.
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>is there any compelling reason for doing this anymore?  
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>what's the 
>>>>   
>>>>
>>>>        
>>>>
>>>>>>>>recommended strategy for LVM?  and need for a non-LVM 
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>filesystem on newer
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>>>machines?
>>>>>>>>
>>>>>>>>      
>>>>>>>>
>>>>>>>>           
>>>>>>>>
>>>>>>>>                
>>>>>>>>
>>>>>>>It really depends on what the system will be used for. 
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>Check out the 
>>>>   
>>>>
>>>>        
>>>>
>>>>>>>howto here: http://www.tldp.org/HOWTO/LVM-HOWTO/index.html
>>>>>>>    
>>>>>>>
>>>>>>>         
>>>>>>>
>>>>>>>              
>>>>>>>
>>>>>>I've actually looked through the howto but am still unable 
>>>>>>       
>>>>>>
>>>>>>            
>>>>>>
>>>>to determine
>>>>   
>>>>
>>>>        
>>>>
>>>>>>how to actually create a lvm system. I've recompiled my kernel to 
>>>>>>have the devive mapper as a module and modprobe'ed it.
>>>>>>
>>>>>>When I try to do vgscan it states that the kernel modules 
>>>>>>       
>>>>>>
>>>>>>            
>>>>>>
>>>>are not loaded.
>>>>   
>>>>
>>>>        
>>>>
>>>>>>  
>>>>>>
>>>>>>       
>>>>>>
>>>>>>            
>>>>>>
>>>>>  I don't remember how I did this with RH9 to make it 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>work, but I remember
>>>>   
>>>>
>>>>        
>>>>
>>>>>I played a bit whth modprobe, the LVM tools and the man pages :)
>>>>>
>>>>>
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>>>Please help.
>>>>>>  
>>>>>>
>>>>>>       
>>>>>>
>>>>>>            
>>>>>>
>>>>>http://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual/s
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>ysadmin-guide/ch-lvm.html
>>>>   
>>>>
>>>>        
>>>>
>>>>>http://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual/s
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>ysadmin-guide/ch-lvm-intro.html
>>>>   
>>>>
>>>>        
>>>>
>>>>>http://www.redhat.com/docs/manuals/linux/RHL-8.0-Manual/custo
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>m-guide/ch-lvm.html
>>>>   
>>>>
>>>>        
>>>>
>>>>>http://www.redhat.com/docs/manuals/linux/RHL-8.0-Manual/custo
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>m-guide/ch-lvm-intro.html
>>>>   
>>>>
>>>>        
>>>>
>>>>>http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/custom-
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>guide/ch-lvm-intro.html
>>>>   
>>>>
>>>>        
>>>>
>>>>>...
>>>>>  I did install FC1 with Software Raid 5 and LVM on top of 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>it, but doing so on less
>>>>   
>>>>
>>>>        
>>>>
>>>>>than three physical disks results to up to 5 times slower 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>transfer (because of the
>>>>   
>>>>
>>>>        
>>>>
>>>>>raid). If you have 3 disks read speed increases and the 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>write speed is almost the
>>>>   
>>>>
>>>>        
>>>>
>>>>>same. Using ReiserFS I was able to resize 61G LV to 64G LV 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>without errors. With
>>>>   
>>>>
>>>>        
>>>>
>>>>>ext3 it worked, but fsck.ext3 had a lot of work to do (the 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>partition was ~50G full).
>>>>   
>>>>
>>>>        
>>>>
>>>>>I hope one day online resize will work with bouth and 
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>reiserfs will get more stable
>>>>   
>>>>
>>>>        
>>>>
>>>>>with acl and SELinux support.
>>>>>  http://www.aplawrence.com/Linux/lvm.html
>>>>>  ps: putting the /boot partiton ouside the LVM worked 
>>>>>          
>>>>>
>>fine for me.
>>    
>>
>>>>>
>>>>>     
>>>>>
>>>>>          
>>>>>
>>>>okay - there are a few steps one needs to take to get their 
>>>>system using 
>>>>LVM. It can be tricky to get your brain around at first but 
>>>>it will slot 
>>>>into place. The steps are quite straight forward - even when 
>>>>setting up 
>>>>post install. Here's a brief overview. I'm assuming you can 
>>>>follow the 
>>>>man pages of each of the commands specified - there are a number of 
>>>>options which will be up to you:
>>>>
>>>>as root
>>>>One(a): Make sure you have backed up any important data 
>>>>before trashing 
>>>>your system ;-)
>>>>One: make sure your kernel supports LVM (By default this is 
>>>>supported in 
>>>>FC1)
>>>>Two: create some LVM partitions (of type 8e under fdisk)
>>>>Three: reboot or execute partprobe
>>>>Four: execute vgscan
>>>>Five: use pvcreate to assign your newly typed disks as use 
>>>>within the LVM
>>>>(actually, four and five might be back to front)
>>>>Six: use vgcreate to generate a new volume group (and add 
>>>>some physical 
>>>>volumes tro it)
>>>>Seven: use lvcreate to make your logical volume
>>>>Eight: format your new logical volume
>>>>
>>>>then it's up to you - mount as you like
>>>>
>>>>use e2fsadm to extend and reduce the size of the volume
>>>>
>>>>There is a huge amount of documentation and you should 
>>>>        
>>>>
>>really get to 
>>    
>>
>>>>grips with resizing, adding new PVs etc. Before you start 
>>>>putting useful 
>>>>data on your new LV!
>>>>   
>>>>
>>>>        
>>>>
>>>Thanks for the info Neil. I think I do have a hang of it.. 
>>>      
>>>
>>sort of anyway.
>>    
>>
>>>So, what you're saying is that I have to create the LVM 
>>>      
>>>
>>partition using
>>    
>>
>>>fdisk 
>>>1st before I can get to execute vgscan??
>>>
>>>Currently I just type vgscan and then it complains
>>>vgscan -- LVM driver/module not loaded??
>>>
>>>(it's loaded. The module is named dm-mod.ko right??)
>>>
>>>
>>>
>>>
>>> 
>>>
>>>      
>>>
>>you've got me there. It should be 'lvm-mod' that gets loaded. try a 
>>manual 'modprobe lvm-mod'. If that works try running 'depmod' 
>>to setup 
>>the module dependancies again. Sounds like something is missing the 
>>mark. Create one or two partitions using fdisk and try vgscan again.
>>    
>>
>
>did I mention i was using 2.6 kernel??
>The 2.6 kernel compiled it as dm-mod
>
>Oh well.. I'll try again.. 
>
>
>  
>
ahh - just read through the thread again :-) sorry - I have no 
experience with the test release as of yet - i've been using wget to 
fetch the dvd.iso but there's a two gig limit bug which caught me out a 
few times. I'm still dling FCt3 -- maybe once I have it running I han 
help further. Let me know how you get on in the meantime.

neil
P.S. It's Friday at least :-D





More information about the fedora-list mailing list