On Fri, Feb 04, 2005 at 09:03:19AM +0100, Benedict Verheyen wrote: > Pigeon wrote: > > The LVM tools need a writable /etc or nothing works. When you get that > > error, / is still the initrd, which is a read-only filesystem because > > it's cramfs. You can either do some jiggery-pokery to make an initrd > > of a different fs type which can be mounted writable, or you can do > > some different jiggery-pokery to provide a writable /etc. I chose to > > provide a writable /etc; see the bit after the comment '# Make a > > writable /etc for lvmtab' in the lvm-init script on my site. > > OK, so if i would add your script i have a chance that it works. Anyway, > is there a good reason > for the mkinitrd script to behave this way (not mounting /etc/ > writeable) or can that also > be considered a bug? IMO if the script says it's able to handle lvm, > then it can be considered > a bug. /etc is not writable because at that stage the root fs is still the initrd, which is a cramfs filesystem, and cramfs filesystems are not writable. The way I read the mkinitrd documentation, it's clear that it's up to the user to provide scripts to deal with this kind of situation, so it's not a bug. Bombing out with "this kernel does not support LVM" when that is not the case is a bug though IMO. > > Now, I was doing a bit of aimless poking about and I discovered that > > in /lib/lvm-10 there is a script called lvmcreate_initrd, with its own > > man page an' all, whose purpose in life is to create initrds for root > > on LVM. It might be that this would save a lot of trouble. I haven't > > tried it, though, because the machine I was setting up the LVM root on > > is a server which is now live (from my point of view) > > Yep, i used that for the initrd of my 2.4.24 kernel. However, lvm2 > doesn't provide such a script. Ug, how dead and chewed. > I found a version of the script that reportedly should work with lvm2 > http://poochiereds.net/svn/lvm2/ > Problem is that it doesn't support modules > 3) This initrd image does not support modules. > Anyway, I hope it will work. I don't know why they don't provide such a > script standard in the > lvm2 package. Since having this problem, i've seen loads of mails of > people struggling with this. > > Thanks for your ongoing help, really appreciate it! No problem :-) That script certainly looks worth a shot; looks like it does handle modules if you explicitly tell it what modules and it'll load them if you explicitly tell it to include /etc/modules. Also seems to handle some device mapper issues which may be connected with your "expected 0" error, though I'm guessing a bit there. -- Pigeon Be kind to pigeons Get my GPG key here: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x21C61F7F
Attachment:
signature.asc
Description: Digital signature