Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 118275 - LVM not started with sys-apps/baselayout-1.12.0_pre13-r1
Summary: LVM not started with sys-apps/baselayout-1.12.0_pre13-r1
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Eric Edgar (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 120265
  Show dependency tree
 
Reported: 2006-01-08 03:50 UTC by gentoo-bugzilla.10.mailinglists
Modified: 2006-04-18 06:16 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gentoo-bugzilla.10.mailinglists 2006-01-08 03:50:19 UTC
As the headline states, LVM does not work with this release of the baselayout. Comparing /etc/init.d/checkfs with the previous version I found that following lines are missing:
--snip--
	# Start RAID/LVM/EVMS/DM volumes for /usr, /var, etc.
	# NOTE: this should be done *before* mounting anything
	[[ -z ${CDBOOT} ]] && start_volumes
--snip--
Comment 1 SpanKY gentoo-dev 2006-01-08 03:53:23 UTC
you neglected to post any real info

the lines arent missing, they've been moved to /sbin/rc
Comment 2 gentoo-bugzilla.10.mailinglists 2006-01-09 08:23:34 UTC
ok, saw that now that you mentioned it. I only checked /etc/init.d/* for it. But there is definitly a problem here. When executed from /sbin/rc I get:
"locking type1 initialization failed" and later on of course checkfs fails since the LVM drives are not available.

When adding the call to checkfs it works.

(In reply to comment #1)
> you neglected to post any real info
> 
> the lines arent missing, they've been moved to /sbin/rc
> 
Comment 3 SpanKY gentoo-dev 2006-01-09 16:20:33 UTC
no idea what that error means
Comment 4 gentoo-bugzilla.10.mailinglists 2006-01-10 02:20:38 UTC
Two things I could imagine here. Could it be that udev did not yet create the /dev/mapper/control device by the time the start_volumes is called? Second could it be that / is not yet writable, since lvm wants to write to /etc/lvm.

(In reply to comment #3)
> no idea what that error means
> 
Comment 5 RB 2006-01-11 17:45:00 UTC
I had the same problem with MD/cryptfs/LVM & backed down to 1.11.14 to get things going again.

I have a custom RC_VOLUME_ORDER="raid dm dm-crypt lvm", but that's just to make sure my LVM-on-dm-crypt-on-md starts and stops in the right order.
Comment 6 gentoo-bugzilla.10.mailinglists 2006-01-12 09:07:55 UTC
Sorry for providing so little information on the issue, but I was pretty busy. Finally I found the time to investigate a bit more. I added calls to start_volumes to checkroot right before mounting / rw and after that. As I mentioned in #3 it proved that running start_volumes requires / to be mounted rw.

(In reply to comment #3)
> no idea what that error means
> 
Comment 7 Rod Smith 2006-01-12 18:54:52 UTC
I've had similar problems with LVM, but in my case LVM would start about 1/3 to 1/2 the time and fail to start the rest of the time. It seems to be related to loading of kernel drivers for the disks. I've got both an SATA disk and a PATA disk managed by a VIA chipset in my motherboard. I'd had the SATA driver (in the SCSI section of the kernel) compiled into the main kernel file and the ATA driver as a module. I did it this way because in earlier kernels (circa 2.6.6), the ATA driver took precedence and tried to control the SATA drive, but I wanted the SATA driver to handle it, so I did it this way. In my case, though, it seems that the SATA driver wasn't being reliably loaded, at least not in time for the LVM startup commands to work correctly. With a 2.6.15 kernel, compiling both the ATA and SATA drivers into the kernel works correctly, and also gives the SATA driver control of the SATA disk.
Comment 8 Sander Sweers 2006-01-22 08:23:04 UTC
(In reply to comment #6)
> Sorry for providing so little information on the issue, but I was pretty busy.
> Finally I found the time to investigate a bit more. I added calls to
> start_volumes to checkroot right before mounting / rw and after that. As I
> mentioned in #3 it proved that running start_volumes requires / to be mounted
> rw.

This should not happen because vgchange is started with --ignorelockingfailure.

The exact error message i am getting is "locking disabled". I sound to me that vgchange is ignoring the --ignorelockingfailure option.
Comment 9 vicaya 2006-01-23 06:36:11 UTC
Doesn't work with 1.12.0_pre15 either... The problem seems to be that vgscan/vgchange with udev would modify /dev (and create symlink in /dev/vg/* to device/mapper/* etc.), while / is mounted read-only. 

quick hack/workaround: move start_volumes from /sbin/rc to /etc/init.d/checkroot after remounting root rw. At least made my laptop boot properly and let me log on to write this note.

Comment 10 SpanKY gentoo-dev 2006-01-23 07:10:57 UTC
> Doesn't work with 1.12.0_pre15 either... The problem seems to be that
> vgscan/vgchange with udev would modify /dev (and create symlink in /dev/vg/* to
> device/mapper/* etc.), while / is mounted read-only. 

/ has nothing to do with /dev

udev mounts a writable ramdisk on /dev so it doesnt matter whether / is still readonly
Comment 11 vicaya 2006-01-24 06:52:09 UTC
Yeah, scratch comment #9. Looks like adding --ignorelockingfailure to both vgscan and vgchange in /lib/rcscripts/addon/lvm-start.sh would work with baselayout 1.12.0_pre15 and gentoo-sources 2.6.14-r5 (amd64)

Comment 12 gentoo-bugzilla.10.mailinglists 2006-01-25 00:57:42 UTC
Just wanted to note that for me the issue is resolved. Please close the bug as soon as everybody in here got his things working.

(In reply to comment #6)
> Sorry for providing so little information on the issue, but I was pretty busy.
> Finally I found the time to investigate a bit more. I added calls to
> start_volumes to checkroot right before mounting / rw and after that. As I
> mentioned in #3 it proved that running start_volumes requires / to be mounted
> rw.
> 
> (In reply to comment #3)
> > no idea what that error means
> > 
> 
Comment 13 SpanKY gentoo-dev 2006-01-25 19:11:48 UTC
Eric: check out comment #11 please
Comment 14 Eric Edgar (RETIRED) gentoo-dev 2006-01-26 07:26:44 UTC
I am not sure why you dont have this .. --ignorelockingfailure has been in the file for sometime.
Comment 15 Laurento Frittella (mrfree) 2006-02-05 03:40:35 UTC
Same problem here with baselayout-1.12.0_pre15-r1 :(

My system doesn't boot correctly... lvm devices aren't inizialized at boot, I need to manually run "vgchange -a y" to mount /var /usr /home

and adding --ignorelockingfailure to both
vgscan and vgchange in /lib/rcscripts/addon/lvm-start.sh doesn't work for me!!!
Comment 16 Laurento Frittella (mrfree) 2006-02-05 05:21:16 UTC
During boot this error appears:
   Locking type 1 initialisation failed

I need to entrer interactive mode... switch to console and run

# vgchange -a y
# mount -a

then I can continue booting the system correctly
Comment 17 Laurento Frittella (mrfree) 2006-02-13 02:04:44 UTC
There aren't any news guys? :(
Comment 18 RB 2006-02-13 04:29:28 UTC
Nope, still broken AFAICT.  Tried 1.12.0_pre15-r1 on my LVM-heavy server this weekend and didn't find any improvement.
Comment 19 Laurento Frittella (mrfree) 2006-02-25 08:45:56 UTC
Shit, probably my mistake :)

I've recompiled 2.6.15-gentoo-r1 using genkernel with lvm2 option enabled, now all works well!!!
Comment 20 RB 2006-02-26 09:18:26 UTC
My concerns have been addressed - running 1.12.0_pre16-r1 and everything seems to work right for me.
Comment 21 Daniel Webert 2006-03-04 19:13:47 UTC
can we close this? - using w/ sys-apps/baselayout-1.12.0_pre16-r3 no probs
Comment 22 Laurento Frittella (mrfree) 2006-03-05 04:26:36 UTC
no more probs here
Comment 23 B. Keroack 2006-04-17 10:26:57 UTC
Everything seems OK with 1.12.0_pre17-r2.
Comment 24 SpanKY gentoo-dev 2006-04-18 06:16:13 UTC
k