Fstab editing causes hang
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Fstab editing causes hang
Hello,
Im running LM14 and want to auto mount a hard disk on boot or log in. I did it the old fassioned way, editing fstab, but when it boots and gets to the linux mint splash screen, some application trys to access/mount/somthing the drive i set up to auto mount, but cant, so the system hangs until i press "S" to skip the disk. it may be the file system error dector beacuse this error follows any "must check for errors on sd*#" statements.
I can boot again, had to add noauto to fstab (or comment the line) but still want it mounted when i start using my system. nothing system vital is on it so auto mounting on log in would suffice. i just don't want to have to manualy mount the FS.
Thanks for not saying "google it" (already did, pysdm is gone.)
Im running LM14 and want to auto mount a hard disk on boot or log in. I did it the old fassioned way, editing fstab, but when it boots and gets to the linux mint splash screen, some application trys to access/mount/somthing the drive i set up to auto mount, but cant, so the system hangs until i press "S" to skip the disk. it may be the file system error dector beacuse this error follows any "must check for errors on sd*#" statements.
I can boot again, had to add noauto to fstab (or comment the line) but still want it mounted when i start using my system. nothing system vital is on it so auto mounting on log in would suffice. i just don't want to have to manualy mount the FS.
Thanks for not saying "google it" (already did, pysdm is gone.)
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Re: Fstab editing causes hang
What would help the folks here answer your question is to post the output of the following commands so they can see how things are set up:
Code: Select all
cat /etc/fstab
Code: Select all
sudo blkid -c /dev/null
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Re: Fstab editing causes hang
FSTAB
blkid
sdd1 is the drive in question.
Code: Select all
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc nodev,noexec,nosuid 0 0
# / was on /dev/sdd2 during installation
UUID=89ee5b26-66ac-4c09-b674-3bdf3950e02c / ext4 errors=remount-ro 0 1
# swap was on /dev/sdd6 during installation
UUID=bd62a968-f9dd-43d4-9a77-962646c49f9e none swap sw 0 0
#after install options
UUID=a81866e4-17e8-4fa0-a25c-eb1fbacac494 /media/fen/Mayhew\040Storage/ ext4 user,noauto 0 1
Code: Select all
/dev/sdb2: UUID="89ee5b26-66ac-4c09-b674-3bdf3950e02c" TYPE="ext4"
/dev/sdb5: LABEL="home1" UUID="cb5db27f-6ede-406c-8c16-8a19939a971a" SEC_TYPE="ext2" TYPE="ext3"
/dev/sdb6: UUID="bd62a968-f9dd-43d4-9a77-962646c49f9e" TYPE="swap"
/dev/sdb7: LABEL="cross platf" UUID="0464-500F" TYPE="vfat"
/dev/sdc1: LABEL="Gentoo" UUID="00f6a405-bc15-4149-8597-31993eebad13" TYPE="ext4"
/dev/sdc2: UUID="c64af971-77f9-44af-9b60-faccad060918" TYPE="swap"
/dev/sdd1: LABEL="Mayhew Storage" UUID="a81866e4-17e8-4fa0-a25c-eb1fbacac494" TYPE="ext2"
Re: Fstab editing causes hang
Mayhew Storage appears to be ext2 but you are trying to mount it ext4. Probably doesn't matter but I would remove the last "/" after storage as well.
Give this a shot:
Change the line to this:
Save it. If you have mounted it manually unmount it then run the following command to remount it:
If it just comes back to the prompt then it mounted it. If it comes back with an error message then that may be the problem.
Give this a shot:
Change the line to this:
Code: Select all
UUID=a81866e4-17e8-4fa0-a25c-eb1fbacac494 /media/fen/Mayhew\040Storage ext2 defaults,user 0 1
Code: Select all
sudo mount -a
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Re: Fstab editing causes hang
just so you know it will mount manualy(gui & cli). w/o changes.
Re: Fstab editing causes hang
Code: Select all
sudo mount -a
Re: Fstab editing causes hang
Create a new mount point and get it out of that /media/fen directory:
Change the line to this:
Run the mount command to test syntax:
Then reboot to see if the problem persists.
If it does go back to the user + noauto method and automate the manual mount:
Change the line to this:
Then add a mount to your startup applications:
Menu > Preferences > Startup Applications
Name: Mount-sdd1
Command: mount "/media/fen/Mayhew Storage"
Then logoff and login to see if it mounts correctly.
Code: Select all
sudo mkdir "/media/Mayhew Storage"
Code: Select all
UUID=a81866e4-17e8-4fa0-a25c-eb1fbacac494 /media/Mayhew\040Storage ext2 defaults 0 2
Code: Select all
sudo mount -a
If it does go back to the user + noauto method and automate the manual mount:
Change the line to this:
Code: Select all
UUID=a81866e4-17e8-4fa0-a25c-eb1fbacac494 /media/fen/Mayhew\040Storage ext2 defaults,user,noauto 0 2
Menu > Preferences > Startup Applications
Name: Mount-sdd1
Command: mount "/media/fen/Mayhew Storage"
Then logoff and login to see if it mounts correctly.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Re: Fstab editing causes hang
Bless you altair4, it works ^.^ thanks much.
Idk what piece of software uses those /media/<username>/ folders but it'd be nice to see it tweaked so edits to fstab wouldn't cause so much problems.
Idk what piece of software uses those /media/<username>/ folders but it'd be nice to see it tweaked so edits to fstab wouldn't cause so much problems.
Re: Fstab editing causes hang
I had same difficulty. In the end it was solved by replacing 'default' by 'user' in fstab. I suspect that being new (2 weeks old) to Linux I wanted to make my drives as much like a Mac as possible and had used chown peter:peter and chmod to 0740. T rying to mount as root as default does caused a whole string of error messages from sudo mount -a. Anyway thanks for help as without it I wouldn't have known where to start.
Re: Fstab editing causes hang
It's "defaults" not "default" and changing "defaults" to "user" wouldn't have done anything. The "user" option in the context of fstab and without the "noauto" option is irrelevant since the only user at the moment fstab is read at boot time is root. "user" doesn't relate to who can use it it relates to who can mount it. "defaults" contains the option "nouser" - this will make it so only root can mount the partition and this is how the UNIX gods intended it.PeterHi wrote:I had same difficulty. In the end it was solved by replacing 'default' by 'user' in fstab.
This is the way ( with defaults ) partitions have been mounted in UNIX/Linux for 40+ years.Trying to mount as root as default does caused a whole string of error messages from sudo mount -a.
It's not really relevant in this case because group=user but you don't want to chmod a directory with an even value number ( the "4" ). It must always be odd because that makes the directory executable and for a directory that enables it to be opened ( or traversed if you want to be persnickety about it )I suspect that being new (2 weeks old) to Linux I wanted to make my drives as much like a Mac as possible and had used chown peter:peter and chmod to 0740.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.