Bug 26667 - /boot partition does not always get mounted when waking up from pm-suspend / booting
Summary: /boot partition does not always get mounted when waking up from pm-suspend / ...
Status: NEW
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Base system maintainers
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-05-22 06:24 CEST by Shlomi Fish
Modified: 2020-06-05 11:14 CEST (History)
1 user (show)

See Also:
Source RPM: systemd-245.5-4.mga8.src.rpm
CVE:
Status comment:


Attachments

Description Shlomi Fish 2020-05-22 06:24:46 CEST
Description of problem:

/boot partition does not always get mounted when waking up from pm-suspend / booting . I recall it started happenning a few weeks ago.

Version-Release number of selected component (if applicable):

Cauldron.
Comment 1 Lewis Smith 2020-05-22 21:35:18 CEST
Hello Shlomi.
Can you give a few background details? The output from 'fdisk -l' perhaps; also from 'mount'. Are you booting from Grub2 or rEFInd? Do you have any weird things like LVM?
How does this failure to mount /boot show itself? If the system boots successfully in spite of the fault, perhaps attach the 'dmesg' output after it has happened.
Intrigued by "when waking up from pm-suspend", in that surely once mounted at boot, the /boot partition would remain mounted; why should suspend unmount it? Perhaps this is a silly question, in which case excuse my lack of knowledge in this area.

CC: (none) => lewyssmith

