Howto auto-mount windows-partitions using /etc/fstab
Assume you are sure about:
- Your created directory is /media/Jonas (with uppercase J)
- Your ntfs partition is /dev/sda3 (you can find this out by issuing sudo blkid
)
My fstab uses a simpler form:
/dev/sda3 /media/windows ntfs defaults 0 0
You may change your "rw,auto, ...." to "defaults"
I will add a little more info to the subject.
If not installed, I recommend to install ntfs-3g
to allow r/w
the ntfs partitions.
apt-get install ntfs-3g
Also, to make the install 'device independent', use the UUID received from the blkid
utility instead of referencing a physical device.
root:~ blkid
...
/dev/sda1: SEC_TYPE="msdos" LABEL="boot" UUID="140A-14B7" TYPE="vfat" PARTUUID="0009bf4f-01"
/dev/sda2: UUID="f24a4949-f4b2-4cad-a780-a138695079ec" TYPE="ext4" PARTUUID="0009bf4f-02"
/dev/sdb1: LABEL="Western Digital" UUID="1C0EBC7A0EBC4F10" TYPE="ntfs" PARTUUID="0002f5f9-01"
...
then, as usual, create a mounting point, for example \wd
and edit /etc/fstab
inserting the following line:
..
UUID=1C0EBC7A0EBC4F10 /wd ntfs-3g defaults 0 0
..
you can try to mount the new device without reboot with mount -a
.
To avoid data corruption, if your need to remove the device, make sure you umount
(umount /wd
in this sample).