Reputation: 1860
I know mount
and df
lists all mounts. But I would like to list the mounts which failed to establish on boot, too. How do I get them?
Upvotes: 26
Views: 152394
Reputation: 1765
df | grep -oP ' (/.*)'
The main issue is an extra space at the start of each line. This just lists all your mounted mount points. To do that there is
df | grep -oP ' (/.*)' | grep -oP '(/.*)'
To output a list of mounts you might consider putting files into / running benchmark on:
df | grep -oP ' (/.*)' | grep -oP '(/.*)' | grep -vE "(/run|/dev|/sys|/boot)"
Upvotes: 0
Reputation: 6193
You can use mount -a
to mount all the mount points defined in the fstab
.
If there is some kind of error mounting, you will get some warning. If the mount point is already mounted successfully, the command will do nothing with that mountpoint.
Mount errors should appear in dmesg
.
Upvotes: 2
Reputation: 42915
There is no such command, since there is no list of "attempted mounts". You can compare the current mount list (/etc/mtab
) to the list of shares registered to be mounted though (/etc/fstab
).
Alternatively you could try to grep
through the system log files to find failed mount attempts.
Upvotes: 26