Comment 2 Shlomi Fish 2020-05-23 07:14:13 CEST
(In reply to Lewis Smith from comment #1)
> Hello Shlomi.
> Can you give a few background details? The output from 'fdisk -l' perhaps;
> also from 'mount'. Are you booting from Grub2 or rEFInd? Do you have any
> weird things like LVM?

fdisk -l:

```
Disk /dev/ram0: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram1: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram2: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram3: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram4: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram5: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram6: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram7: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram8: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram9: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram10: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram11: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram12: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram13: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram14: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram15: 31.26 MiB, 32768000 bytes, 64000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/sda: 1.84 TiB, 2000398934016 bytes, 3907029168 sectors
Disk model: ST2000DL003-9VT1
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x000ecf82

Device     Boot      Start        End    Sectors   Size Id Type
/dev/sda1  *            63   33431264   33431202    16G 83 Linux
/dev/sda2         33431265 3857608124 3824176860   1.8T  5 Extended
/dev/sda5         33431328 2957855669 2924424342   1.4T 83 Linux
/dev/sda6       2957855733 3024894914   67039182    32G 83 Linux
/dev/sda7       3024894978 3154475204  129580227  61.8G 82 Linux swap / Solaris
/dev/sda8       3154475268 3335174324  180699057  86.2G 83 Linux
/dev/sda9       3335174388 3529014614  193840227  92.4G 83 Linux
/dev/sda10      3529015296 3763390463  234375168 111.8G 83 Linux
/dev/sda11      3763392512 3857608124   94215613  44.9G 83 Linux
```

mount output:

```
root@telaviv1:~ # mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
devtmpfs on /dev type devtmpfs (rw,nosuid,noexec,size=4018876k,nr_inodes=1004719,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev,noexec)
tmpfs on /run type tmpfs (rw,nosuid,nodev,noexec,mode=755)
/dev/sda6 on / type ext4 (rw,noatime,data=ordered)
/dev/sda9 on /usr type ext4 (rw,noatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
none on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=28,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=2480)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime,mode=755)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
nfsd on /proc/fs/nfsd type nfsd (rw,relatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
/dev/sda5 on /home type ext4 (rw,noatime)
/dev/sda1 on /boot type ext3 (rw,noatime)
/dev/sda8 on /var type ext4 (rw,noatime)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw,relatime)
tmpfs on /run/user/500 type tmpfs (rw,nosuid,nodev,relatime,size=805988k,mode=700,uid=500,gid=500)
tmpfs on /var/spool/postfix/run/saslauthd type tmpfs (rw,nosuid,nodev,noexec,mode=755)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
gvfsd-fuse on /run/user/500/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=500,group_id=500)
```

I am booting using grub2 and don't have LVM (I just use raw partitions).

> How does this failure to mount /boot show itself? If the system boots
> successfully in spite of the fault, perhaps attach the 'dmesg' output after
> it has happened.

After the /boot partition is not mounted, the new kernels/initrds/etc. are installed into the wrong place (= the /boot directory of the "/" partition - before it is overrided by the mount), and as a result at the next computer startup, grub2 can only use the older kernels - which are still there is the "/boot" / "/dev/sda1" partition.

> Intrigued by "when waking up from pm-suspend", in that surely once mounted
> at boot, the /boot partition would remain mounted; why should suspend
> unmount it? Perhaps this is a silly question, in which case excuse my lack
> of knowledge in this area.
Comment 3 Lewis Smith 2020-05-23 14:31:27 CEST
Thank you Shlomi for the extra information.
> /dev/sda1 on /boot type ext3 (rw,noatime)
looks normal enough!

Assigning to BaseSystem.

CC: lewyssmith => (none)
Assignee: bugsquad => basesystem

Comment 4 Dave Hodgins 2020-05-23 16:17:45 CEST
Next time /boot fails to mount, please post the output of
dmesg|grep sda

CC: (none) => davidwhodgins

Comment 5 Shlomi Fish 2020-06-04 08:42:10 CEST
(In reply to Dave Hodgins from comment #4)
> Next time /boot fails to mount, please post the output of
> dmesg|grep sda

Dave: hi! /boot was not mounted after a ctrl+alt+del restart.

Here is the output of the 'dmesg | grep -F sda':

```
[    1.009629] sd 0:0:0:0: [sda] 3907029168 512-byte logical blocks: (2.00 TB/1.82 TiB)
[    1.009731] sd 0:0:0:0: [sda] Write Protect is off
[    1.009796] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[    1.009819] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[    1.094543]  sda: sda1 sda2 < sda5 sda6 sda7 sda8 sda9 sda10 sda11 >
[    1.095548] sd 0:0:0:0: [sda] Attached SCSI disk
[    3.788277] EXT4-fs (sda6): mounted filesystem with ordered data mode. Opts: data=ordered
[    4.139966] EXT4-fs (sda6): mounted filesystem with ordered data mode. Opts: data=ordered
[    4.263929] dracut: Mounted root filesystem /dev/sda6
[    4.663054] EXT4-fs (sda9): mounted filesystem with ordered data mode. Opts: acl
[    9.227222] systemd[1]: usr.mount: Unit is bound to inactive unit dev-sda9.device. Stopping, too.
[   13.601768] Adding 64790108k swap on /dev/sda7.  Priority:-2 extents:1 across:64790108k FS
[   14.508613] EXT4-fs (sda8): mounted filesystem with ordered data mode. Opts: acl
[   15.172658] EXT4-fs (sda5): mounted filesystem with ordered data mode. Opts: acl
[   28.405757] EXT4-fs (sda6): re-mounted. Opts: acl
[   28.486383] EXT4-fs (sda9): re-mounted. Opts: acl
```

Thanks for your help!
Comment 6 Dave Hodgins 2020-06-04 17:14:39 CEST
Strange. Other then in the list of partitions, no reference to sda1 in the
above, just the msg about "usr.mount: Unit is bound to inactive unit dev-sda9.device. Stopping, too". Doesn't make sense to me, and no help there.

What's in /etc/fstab? Unless the nofail option has been added, systemd should
be dropping the boot to a rescue shell if /boot or /usr has failed to mount.
Comment 7 Shlomi Fish 2020-06-04 20:04:55 CEST
(In reply to Dave Hodgins from comment #6)
> Strange. Other then in the list of partitions, no reference to sda1 in the
> above, just the msg about "usr.mount: Unit is bound to inactive unit
> dev-sda9.device. Stopping, too". Doesn't make sense to me, and no help there.
> 
> What's in /etc/fstab? Unless the nofail option has been added, systemd should
> be dropping the boot to a rescue shell if /boot or /usr has failed to mount.

```
[shlomif@telaviv1 ~]$ grep boot /etc/fstab
UUID=4a5d4de6-01cb-4f22-9a9e-f36f6a3867d0 /boot ext3 acl,noatime 1 2
[shlomif@telaviv1 ~]$ grep -B 1 boot /etc/fstab
# Entry for /dev/sda1 :
UUID=4a5d4de6-01cb-4f22-9a9e-f36f6a3867d0 /boot ext3 acl,noatime 1 2
```

Thanks!
Comment 8 Dave Hodgins 2020-06-05 00:29:40 CEST
I'm wondering if that last created initrd has some problem.

With all partitions mounted properly, try forcing an update of the initrd
with (as root) "dracut -f".
Comment 9 Shlomi Fish 2020-06-05 11:14:09 CEST
(In reply to Dave Hodgins from comment #8)
> I'm wondering if that last created initrd has some problem.
> 
> With all partitions mounted properly, try forcing an update of the initrd
> with (as root) "dracut -f".

`dracut -f` gave me this output:

```
dracut: Executing: /usr/bin/dracut -f
dracut: dracut module 'bootchart' will not be installed, because command '/sbin/bootchartd' could not be found!
dracut: dracut module 'mksh' will not be installed, because command '/bin/mksh' could not be found!
dracut: dracut module 'systemd' will not be installed, because it's in the list to be omitted!
dracut: systemd-initrd needs systemd in the initramfs
dracut: systemd-networkd needs systemd in the initramfs
dracut: dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
dracut: dracut module 'rngd' will not be installed, because command 'rngd' could not be found!
dracut: dracut module 'network' will not be installed, because it's in the list to be omitted!
dracut: dracut module 'network' will not be installed, because it's in the list to be omitted!
dracut: dracut module 'ifcfg' depends on 'network', which can't be installed
dracut: dracut module 'dmraid' will not be installed, because command 'dmraid' could not be found!
dracut: dracut module 'stratis' will not be installed, because command 'stratisd-init' could not be found!
dracut: dracut module 'cifs' will not be installed, because command 'mount.cifs' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsi-iname' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsiadm' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsid' could not be found!
dracut: dracut module 'biosdevname' will not be installed, because command 'biosdevname' could not be found!
dracut: dracut-systemd needs systemd-initrd in the initramfs
dracut: dracut module 'mksh' will not be installed, because command '/bin/mksh' could not be found!
dracut: dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
dracut: dracut module 'rngd' will not be installed, because command 'rngd' could not be found!
dracut: dracut module 'ifcfg' depends on 'network', which can't be installed
dracut: dracut module 'dmraid' will not be installed, because command 'dmraid' could not be found!
dracut: dracut module 'stratis' will not be installed, because command 'stratisd-init' could not be found!
dracut: dracut module 'cifs' will not be installed, because command 'mount.cifs' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsi-iname' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsiadm' could not be found!
dracut: dracut module 'iscsi' will not be installed, because command 'iscsid' could not be found!
dracut: *** Including module: bash ***
dracut: *** Including module: dash ***
dracut: *** Including module: i18n ***
dracut: *** Including module: drm ***
dracut: *** Including module: plymouth ***
dracut: *** Including module: kernel-modules ***
dracut: *** Including module: kernel-modules-extra ***
dracut: *** Including module: resume ***
dracut: *** Including module: rootfs-block ***
dracut: *** Including module: terminfo ***
dracut: *** Including module: udev-rules ***
dracut: Skipping udev rule: 40-redhat.rules
dracut: Skipping udev rule: 50-firmware.rules
dracut: Skipping udev rule: 50-udev.rules
dracut: Skipping udev rule: 91-permissions.rules
dracut: Skipping udev rule: 80-drivers-modprobe.rules
dracut: *** Including module: usrmount ***
dracut: *** Including module: base ***
dracut: *** Including module: fs-lib ***
dracut: *** Including module: shutdown ***
dracut: *** Including modules done ***
dracut: *** Installing kernel module dependencies ***
dracut: *** Installing kernel module dependencies done ***
dracut: *** Resolving executable dependencies ***
dracut: *** Resolving executable dependencies done ***
dracut: *** Hardlinking files ***
dracut: *** Hardlinking files done ***
dracut: *** Generating early-microcode cpio image ***
dracut: *** Constructing GenuineIntel.bin ***
dracut: *** Store current command line parameters ***
dracut: Stored kernel commandline:
dracut:  resume=LABEL=sf_unix_swap resume=UUID=9be1d836-b396-4fc3-970d-f9b4d82140e8
dracut:  root=UUID=d320c338-58a2-4aa6-9d47-d2c0bc60524b rootfstype=ext4 rootflags=rw,noatime,data=ordered
dracut: *** Stripping files ***
dracut: *** Stripping files done ***
dracut: *** Creating image file '/boot/initrd-5.6.15-desktop-1.mga8.img' ***
dracut: *** Creating initramfs image file '/boot/initrd-5.6.15-desktop-1.mga8.img' done ***
```

What should I do now?

Note You need to log in before you can comment on or make changes to this bug.