[Bug 753366] New: systemd: btrfs.service is a prerequisite for multi-device btrfs partitions
https://bugzilla.novell.com/show_bug.cgi?id=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c0 Summary: systemd: btrfs.service is a prerequisite for multi-device btrfs partitions Classification: openSUSE Product: openSUSE 12.1 Version: Final Platform: x86-64 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-bugs@suse.de Found By: Beta-Customer Blocker: --- A btrfs filesystem generated with # mkfs.btrfs /dev/sd[cdef] Cannot be mounted before `btrfs device scan` is run. Since systemd never executes this, it fails to load fstab entries for such device-spanning FSes. (The fstab entry is just like any other, i.e. /dev/sdc /srv btrfs nofail 0 0 ) -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c Jan Engelhardt <jengelh@medozas.de> changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|bnc-team-screening@forge.pr |fcrozat@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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c1 Frederic Crozat <fcrozat@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|fcrozat@suse.com |bnc-team-screening@forge.pr | |ovo.novell.com --- Comment #1 from Frederic Crozat <fcrozat@suse.com> 2012-03-21 16:50:46 UTC --- I guess btrfsprogs package should ship a .service doing this and this service should be enabled in local-fs-pre.target. But all of this is the responsability of btrfsprogs maintainer. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c kk zhang <kkzhang@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kkzhang@novell.com AssignedTo|bnc-team-screening@forge.pr |dmueller@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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c2 Dirk Mueller <dmueller@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|dmueller@suse.com |dsterba@suse.com --- Comment #2 from Dirk Mueller <dmueller@suse.com> 2012-03-29 10:24:44 CEST --- Reassigning to btrfsprogs maintainer. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c3 DaQ QaD <mirtone_1@yahoo.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mirtone_1@yahoo.com --- Comment #3 from DaQ QaD <mirtone_1@yahoo.com> 2012-08-22 01:11:55 UTC --- I tried adding /sbin/btrfs device scan to boot.localfs right before fstab is mounted, but it didn't work. Did you even figure out a correct place to add the device scan so that boot is not interrupted? -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c4 Jan Engelhardt <jengelh@inai.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gregkh@linux.com --- Comment #4 from Jan Engelhardt <jengelh@inai.de> 2012-08-25 16:39:00 CEST --- /etc/init.d/boot.local served my case. But ideally, device scan should be executed whenever a disk is hotplugged. Someone please Cc the udev maintainer. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c5 Greg Kroah-Hartman <gregkh@linux.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC|gregkh@linux.com | --- Comment #5 from Greg Kroah-Hartman <gregkh@linux.com> 2012-08-25 14:51:59 UTC --- I am not the udev maintainer... -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c6 --- Comment #6 from DaQ QaD <mirtone_1@yahoo.com> 2012-08-30 19:23:35 UTC --- This is the correct solution to this issue: http://forums.opensuse.org/english/get-technical-help-here/install-boot-logi... To summarize: btrfs boot script runs before mount script so module cannot be loaded from the file system. As long as your / is not btrfs, not a problem since you will get dropped into super user mode where you can load the module by hand. The correct solution: Add btrfs module to initrd so that it is loaded into initial ramdisk. Details are on that forum entry. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c7 DaQ QaD <mirtone_1@yahoo.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugzilla.novell.com | |/show_bug.cgi?id=727383 --- Comment #7 from DaQ QaD <mirtone_1@yahoo.com> 2012-08-30 19:36:11 UTC --- BTW, this seems like a duplicate of https://bugzilla.novell.com/show_bug.cgi?id=727383 -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c8 --- Comment #8 from Jan Engelhardt <jengelh@inai.de> 2012-08-30 21:39:30 CEST --- The problem here is not module loading, it's that btrfs mount will fail if the btrfs core does not know all devices. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c9 --- Comment #9 from DaQ QaD <mirtone_1@yahoo.com> 2012-08-30 21:51:36 UTC --- I don't think that's correct. Loading module should scan the devices. At the same time, scanning devices will load the module, but only if the file system containing the module is already mounted (and is not btrfs.) I think the big problem is that module is not loaded when it is supposed to. You can test it by removing your boot.local modification and adding btrfs to initrd as recommended in the forum entry linked above. I didn't need to modify any scrips or force any device scans after I added btrfs module to ramdisk. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c10 --- Comment #10 from Jan Engelhardt <jengelh@inai.de> 2012-08-31 01:14:26 CEST --- Because "btrfs" is listed in fstab as type for the fs, it will already be autoloaded by the kernel when attempting to mount /dev/sdf.
Loading module should scan the devices.
Have you actually tested your theories? I doubt it. As a result of `btrfs dev scan`, dmesg will show "device label ... devid ... transid ... /dev/sdX`. No such messages are emitted when loading btrfs.ko. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c11 --- Comment #11 from DaQ QaD <mirtone_1@yahoo.com> 2012-08-30 23:34:53 UTC --- (In reply to comment #10)
Because "btrfs" is listed in fstab as type for the fs, it will already be autoloaded by the kernel when attempting to mount /dev/sdf.
That wasn't true in my case. I had btrfs in fstab, yet module wasn't loading.
Loading module should scan the devices.
Have you actually tested your theories? I doubt it. As a result of `btrfs dev scan`, dmesg will show "device label ... devid ... transid ... /dev/sdX`. No such messages are emitted when loading btrfs.ko.
My logic was that loading the module fixed it for me without having to run 'btrfs dev scan' I also mount FS with multiple devices. I did not actually read the code for btrfs module to confirm this. Do you have any evidence that shows my test is invalid? Just try it before getting angry. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c12 Jan Engelhardt <jengelh@inai.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dsterba@suse.com --- Comment #12 from Jan Engelhardt <jengelh@inai.de> 2012-08-31 01:51:46 CEST --- Daniel Sterba, there should be a udev rule calling `btrfs dev scan $blkdev` (ignore return code) whenever there is a ADD BLOCK event. Josef Bacik says this is what should be done - and which is what Fedora does. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c13 --- Comment #13 from David Sterba <dsterba@suse.com> 2012-09-03 17:54:56 CEST --- (In reply to comment #6)
This is the correct solution to this issue: http://forums.opensuse.org/english/get-technical-help-here/install-boot-logi...
To summarize: btrfs boot script runs before mount script so module cannot be loaded from the file system. As long as your / is not btrfs, not a problem since you will get dropped into super user mode where you can load the module by hand.
The correct solution: Add btrfs module to initrd so that it is loaded into initial ramdisk.
Details are on that forum entry.
I've read through the forum post, it mentions several problems with multi-device btrfs and boot. Summary: * missing module in initrd despite btrfs feature is detected => really a bug (missing directive in mkinitrd script), already fixed, I'll check if it's actually released via maintenance update * devices not detected during boot, ie. the missing 'btrfs device scan' => unless the module is not loaded, the scan does not happen; formerly the scan step was not done at all, should be ok now there's a difference when scanning root device and non-root devices: * root: all steps need to be done from within the initrd environment (like setting up MD/DM/crypto, then scan and mount) * non-root filesystems may depend on post-initrd setup of MD/DM/crypto devices and this cannot be resolved from initrd at all => needs udev rules to detect any new blockdevice (as suggested in comment 12) I'll push out updated progs (udev rules and other progs fixes) soon. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c14 Philipp Woelfel <woelfel@gmx.net> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |woelfel@gmx.net --- Comment #14 from Philipp Woelfel <woelfel@gmx.net> 2012-10-13 01:02:15 UTC --- Same bug exists on openSUSE 12.2 -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c15 Jan Engelhardt <jengelh@inai.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|Basesystem |Basesystem Product|openSUSE 12.1 |openSUSE 12.2 --- Comment #15 from Jan Engelhardt <jengelh@inai.de> 2012-10-13 03:48:45 CEST --- It certainly is. -- 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=753366 https://bugzilla.novell.com/show_bug.cgi?id=753366#c16 Jeff Mahoney <jeffm@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |WONTFIX --- Comment #16 from Jeff Mahoney <jeffm@suse.com> 2014-08-07 15:31:27 EDT --- This report is against openSUSE 12.2 which is no longer under maintenance. If you are able to reproduce it with openSUSE 13.1 or openSUSE Factory, please re-open and reset the the "Product" field to the appropriate release. [Note: This should be fixed via the udev rules that call btrfs device ready when a partition is probed.] -- 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