0

First Boot always fails. Is it possible to make it work ?

Working on modified OS image. Where it uses kernel of version 3.10 (Centos 7.6) but grub is still old version 0.97.

When deployment of OS image happens. It always stuck at [reached target Local Encrypted Volumes.] but after reboot/reset image works fine. As per log I see there is mount issue during the first boot.

If I change the Mount Point /mnt or any other path. It boots in first boot itself. So it's pretty clear that initramfs image mounted at "/" and when it reads the fstab tries to remount the root file system at "/" but fails.

fstab file:

tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
tmpfs                   /tmp                    tmpfs   size=64M        0 0
LABEL=/                 /                       ext3    defaults        0 1
LABEL=/var/log          /var/log                ext3    defaults        0 2

grub.conf:

default=0
timeout=5
title <TITLE> (3.10.0-957.1.3.el7.x86_64)
        root(hd0,1)
        kernel /boot/vmlinuz-3.10.0-957.1.3.el7.x86_64 rw root=LABEL=/ console=ttyS0,9600 ipv6.disable=1 net.ifnames=0 biosdevname=0 
        initrd /boot/initramfs-3.10.0-957.1.3.el7.x86_64.img

Boot Logs

[    5.443809] scsi 0:0:0:0: Direct-Access     VMware   Virtual disk     1.0  PQ: 0 ANSI: 2
[    6.082467] sd 0:0:0:0: [sda] 67108864 512-byte logical blocks: (34.3 GB/32.0 GiB)
[    6.084567] sd 0:0:0:0: [sda] Write Protect is off
[    6.085880] sd 0:0:0:0: [sda] Cache data unavailable
[    6.087230] sd 0:0:0:0: [sda] Assuming drive cache: write through
[    6.126988]  sda: sda1 sda2 sda3 sda4 < sda5 sda6 sda7 >
[    6.130980] sd 0:0:0:0: [sda] Attached SCSI disk
[    6.298133] random: fast init done
[    6.488183] EXT4-fs (sda2): mounting ext3 file system using the ext4 subsystem
[    6.506629] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[    6.638000] dracut: Checking ext3: /dev/disk/by-label/\x2f
[    6.640891] dracut: issuing e2fsck -a  /dev/disk/by-label/\x2f
[    6.719509] dracut: /: ignoring check interval, broken_system_clock set
[    6.723541] dracut: /: clean, 25095/625664 files, 1137935/5000000 blocks
[    6.733432] dracut: Mounting /dev/disk/by-label/\x2f with -o defaults,rw
[    6.787698] EXT4-fs (sda2): mounting ext3 file system using the ext4 subsystem
[    6.795954] EXT4-fs (sda2): warning: checktime reached, running e2fsck is recommended
[    6.799898] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[    6.902962] dracut: Mounted root filesystem /dev/sda2
[    7.122655] dracut: Switching root
[    7.263505] random: crng init done
[    7.726233] ip_tables: (C) 2000-2006 Netfilter Core Team
[    7.729639] systemd[1]: Inserted module 'ip_tables'
[    7.735397] systemd[1]: Configuration file /etc/systemd/system.conf is marked executable. Please remove executable permission bits. Proceeding anyway.
[    7.746005] systemd[1]: systemd 219 running in system mode. (+PAM +AUDIT +SELINUX +IMA -APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 -SECCOMP +BLKID +ELFUTILS +KMOD +IDN)
[    7.753805] systemd[1]: Detected virtualization vmware.
[    7.756236] systemd[1]: Detected architecture x86-64.

Welcome to [0;31mCentOS Linux 7 (Core)[0m!

[    9.084894] systemd[1]: Created slice system-serial\x2dgetty.slice.
[[32m  OK  [0m] Created slice system-serial\x2dgetty.slice.
[    9.090775] systemd[1]: Reached target Slices.
[[32m  OK  [0m] Reached target Slices.
[    9.095230] systemd[1]: -.mount: Directory / to mount over is not empty, mounting anyway.
[    9.099881] systemd[1]: Mounting /...
         Mounting /...
[    9.127149] systemd[1]: -.mount mount process exited, code=exited status=32
[    9.130870] systemd[1]: Failed to mount /.
[[1;31mFAILED[0m] Failed to mount /.
See 'systemctl status -.mount' for details.
  • upgrading grub to grub2.0 resolved this issue. – Rocoder Apr 8 at 8:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.