[Solved] fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Questions about applications and software
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
stu4ben
Level 1
Level 1
Posts: 12
Joined: Mon Jun 28, 2021 3:54 pm

[Solved] fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by stu4ben »

Hey, I have encountered a bug with my fstab file, after startup the partition is displayed as mounted, even though it's not really mounted. I'm not able to load any data of it over the mountpoint. Also I'm unable to unmount it. However if i comment out the line for the partition in question (sda2 / UUID=0230B6A130B69ADD), and restart the computer, and remove the comment # again, and manually mount the drive by clicking it in the file manager and Devices, it works as intended. The ext4 partition on the same drive mounts as intended.
I also have the same problem with nvme0n1p4, which is however not in the fstab file right now.
My /etc/fstab file content:

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>
# / was on /dev/sda2 during installation
UUID=6276e2f4-1892-4fe1-ab15-9c2e1c36e009 /                       ext4    errors=remount-ro                        0       1
# /boot/efi was on /dev/sda1 during installation
UUID=BA61-700F                            /boot/efi               vfat    umask=0077                               0       1
# /home was on /dev/sda3 during installation
UUID=8aa6b543-95dc-40f0-b5b8-3af2b956f418 /home                   ext4    defaults                                 0       2
# swap was on /dev/sda4 during installation
UUID=df6044f1-c30c-4205-bb55-925a719c8416 none                    swap    sw                                       0       0
# Backup Partition on 8TB HDD 
UUID=b1aa50c5-2ef5-4e58-b619-735ab9d64a91 /backup                 ext4    defaults                                 0       2
# Bulk Data Partition on 8TB HDD
UUID=0230B6A130B69ADD                     /home/stu4ben/DATA      ntfs    rw,user,exec,umask=002,uid=stu4ben       0       2
My console commands:

Code: Select all

stu4ben@stu4ben-linux-mint-pc:~$ lsblk
NAME 		   MAJ:MIN 	RM 	SIZE 	RO 	TYPE 	MOUNTPOINT
sda           		8:0    	0  	7.3T  	0 	disk 
├─sda1      		8:1    	0    	16M  	0 	part 
├─sda2     	   	8:2    	0   	6.7T  	0 	part 	/home/stu4ben/DATA
└─sda3     	  	8:3    	0 	616.1G 	0 	part 	/run/timeshift/backup
sdb           		8:16   	0 	238.5G	0 	disk 
├─sdb1      	  	8:17   	0   	512M  	0 	part 	/boot/efi
├─sdb2        		8:18   	0  	62.5G  	0 	part 	/
├─sdb3      	  	8:19   	0 	117.2G 	0 	part 	/home
└─sdb4      	  	8:20   	0  	31.3G  	0 	part 	[SWAP]
nvme0n1 		259:0 	0 	465.8G 	0 	disk 
├─nvme0n1p1 		259:1 	0   	529M 	0 	part 
├─nvme0n1p2 		259:2 	0   	100M  	0 	part 
├─nvme0n1p3 		259:3 	0    	16M  	0 	part 
└─nvme0n1p4 		259:4 	0 	465.1G 	0 	part 
stu4ben@stu4ben-linux-mint-pc:~$ sudo umount /dev/sda2
umount: /home/stu4ben/DATA: not mounted.
Do you need anything else?
I will just add an noauto flag as a provisional solution, however I'd really like it to mount it fully automatically.
Does any of you have any clue? Help would be greatly appreciated.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 3 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
t42
Level 11
Level 11
Posts: 3734
Joined: Mon Jan 20, 2014 6:48 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by t42 »

did you try
ntfs defaults,uid=1000,gid=1000,umask=002 0 2
or if you prefere not to share
ntfs defaults,uid=1000,gid=1000,umask=007 0 2
-=t42=-
rene
Level 20
Level 20
Posts: 12212
Joined: Sun Mar 27, 2016 6:58 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by rene »

Do you use home directory encryption? That is, is /dev/sda2 being mounted onto /home/stu4ben/DATA just before you overlay an ecryptfs onto /home/stu4ben/?

Admittedly that would imply you having a /home/stu4ben/DATA directory (also) in your unencrypted /home/stu4ben which does not make great sense but "bugs" in this area also don't really. You are using home directory encryption if mount shows an ecryptfs mounted on /home/stu4ben.
t42
Level 11
Level 11
Posts: 3734
Joined: Mon Jan 20, 2014 6:48 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by t42 »

rene wrote: Mon Sep 20, 2021 4:06 pm Do you use home directory encryption?
That's may be (not revealed) it! Still I don't understand that sdb3 /home considering installation time note in fstab.

Edit. It's logical to use dm-crypt having separate home and being conveniently evident in lsblk output
Last edited by t42 on Mon Sep 20, 2021 4:53 pm, edited 1 time in total.
-=t42=-
rene
Level 20
Level 20
Posts: 12212
Joined: Sun Mar 27, 2016 6:58 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by rene »

Looks not strange as far as I'm noticing; /dev/sdb3 on /home as a regular split-off /home, /dev/sda2 on /home/stu4ben/DATA at boot-time, /home/.ecryptfs/stu4ben/... on /home/stu4ben post-login, hiding the boot-time /home/stu4ben/DATA

[EDIT] Noticed your edit; oh well; let's just wait for confirmation/denial.
stu4ben
Level 1
Level 1
Posts: 12
Joined: Mon Jun 28, 2021 3:54 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by stu4ben »

Ooh, yeah i'm using home folder encryption. That makes sense. So if i just mount it to /DATA or so, it should be fine?
Thanks a lot for your Answers.
stu4ben
Level 1
Level 1
Posts: 12
Joined: Mon Jun 28, 2021 3:54 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by stu4ben »

I don't understand that sdb3 /home considering installation time note in fstab.
I installed it without current sda installed, so sdb was sda during installation. It somehow got changed to sdb when installing the Bulk HDD
rene
Level 20
Level 20
Posts: 12212
Joined: Sun Mar 27, 2016 6:58 pm

Re: fstab bug: ntfs partition showing as mounted even though it's not actually mounted

Post by rene »

stu4ben wrote: Tue Sep 21, 2021 7:13 am So if i just mount it to /DATA or so, it should be fine?
Yes. Common locations are /data and /mnt/data, and you can easily still have it available also under your home directory with a symlink:

Code: Select all

rmdir ~/DATA && ln -s /DATA ~/
Locked

Return to “Software & Applications”