Please correct my fstab [SOLVED]

Getting your soundcard to work, using Debian on non-i386 hardware, etc

Please correct my fstab [SOLVED]

Postby ckosloff » 2019-07-20 12:17

#
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/sda1 during installation
UUID=d3d3d099-2fc0-4c08-ad45-ac11b626f0f8 /               ext4    errors=remount-ro 0       1
# /home was on /dev/sda3 during installation
UUID=1d101b5b-ac69-4afa-a86d-6f538edd9461 /home           ext4    defaults        0       2
# swap was on /dev/sda2 during installation
UUID=5130e73e-6a69-4612-bdd2-5eba05cdb008 none            swap    sw              0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0
UUID="3477a04f-d073-46d9-8c7e-237012714900"         ext4    defaults   0   0


This is my fstab, the last entry refers to an additional hardrive sdb1, which used to mount seamlessly until I had to reinstall system, now it requests root password.
Computer boots OK, the UUID i got from command blkid, but something is missing in that entry.
Please help.
Last edited by ckosloff on 2019-07-20 12:39, edited 1 time in total.
User avatar
ckosloff
 
Posts: 451
Joined: 2011-12-29 15:08
Location: South Florida, USA

Re: Please correct my fstab

Postby cds60601 » 2019-07-20 12:21

Looks like the line is missing a mount point.
Server: Debian 9, Workstation: Arch
Laptop: Debian SID (i3), Pi: Raspbian (Pi-Hole)
User avatar
cds60601
 
Posts: 177
Joined: 2017-11-25 05:58
Location: Tampa, Florida

Re: Please correct my fstab

Postby ckosloff » 2019-07-20 12:27

This drive has label Data, should I add /Data?
User avatar
ckosloff
 
Posts: 451
Joined: 2011-12-29 15:08
Location: South Florida, USA

Re: Please correct my fstab

Postby cds60601 » 2019-07-20 12:35

The mount point is up to you. You will notice that other line show a mount point such as /home, / and so on

Here is a nice readup

https://wiki.archlinux.org/index.php/Fstab
Server: Debian 9, Workstation: Arch
Laptop: Debian SID (i3), Pi: Raspbian (Pi-Hole)
User avatar
cds60601
 
Posts: 177
Joined: 2017-11-25 05:58
Location: Tampa, Florida

Re: Please correct my fstab

Postby ckosloff » 2019-07-20 12:38

# /etc/fstab: static file system information.
Code: Select all
#
# 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/sda1 during installation
UUID=d3d3d099-2fc0-4c08-ad45-ac11b626f0f8 /               ext4    errors=remount-ro 0       1
# /home was on /dev/sda3 during installation
UUID=1d101b5b-ac69-4afa-a86d-6f538edd9461 /home           ext4    defaults        0       2
# swap was on /dev/sda2 during installation
UUID=5130e73e-6a69-4612-bdd2-5eba05cdb008 none            swap    sw              0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0
UUID="3477a04f-d073-46d9-8c7e-237012714900"         ext4    defaults   0   0
/dev/sdb1     /media/ckosloff/Data


It worked, this is my new fstab.
I got mount point by mounting after root password and then right-cliking on address bar in Dolphin file manager, select Edit, which revealed the actual mount point.
Thank you.
User avatar
ckosloff
 
Posts: 451
Joined: 2011-12-29 15:08
Location: South Florida, USA

Re: Please correct my fstab

Postby Head_on_a_Stick » 2019-07-20 19:25

ckosloff wrote:I got mount point by mounting after root password and then right-cliking on address bar in Dolphin file manager, select Edit, which revealed the actual mount point.

You have used a mount point employed by udisks2 for auto-mounting so you should probably choose a different one. And maybe fill in the other fields as well:
Code: Select all
grep sdb1 /proc/self/mounts

Using /dev/sdb1 in /etc/fstab is unwise because the block devices are assigned dynamically and so change from one boot to the next, this is why the other entries use UUIDs instead.
User avatar
Head_on_a_Stick
 
Posts: 10377
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Please correct my fstab [SOLVED]

Postby cds60601 » 2019-07-20 19:28

I agree with HoaS. The mount point should come after your uuid for that drive. Note the lines above for / and /home

So your line would look something like this

UUID=3477a04f-d073-46d9-8c7e-237012714900 /media/ckosloff/Data ext4 defaults 0 0
Server: Debian 9, Workstation: Arch
Laptop: Debian SID (i3), Pi: Raspbian (Pi-Hole)
User avatar
cds60601
 
Posts: 177
Joined: 2017-11-25 05:58
Location: Tampa, Florida

Re: Please correct my fstab [SOLVED]

Postby ckosloff » 2019-07-22 10:53

I corrected fstab once again according to latest suggestions and of course it worked.
It is indeed the correct way to do it and it reproduces the syntax used by system upon install.
Thanks for all the help.
User avatar
ckosloff
 
Posts: 451
Joined: 2011-12-29 15:08
Location: South Florida, USA


Return to Hardware

Who is online

Users browsing this forum: No registered users and 4 guests

fashionable