fstab entry added by GUI Disks utility seems ill-formatted but works?

The Disks utility (gnome-disks) added this entry in /etc/fstab:

UUID=[UUID] [mount pount] auto nosuid,nodev,nofail,x-gvfs-show 0 0

Based on numerous examples and on info fstab, auto is where the filesystem type (ext4 in this case) should be, and then auto,, with a comma, should start the list of options.

But the partition is mounted at startup, so auto is working. Is fstab lax about formatting? Is the Disks utility sloppy about formatting?

(Why I care: I'm about to install Ubuntu server on a new hardware system and want to add an appropriate fstab entry manually.)


Solution 1:

In your fstab-line auto is indeed the third field and the filesystem-type.

In the forth field which contains the mount options seperated with a comma there is no need to add the auto-option because it is default and this default will be used. If you don't want a partition to be automatically mounted, you'd have to use the noauto- option.

Here a short list of default mount-options:

rw, suid, dev, exec, auto, nouser, async

You can find such information with man mount.

Solution 2:

No, it is not ill-formatted; the auto keyword may be used as both a filesystem type and a mount option. From man mount:

(as a filesystem type):

          If  no  -t  option  is  given, or if the auto type is specified,
          mount will try to guess the desired type.

(as a mount option):

   auto   Can be mounted with the -a option.