Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 156009 - genkernel should check that /etc/lvm/lvm.conf is valid before merging it to initrd
Summary: genkernel should check that /etc/lvm/lvm.conf is valid before merging it to i...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Genkernel Maintainers
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2006-11-23 02:10 UTC by Petteri Räty (RETIRED)
Modified: 2007-04-05 15:00 UTC (History)
0 users

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 Petteri Räty (RETIRED) gentoo-dev 2006-11-23 02:10:45 UTC
I recently stumbled onto a problem where I had typoed my lvm.conf in the chroot. When booting the machine I found out that genkernel happily used my typoed lvm.conf in the initrd. You can use lvm dumpconfig to detect if lvm.conf is valid.

rj ~ # lvm dumpconfig
  Parse error at line 79: expected a value
  Failed to load config file /etc/lvm/lvm.conf
rj ~ # echo $?
255
rj ~ # lvm dumpconfig
devices {
        dir="/dev"
        scan="/dev"
        filter="r|/dev/cdrom|"
        cache="/etc/lvm/.cache"
        write_cache_state=1
        sysfs_scan=1
        md_component_detection=1
}
activation {
        missing_stripe_filler="/dev/ioerror"
        reserved_stack=256
        reserved_memory=8192
        process_priority=-18
        mirror_region_size=512
        mirror_log_fault_policy="allocate"
        mirror_device_fault_policy="remove"
}
global {
        umask=63
        test=0
        activation=1
        proc="/proc"
        locking_type=1
        locking_dir="/var/lock/lvm"
}
shell {
        history_size=100
}
backup {
        backup=1
        backup_dir="/etc/lvm/backup"
        archive=1
        archive_dir="/etc/lvm/archive"
        retain_min=10
        retain_days=30
}
log {
        verbose=0
        syslog=1
        overwrite=0
        level=0
        indent=1
        command_names=0
        prefix="  "
}
rj ~ # echo $?
0
Comment 1 Chris Gianelloni (RETIRED) gentoo-dev 2006-12-13 09:23:51 UTC
Ehh... ok... got a patch?
Comment 2 Chris Gianelloni (RETIRED) gentoo-dev 2007-03-14 01:30:04 UTC
OK, I think I've fixed this in subversion/3.4.7_pre5
Comment 3 Chris Gianelloni (RETIRED) gentoo-dev 2007-04-05 15:00:59 UTC
This is fixed in genkernel 3.4.7 which is now in the tree.