[Bug 716240] New: cryptsetup: fails to recognize certain dm names
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c0 Summary: cryptsetup: fails to recognize certain dm names Classification: openSUSE Product: openSUSE 12.1 Version: Factory Platform: All OS/Version: Linux Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: jengelh@medozas.de QAContact: qa@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:6.0) Gecko/20100101 Firefox/6.0 cryptsetup's mkinitrd scripts cannot deal with dm names which have a dash in them (and perhaps other characters). mkinitrd does not catch this. Reproducible: Always Steps to Reproduce: 1. make an encrypted root partition (e.g. boot rescue system, cryptsetup format and so on, then copy files from an old system) and use a dmname with a dash, e.g. "foo-bar" 2. run mkinitrd within the system Actual Results: When running mkinitrd, there is no notification of LUKS. (#dbg is output from echoes I added, and reflects the state of the same-name variables) yaguchi:/lib/mkinitrd/scripts # mkinitrd Scanning scripts ... Resolve dependencies ... Install symlinks in /lib/mkinitrd/setup ... Install symlinks in /lib/mkinitrd/boot ... Kernel image: /boot/vmlinuz-2.6.37.6-jng135-desktop Initrd image: /boot/initrd-2.6.37.6-jng135-desktop Root device: /dev/mapper/yaguchi-root (mounted on / as ext4) # dbg: bd=/dev/mapper/yaguchi-root deps=/dev/sda3 # dbg: yaguchi-root already handled # dbg: bd=/dev/mapper/yaguchi-root deps=/dev/sda3 # dbg: yaguchi-root already handled modprobe: Module kernel not found. WARNING: no dependencies for kernel module 'kernel' found. Kernel Modules: sata_sil thkd dm-mod dm-crypt dm-snapshot crc16 jbd2 mbcache ext4 nls_base usbcore ohci-hcd ehci-hcd uhci-hcd hid usbhid cbc aes-i586 sha256_generic Features: dm usb luks Expected Results: This is what I get without a dash: # mkinitrd Kernel image: /boot/vmlinuz-2.6.37.6-jng135-desktop Initrd image: /boot/initrd-2.6.37.6-jng135-desktop Root device: /dev/mapper/yroot (mounted on / as ext4) # dbg: luks_name=yroot enabling LUKS support for /dev/sda3 (yroot) # dbg: luks_name=yroot # dbg: yroot already handled modprobe: Module kernel not found. WARNING: no dependencies for kernel module 'kernel' found. Kernel Modules: sata_sil thkd dm-mod dm-crypt dm-snapshot crc16 jbd2 mbcache ext4 nls_base usbcore ohci-hcd ehci-hcd uhci-hcd hid usbhid cbc aes-i586 sha256_generic Features: dm block usb luks Occurs with openSUSE 11.4 and 12.1. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c zj jia <zjjia@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |zjjia@suse.com AssignedTo|bnc-team-screening@forge.pr |lnussel@suse.com |ovo.novell.com | -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c1 Ludwig Nussel <lnussel@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |NEEDINFO InfoProvider| |jengelh@medozas.de --- Comment #1 from Ludwig Nussel <lnussel@suse.com> 2011-09-09 14:05:42 CEST --- works fine for me on a fresh 12.1 Factory install where YaST set up the root partition. Tried "dmsetup rename system-root foo-bar" and mkintrd still works. So maybe your setup is unusal. try setting mkinitrd_luks_debug=1 before running mkinitrd. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c2 --- Comment #2 from Jan Engelhardt <jengelh@medozas.de> 2011-09-09 12:20:20 UTC --- Well besides dmsetup rename you also have to adjust fstab (if need be) and crypttab. BTW, it just can't work, simply because of things like eval: eval "luks_${name}_device=\"\$physdev\"" and if $name contains a dash you are essentially doing in shell luks_a-b_device=foo which, on bash-4, is regarded as an error. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c3 Ludwig Nussel <lnussel@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |ASSIGNED InfoProvider|jengelh@medozas.de | --- Comment #3 from Ludwig Nussel <lnussel@suse.com> 2011-09-09 14:42:04 CEST --- that could be fixed by sanitizing the name. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c4 --- Comment #4 from Bernhard Wiedemann <bwiedemann@suse.com> 2012-06-15 15:00:07 CEST --- This is an autogenerated message for OBS integration: This bug (716240) was mentioned in https://build.opensuse.org/request/show/125109 Factory / cryptsetup -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=716240 https://bugzilla.novell.com/show_bug.cgi?id=716240#c5 Ludwig Nussel <lnussel@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |FIXED --- Comment #5 from Ludwig Nussel <lnussel@suse.com> 2012-06-18 09:20:30 CEST --- fixed -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com