[systemd-devel] Cannot mount anything after recovering and redoing boot mbr

Lennart Poettering lennart at poettering.net
Mon Jul 27 17:31:54 PDT 2015


On Mon, 27.07.15 16:35, ccox at endlessnow.com (ccox at endlessnow.com) wrote:

> > On Mon, 27.07.15 01:18, Christopher Cox (ccox at endlessnow.com) wrote:
> >
> >> I suspect that somebody here knows why, but all mounts now fail... well
> >> all but /.
> >>
> >> Has anyone run across this before?  What did I miss?
> >>
> >> I accidentally messed up my boot mbr. and I did a rescue cd and chroot
> >> in
> >> order to rerun grub2-mkconfig and do a grub2-install.
> >>
> >> Now the system boots to a grub menu and tries to boot, root fileystem
> >> mounts
> >> but all other mounts fail so goes into "emergency" mode.  From that
> >> shell I
> >> cannot seem to mount anything, they all fail saying that whatever I'm
> >> trying
> >> to mount is already mounted or it's "in use".  I can't fsck umounted
> >> filesystems either.  They all say "in use".
> >
> > Maybe your changed the order of your partitions or changed their
> > partition UUID? If so, then /etc/fstab will reference incorrect
> > partitions now. Make sure bring /etc/fstab into sync with your actual
> > partitions.
> 
> A "root" is getting mounted and I figure it's the same but will double
> check (away from system right now).  Would some kind of root getting
> mounted at startup and being different from root in /etc/fstab make some
> sort of difference?  

Nope, mounted is mounted. systemd doesn't really care where something
is mounted from, it only cares whether it is mounted at all. And the
mount source it will only use if it needs to mount something because
nobody else has mounted it yet.

> Would that cause manual mounts of old style nonportable dev
> shortnames (e.g. mount /dev/sda7 /mnt) to fail with the error of
> "busy" when done at the command line? (from emergency shell).

Well if you use references such as /dev/sda7 then you are of course
very vulnerable to partition renumbering if you redoo your partition
table. Use /dev/disks/by-uuid/ and you should be safe regarding that.

Lennart

-- 
Lennart Poettering, Red Hat


More information about the systemd-devel mailing list