LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-05-2012, 02:59 AM   #1
blue_k
Member
 
Registered: Apr 2011
Distribution: Slackware64 14.0 & Slackware 13.37
Posts: 121

Rep: Reputation: 5
A few LVM questions.


Hi,

I was just wondering do I put my boot partition in the LVM, or make a normal partition for it? Also, following the instructions for LVM included on the disk, when I generate the initrd, does this use the generic kernel, like the one in the initrd readme file, or the huge one?

Thank you
 
Old 04-05-2012, 03:05 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
/boot would be outside of LVM. Not sure what you're referring to by the "huge one" but the initrds are used as per the matching kernel package, they aren't rebuilt during the install
 
Old 04-05-2012, 03:13 AM   #3
blue_k
Member
 
Registered: Apr 2011
Distribution: Slackware64 14.0 & Slackware 13.37
Posts: 121

Original Poster
Rep: Reputation: 5
Thank you for answering. In the LVM readme, it states to run this
Code:
mkinitrd -c -k 2.6.37.6-smp -m ext3 -f ext3 -r /dev/myvg/root -L
After the install is finished. Where as the initrd readme says to do this first before running the mkinitrd command.
Code:
installpkg kernel-generic-2.6.37.6-i686-1.tgz
installpkg kernel-modules-2.6.37.6-i686-1.tgz
installpkg mkinitrd-1.1.0-i486-1.tgz
I am wondering does the LVM instructions use the kernel-generic-2.6.37.6-i686-1.tgz and the kernel-modules-2.6.37.6-i686-1.tgz packages to make it's initrd?
 
Old 04-05-2012, 03:16 AM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
My apologies, I didn't realize this was in Slackware, and your profile listed CentOS 6.2. LVM should have no relation whatsoever to the running kernel though (save for LVM support which shouldn't be "interesting"

Last edited by acid_kewpie; 04-05-2012 at 03:18 AM.
 
Old 04-05-2012, 03:20 AM   #5
blue_k
Member
 
Registered: Apr 2011
Distribution: Slackware64 14.0 & Slackware 13.37
Posts: 121

Original Poster
Rep: Reputation: 5
Sorry for not making it clearer, yes I am trying to install Slackware64 13.37. So will it just use whatever kernel is running? So I would still have to go through the steps in the initrd readme to get the "generic" kernel after install correct?
 
Old 04-05-2012, 03:37 AM   #6
tramni1980
Member
 
Registered: Jul 2006
Location: Köln, Germany
Distribution: Slackware64-14.2 & -current, DragonFly BSD, OpenBSD
Posts: 819

Rep: Reputation: 55
Hello blue_k,

There is no problem to make all your partitions on LVM, as well as /boot. Just follow the step by step instructions from the LVM-Howto (the file name is not exactly the same) file on the installation CD. If you have any further questions, do not hesitate to ask.
 
Old 04-05-2012, 03:49 AM   #7
TommyC7
Member
 
Registered: Mar 2012
Distribution: Slackware, CentOS, OpenBSD, FreeBSD
Posts: 530

Rep: Reputation: Disabled
First off, you will want /boot on it's own primary partition. The rest of Linux can be on its own Logical Partition or Primary Partition, it doesn't care but make sure /boot is on a primary partition..

Perhaps you should use the mkinitrd_script_generator:

Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh -r
If it generates the script you like, you can simply use:
Code:
$( /usr/share/mkinitrd/mkinitrd_command_generator.sh -r )
`/usr/share/mkinitrd/mkinitrd_command_generator.sh -r`
Either one should work. They will run the command the mkinitrd_command_generator script creates for you.

The command you posted will assume you want the initrd.gz for the 2.6.37.6-smp kernel and assumes the root partition is ext3, but you can make it for just about any kernel you want. I would follow the README_LVM.txt instructions. At least I did and I had a perfectly working system and that command generator even picked up the root filesystem too. No matter which kernel you choose -- just make sure it exists!

Last edited by TommyC7; 04-05-2012 at 03:51 AM.
 
Old 04-05-2012, 04:50 AM   #8
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,897

Rep: Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018Reputation: 5018
Lilo can find the initrd and vmlinuz files even if they are on a /boot that is within an LVM LV, but only if you're not doing an encrypted lvm setup. I'm not certain, but I believe with the grub bootloader these files need to be outside of LVM.

However, if you're going to leave /boot within the LVM, you might as well not have a boot lv at all and just leave the /boot directory in the rootfs. There's really no good reason to separate it in this situation.

Please bear in mind that you'll still need a primary partition to install the lilo bootcode to (unless you put it directly in the MBR - which is something I prefer not to do) and having /boot in a primary partition outside of lvm caters to this need and seems kind of a logical place to put it. It also provides you with a degree of extra flexibility (choosing to use grub or encrypted PVs in future).

You don't have to run 'generic' if you're using an initrd, but it makes sense to do so and I generally recommend running generic+initrd over the monolithic 'huge' kernels.


I'm with Tommy on this one: if you can spare a primary partition then it's a good choice.
 
Old 04-05-2012, 05:02 AM   #9
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
In a LVM setup, you can have your /boot directory inside the LVM, it does not have to be a separate non-LVM partition. The init script inside the initrd.gz file which you have to create, is smart enough for this to work properly.

The only case where /boot needs its own separate partition is when you do a full disk encryption of your Slackware installation (including the root partition).

Eric
 
Old 04-05-2012, 01:31 PM   #10
TommyC7
Member
 
Registered: Mar 2012
Distribution: Slackware, CentOS, OpenBSD, FreeBSD
Posts: 530

Rep: Reputation: Disabled
Heh, whoops. Sorry about telling you /boot had to have it's own primary partition. ^^
 
Old 04-10-2012, 03:30 AM   #11
blue_k
Member
 
Registered: Apr 2011
Distribution: Slackware64 14.0 & Slackware 13.37
Posts: 121

Original Poster
Rep: Reputation: 5
Alright, thanks.
 
Old 04-12-2012, 07:13 PM   #12
ricky_cardo
Member
 
Registered: Feb 2006
Location: Syracuse, NY
Distribution: Slackware64-Current
Posts: 210

Rep: Reputation: 76
I did notice some weird behavior having /boot on an LVM that spanned 2 physical volumes. Lilo failed to install. When I put /boot on a separate partition outside the LVM things were cool again. I wish I captured the error I received, but it was some time ago. I was pretty sure I followed the directions to the T. Anyone else have success with 2 physical drives one LVM and /boot on there too? (again LVM on one physical drive with /boot included no problem; but when I added a 2nd physical drive lilo failed to install. I found splitting the /boot to a separate ext2 partition resolved)

Next Fresh load of Slackware I might try it again. (any pointers anyone?)
 
  


Reply



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
lvm questions tramni1980 Slackware 31 09-17-2009 04:46 AM
Using LVM on RAID, some questions [GOD]Anck Slackware 2 03-16-2008 11:07 AM
software raid5 + LVM and other questions slackman Linux - Server 0 05-08-2007 02:54 AM
Basic LVM Questions. hondaman Linux - Software 0 08-24-2006 04:54 PM
lvm questions billehunt Linux - Software 4 06-15-2005 03:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 11:20 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
Open Source Consulting | Domain Registration