Re: grub2-probe confused by double bind mount?
On Tue, Aug 8, 2017 at 2:04 AM, Vladimir 'phcoder' Serbinenkowrote: > Did you mount /proc ? What is the contents of /proc/self/mountinfo ? /proc is mounted. The way these ostree environments get assembled is super messy, and I can't be sure I'm truly assembling it exactly as the OS installer does, because the installer isn't logging the chroot commands. However, doing my own chroot to get a cat /proc/self/mountinfo from inside the chroot, I get a grub-probe fail only with Btrfs not ext4. This is mountinfo inside the chroot, with Btrfs installation. https://pastebin.com/d2twu4qi This is mountinfo inside the chroot, with ext4 installation. https://pastebin.com/vqyJiNz4 This is interleaving the two mountinfo outputs, Btrfs (top line) and ext4 (bottom line), deleting the duplicates where the two match. https://pastebin.com/nYX71ckR OK so there are a few discrepancies I'm seeing in this 3rd paste showing comparisons: 1. Neither one has / in the fifth column, for mountpoint. And yet this doesn't cause a grub-probe problem in the ext4 case. Lines 7 and 8. 2. Each Btrfs case has /root/ as a prefix for column 4, that's the name of the subvolume the installation is put into, so it should be OK. grub2-probe doesn't have a problem with this when it's a conventional non-ostree installation. 3. The one thing that is kinda screwy is the mountinfo for btrfs mount options, shows a bogus subvol= path. The kernel code shows the correct subvolid= in each case, but the multiple bind mounts ostree is doing is causing the kernel code to *assume* those are subvolumes when in fact they are not. There is only one legit subvolume on this installation and that's a subvolume named "root". So all the other subvol= paths are not really subvolumes. I hope that makes sense... If grub-probe does not parse for subvol= then that's not likely the problem here. -- Chris Murphy ___ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel
Re: grub2-probe confused by double bind mount?
Did you mount /proc ? What is the contents of /proc/self/mountinfo ? On Tue, Aug 8, 2017, 06:35 Chris Murphywrote: > On Mon, Aug 7, 2017 at 9:09 AM, Vladimir 'phcoder' Serbinenko > wrote: > > Upstream doesn't use grub2 prefix. Please try with latest upstream and > make > > sure it's compiled with libdevmapper > > > Same result with current git as of today. > > [chris@f26wnuc grub]$ ./configure --build=x86_64 --host=x86_64 > --with-platform=efi > > > GRUB2 will be compiled with following components: > Platform: x86_64-efi > With devmapper support: Yes > > And in the chroot: > > [root@localhost /]# /usr/local/sbin/grub-probe -V > /usr/local/sbin/grub-probe (GRUB) 2.03 > [root@localhost /]# /usr/local/sbin/grub-probe -v / > /usr/local/sbin/grub-probe: info: cannot open `/boot/grub/device.map': > No such file or directory. > /usr/local/sbin/grub-probe: info: changing current directory to /dev. > /usr/local/sbin/grub-probe: info: changing current directory to v4l. > /usr/local/sbin/grub-probe: info: changing current directory to by-path. > /usr/local/sbin/grub-probe: info: changing current directory to by-id. > /usr/local/sbin/grub-probe: info: changing current directory to dri. > /usr/local/sbin/grub-probe: info: changing current directory to by-path. > /usr/local/sbin/grub-probe: info: changing current directory to snd. > /usr/local/sbin/grub-probe: info: changing current directory to by-path. > /usr/local/sbin/grub-probe: info: changing current directory to vfio. > /usr/local/sbin/grub-probe: info: changing current directory to mqueue. > /usr/local/sbin/grub-probe: info: changing current directory to hugepages. > /usr/local/sbin/grub-probe: info: changing current directory to disk. > /usr/local/sbin/grub-probe: info: changing current directory to by-uuid. > /usr/local/sbin/grub-probe: info: changing current directory to > by-partuuid. > /usr/local/sbin/grub-probe: info: changing current directory to > by-partlabel. > /usr/local/sbin/grub-probe: info: changing current directory to by-label. > /usr/local/sbin/grub-probe: info: changing current directory to by-path. > /usr/local/sbin/grub-probe: info: changing current directory to by-id. > /usr/local/sbin/grub-probe: info: changing current directory to block. > /usr/local/sbin/grub-probe: info: changing current directory to usb. > /usr/local/sbin/grub-probe: info: changing current directory to char. > /usr/local/sbin/grub-probe: info: changing current directory to net. > /usr/local/sbin/grub-probe: info: changing current directory to pts. > /usr/local/sbin/grub-probe: info: changing current directory to shm. > /usr/local/sbin/grub-probe: info: changing current directory to bsg. > /usr/local/sbin/grub-probe: info: changing current directory to mapper. > /usr/local/sbin/grub-probe: info: changing current directory to input. > /usr/local/sbin/grub-probe: info: changing current directory to by-path. > /usr/local/sbin/grub-probe: info: changing current directory to by-id. > /usr/local/sbin/grub-probe: info: changing current directory to bus. > /usr/local/sbin/grub-probe: info: changing current directory to usb. > /usr/local/sbin/grub-probe: info: changing current directory to 004. > /usr/local/sbin/grub-probe: info: changing current directory to 003. > /usr/local/sbin/grub-probe: info: changing current directory to 002. > /usr/local/sbin/grub-probe: info: changing current directory to 001. > /usr/local/sbin/grub-probe: info: changing current directory to raw. > /usr/local/sbin/grub-probe: info: changing current directory to cpu. > /usr/local/sbin/grub-probe: info: changing current directory to 7. > /usr/local/sbin/grub-probe: info: changing current directory to 6. > /usr/local/sbin/grub-probe: info: changing current directory to 5. > /usr/local/sbin/grub-probe: info: changing current directory to 4. > /usr/local/sbin/grub-probe: info: changing current directory to 3. > /usr/local/sbin/grub-probe: info: changing current directory to 2. > /usr/local/sbin/grub-probe: info: changing current directory to 1. > /usr/local/sbin/grub-probe: info: changing current directory to 0. > /usr/local/sbin/grub-probe: error: cannot find a device for / (is /dev > mounted?). > [root@localhost /]# > > > > > > > -- > Chris Murphy > ___ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel
Re: grub2-probe confused by double bind mount?
On Mon, Aug 7, 2017 at 9:09 AM, Vladimir 'phcoder' Serbinenkowrote: > Upstream doesn't use grub2 prefix. Please try with latest upstream and make > sure it's compiled with libdevmapper Same result with current git as of today. [chris@f26wnuc grub]$ ./configure --build=x86_64 --host=x86_64 --with-platform=efi GRUB2 will be compiled with following components: Platform: x86_64-efi With devmapper support: Yes And in the chroot: [root@localhost /]# /usr/local/sbin/grub-probe -V /usr/local/sbin/grub-probe (GRUB) 2.03 [root@localhost /]# /usr/local/sbin/grub-probe -v / /usr/local/sbin/grub-probe: info: cannot open `/boot/grub/device.map': No such file or directory. /usr/local/sbin/grub-probe: info: changing current directory to /dev. /usr/local/sbin/grub-probe: info: changing current directory to v4l. /usr/local/sbin/grub-probe: info: changing current directory to by-path. /usr/local/sbin/grub-probe: info: changing current directory to by-id. /usr/local/sbin/grub-probe: info: changing current directory to dri. /usr/local/sbin/grub-probe: info: changing current directory to by-path. /usr/local/sbin/grub-probe: info: changing current directory to snd. /usr/local/sbin/grub-probe: info: changing current directory to by-path. /usr/local/sbin/grub-probe: info: changing current directory to vfio. /usr/local/sbin/grub-probe: info: changing current directory to mqueue. /usr/local/sbin/grub-probe: info: changing current directory to hugepages. /usr/local/sbin/grub-probe: info: changing current directory to disk. /usr/local/sbin/grub-probe: info: changing current directory to by-uuid. /usr/local/sbin/grub-probe: info: changing current directory to by-partuuid. /usr/local/sbin/grub-probe: info: changing current directory to by-partlabel. /usr/local/sbin/grub-probe: info: changing current directory to by-label. /usr/local/sbin/grub-probe: info: changing current directory to by-path. /usr/local/sbin/grub-probe: info: changing current directory to by-id. /usr/local/sbin/grub-probe: info: changing current directory to block. /usr/local/sbin/grub-probe: info: changing current directory to usb. /usr/local/sbin/grub-probe: info: changing current directory to char. /usr/local/sbin/grub-probe: info: changing current directory to net. /usr/local/sbin/grub-probe: info: changing current directory to pts. /usr/local/sbin/grub-probe: info: changing current directory to shm. /usr/local/sbin/grub-probe: info: changing current directory to bsg. /usr/local/sbin/grub-probe: info: changing current directory to mapper. /usr/local/sbin/grub-probe: info: changing current directory to input. /usr/local/sbin/grub-probe: info: changing current directory to by-path. /usr/local/sbin/grub-probe: info: changing current directory to by-id. /usr/local/sbin/grub-probe: info: changing current directory to bus. /usr/local/sbin/grub-probe: info: changing current directory to usb. /usr/local/sbin/grub-probe: info: changing current directory to 004. /usr/local/sbin/grub-probe: info: changing current directory to 003. /usr/local/sbin/grub-probe: info: changing current directory to 002. /usr/local/sbin/grub-probe: info: changing current directory to 001. /usr/local/sbin/grub-probe: info: changing current directory to raw. /usr/local/sbin/grub-probe: info: changing current directory to cpu. /usr/local/sbin/grub-probe: info: changing current directory to 7. /usr/local/sbin/grub-probe: info: changing current directory to 6. /usr/local/sbin/grub-probe: info: changing current directory to 5. /usr/local/sbin/grub-probe: info: changing current directory to 4. /usr/local/sbin/grub-probe: info: changing current directory to 3. /usr/local/sbin/grub-probe: info: changing current directory to 2. /usr/local/sbin/grub-probe: info: changing current directory to 1. /usr/local/sbin/grub-probe: info: changing current directory to 0. /usr/local/sbin/grub-probe: error: cannot find a device for / (is /dev mounted?). [root@localhost /]# -- Chris Murphy ___ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel
Re: grub2-probe confused by double bind mount?
Upstream doesn't use grub2 prefix. Please try with latest upstream and make sure it's compiled with libdevmapper On Mon, Aug 7, 2017, 08:57 Chris Murphywrote: > It's not the double bind mount. I've removed it by eliminating the -o > subvol option and adjusted paths accordingly during assembly. But > grub2-probe still fails inside the chroot, even though it works on the > path I'm chrooting. > > mount assembly > https://pastebin.com/LMSPeeiP > > strace grub2-probe inside chroot (fails) > https://pastebin.com/S1mA8RTh > > strace grub2-probe outside chroot (succeeds) > https://pastebin.com/VkfZnsKu > > > In the outside chroot (working) case, line 233 it figures out it's > Btrfs with Btrfs specific ioctls. Where the failing case never does > even after digging around in /dev/ which it does find and yet > complaint that it's not mounted. So the error message itself seems > bogus and only a symptom of confusion and not what or why the actual > problem is happening. > > The non-working case looks like it starts failing after line 213, > openat /proc/self/mountinfo as if whatever it finds there is not at > all helpful. > > inside > < 693 225 0:6 / /dev rw,nosuid shared:22 - devtmpfs devtmpfs > rw,seclabel,size=3999060k,nr_inodes=999765,mode=755 > > outside > > 21 71 0:6 / /dev rw,nosuid shared:22 - devtmpfs devtmpfs > rw,seclabel,size=3999060k,nr_inodes=999765,mode=755 > > > Chris Murphy > > ___ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel > ___ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel
Re: grub2-probe confused by double bind mount?
Chris Murphy schreef op 07-08-2017 8:56: The non-working case looks like it starts failing after line 213, openat /proc/self/mountinfo as if whatever it finds there is not at all helpful. The only similar thing I ever experienced is when my system inside a chroot actually had a line filtering out a certain volume group or physical volume for LVM, thereby mysteriously causing a command to fail inside the chroot but not outside of it ;-). Probably not helpful, but I thought I'd mention. ___ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel
Re: grub2-probe confused by double bind mount?
It's not the double bind mount. I've removed it by eliminating the -o subvol option and adjusted paths accordingly during assembly. But grub2-probe still fails inside the chroot, even though it works on the path I'm chrooting. mount assembly https://pastebin.com/LMSPeeiP strace grub2-probe inside chroot (fails) https://pastebin.com/S1mA8RTh strace grub2-probe outside chroot (succeeds) https://pastebin.com/VkfZnsKu In the outside chroot (working) case, line 233 it figures out it's Btrfs with Btrfs specific ioctls. Where the failing case never does even after digging around in /dev/ which it does find and yet complaint that it's not mounted. So the error message itself seems bogus and only a symptom of confusion and not what or why the actual problem is happening. The non-working case looks like it starts failing after line 213, openat /proc/self/mountinfo as if whatever it finds there is not at all helpful. inside < 693 225 0:6 / /dev rw,nosuid shared:22 - devtmpfs devtmpfs rw,seclabel,size=3999060k,nr_inodes=999765,mode=755 outside > 21 71 0:6 / /dev rw,nosuid shared:22 - devtmpfs devtmpfs > rw,seclabel,size=3999060k,nr_inodes=999765,mode=755 Chris Murphy ___ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel