OpenLMI Mounting Model

Table of Contents

1 OpenLMI Mounting Model

This page presents a draft of a CIM model that will be used to implement mounting in OpenLMI. The implemented provider will be used to mount and unmount local and remote filesystems. The provider will support binding mounts as well.

mounting.png

2 Classes


[ Description (
         "Class for representing mount options. Basic boolean properties represent "
         "filesystem independent mount options (as listed in mount(8)). Options "
         "'auto' and 'user' are ommited, as they only make sense in /etc/fstab." ) ]
class LMI_MountedFileSystemSetting : CIM_SettingData
{
         [ Description (
                 "All I/O to the filesystem should be done synchronously. In case of "
                 "media with limited number of write cycles (e.g. some flash drives), "
                 "this option may cause life-cycle shortening. Corresponds to 'sync' "
                 "mount option." ) ]
         boolean SynchronousIO;

         [ Description (
                 "All directory updates within the filesystem should be done "
                 "synchronously. This affects the following system calls: creat, link, "
                 "unlink, symlink, mkdir, rmdir, mknod and rename. Corresponds to "
                 "'dirsync' mount option." ) ]
         boolean SynchronousDirectoryUpdates;

         [ Description (
                 "Update inode access times on this filesystem. Corresponds to 'atime' "
                 "mount option." ) ]
         boolean UpdateAccessTimes;

         [ Description (
                 "Allows to explicitly requesting full atime updates. This makes it "
                 "possible for kernel to defaults to relatime or noatime but still "
                 "allow userspace to override it. Corresponds to 'strictatime' mount "
                 "option." ) ]
         boolean UpdateFullAccessTimes;

         [ Description (
                 "Update inode access times relative to modify or change time. Access "
                 "time is only updated if the previous access time was earlier than the "
                 "current modify or change time. Corresponds to 'relatime' mount "
                 "option." ) ]
         boolean UpdateRelativeAccessTimes;

         [ Description (
                 "Update directory inode access times on this filesystem. This is the "
                 "default. Corresponds to 'diratime' mount option." ) ]
         boolean UpdateDirectoryAccessTimes;

         [ Description (
                 "Interpret character or block special devices on the filesystem."
                 "Corresponds to 'dev' mount option." ) ]
         boolean InterpretDevices;

         [ Description (
                 "Allow mandatory locks on this filesystem. See fcntl(2). Corresponds "
                 "to 'mand' mount option." ) ]
         boolean AllowMandatoryLock;

         [ Description (
                 "Permit execution of binaries. Corresponds to 'exec' mount option." ) ]
         boolean AllowExecution;

         [ Description (
                 "Allow set-user-identifier or set-group-identifier bits to take "
                 "effect. Corresponds to 'suid' mount option." ) ]
         boolean AllowSUID;

         [ Description (
                 "Mount the filesystem read-write. If false, mount read-only."
                 "Corresponds to 'rw' mount option." ) ]
         boolean AllowWrite;

         [ Description (
                 "Turn on the silent flag. Corresponds to 'silent' mount option." ) ]
         boolean Silent;

         [ Description (
                 "Other mount options that can be filesystem specific. This property is "
                 "also used to specify options with values (e.g. uid=0 or gid=100). "
                 "OtherOptions are appended (in the same order as they appear in the "
                 "array) to the basic options." ),
             ArrayType ( "Indexed" ) ]
         string OtherOptions[];

         [ Description (
                 "Mount automatically at boot-up. Corresponds to 'auto' mount "
                 "option. This option is only relevant in /etc/fstab." ) ]
         boolean Auto;

         [ Description (
                 "Allow an ordinary user to mount the filesystem. Corresponds to 'user' "
                 "mount option. This option is only relevant in /etc/fstab." ) ]
         boolean AllowUserMount;

         [ Description (
                 "This field is used for these filesystems by the dump(8) command to "
                 "determine which filesystems need to be dumped. If the field is "
                 "not present, a value of zero is returned and dump will assume that "
                 "the filesystem does not need to be dumped. This option is only "
                 "relevant in /etc/fstab." ) ]
         boolean Dump;

         [ Description (
                 "Used by the fsck(8) program to determine the order in which "
                 "filesystem checks are done at reboot time. The root filesystem should "
                 "be specified with a 1, other filesystems with a 2. Filesystems within "
                 "a drive are checked sequentially, but filesystems on different drives "
                 "are checked in parallel. This option is only relevant in "
                 "/etc/fstab." ) ]
         uint16 FileSystemCheckOrder;
};

[ Description (
         "Class for representing mounted filesystems. Can be thought of as either "
         "an entry in /etc/mtab, or in /etc/fstab, according to its associated "
         "LMI_MountedFileSystemSetting." ) ]
class LMI_MountedFileSystem : CIM_ManagedElement
{
         [ Description (
                 "Filesystem type.") ]
         string FileSystemType;

         [ Key, Description (
                 "Filesystem specification. Corresponds to the device field in "
                 "/etc/fstab." ) ]
         string FileSystemSpec;

         [ Key, Description (
                 "Path to a directory where the device is mounted." ) ]
         string MountPointPath;
};

class LMI_MountedFileSystemCapabilities : CIM_Capabilities
{
         [ Description (
                 "Method to create and populate an LMI_MountedFileSystemSetting instance. This "
                 "removes the need to populate default settings and other settings "
                 "in the context of each LMI_MountedFileSystemCapabilities (which could be "
                 "numerous)." ),
             ValueMap { "0", "1", "2", "3", "4", "5", "..", "32768..65535" },
             Values { "Success", "Not Supported", "Unspecified Error", "Timeout",
                               "Failed", "Invalid Parameter", "DMTF Reserved",
                               "Vendor Specific" } ]
         uint32 CreateSetting(
                 [ IN(false), OUT, Description (
                         "Reference to the created setting instance." ) ]
                 LMI_MountedFileSystemSetting REF MountSetting
         );

         [ ValueMap { "0", "1", "2" },
             Values { "CreateMount", "ModifyMount", "DeleteMount" } ]
         uint16 SupportedAsynchronousMethods[];
};

class LMI_MountConfigurationService : CIM_Service
{
         [ Description (
                 "Mounts the specified filesystem to a mountpoint." ),
             ValueMap { "0", "1", "2", "3", "4", "5", "6", "..", "4096",
                                   "4097", "4098..32767", "32768..65535" },
             Values { "Job Completed with No Error", "Not Supported",
                               "Unknown", "Timeout", "Failed", "Invalid Parameter",
                               "In Use", "DMTF Reserved",
                               "Method Parameters Checked - Job Started",
                               "Size Not Supported", "Method Reserved", "Vendor Specific" } ]
         uint32 CreateMount(
                 [ IN(false), OUT, Description (
                         "Reference to the created job." ) ]
                 CIM_ConcreteJob REF Job,

                 [ IN(false), OUT, Description (
                         "Reference to the created LMI_MountedFileSystem instance." ) ]
                 LMI_MountedFileSystem REF Mount,

                 [ IN, Description (
                       "Existing filesystem that should be mounted. If NULL, mount a "
                       "remote filesystem, or mount a non-device filesystem (e.g. tmpfs). "
                       "If not NULL, mount a local filesystem. When mounting a local "
                       "filesystem, the FileSystemType parameter has to agree with "
                       "the type of FileSystem." ) ]
                 CIM_FileSystem REF FileSystem,

                 [ IN, Description (
                         "Directory where the mounted filesystem should be attached at." ) ]
                 string MountPoint,

                 [ IN, Description (
                         "Filesystem specification. Specifies the device that should be "
                         "mounted. Remote filesystems can be specified in their usual "
                         "form (e.g. 'hostname:/share' for NFS, or '//hostname/share' for "
                         "CIFS). Non-device filesystems can also be specified "
                         "(e.g. 'tmpfs' or 'sysfs')." ) ]
                 string FileSystemSpec,

                 [ IN, Description (
                         "Filesystem type. If NULL, perform a binding mount. If binding a "
                         "local filesystem, this parameter has to be in agreement with the "
                         "FileSystem." ) ]
                 string FileSystemType,

                 [ IN, Description (
                         "Desired mount settings. If NULL, defaults will be used. Default "
                         "mount options are 'rw, suid, dev, exec, auto, nouser, async'." ) ]
                 LMI_MountedFileSystemSetting REF Goal,

                 [ IN, Description (
                         "The mode in which the configuration is to be applied to the "
                         "MountedFileSystem."
                         "\nMode 0 - Not used."
                         "\nMode 1 - IsNext = 1, IsCurrent = 1."
                         "\nMode 2 - IsNext = 1, IsCurrent not affected."
                         "\nMode 3 - Not used."
                         "\nMode 4 - IsNext = 2, IsCurrent = 2."
                         "\nMode 5 - IsNext = 2, IsCurrent not affected."
                         "\nMode 6 - Not used."
                         "\nMode 32768 - IsNext not affected, IsCurrent = 1."
                         "\nMode 32769 - IsNext not affected, IsCurrent = 2." ),
                     ValueMap { "0", "1", "2", "3", "4", "5", "6", "..", "32768", "32769" },
                     Values { "Mode 0", "Mode 1", "Mode 2", "Mode 3", "Mode 4", "Mode 5",
                                       "Mode 6", "DMTF Reserved", "Mode 32768", "Mode 32769" } ]
                 uint16 Mode
         );

         [ Description (
                 "Modifies (remounts) an existing mount." ),
             ValueMap { "0", "1", "2", "3", "4", "5", "6", "..", "4096",
                                   "4097", "4098..32767", "32768..65535" },
             Values { "Job Completed with No Error", "Not Supported",
                               "Unknown", "Timeout", "Failed", "Invalid Parameter",
                               "In Use", "DMTF Reserved",
                               "Method Parameters Checked - Job Started",
                               "Size Not Supported", "Method Reserved", "Vendor Specific" } ]
         uint32 ModifyMount(
                 [ IN(false), OUT, Description (
                         "Reference to the created job." ) ]
                 CIM_ConcreteJob REF Job,

                 [ IN, OUT, Description (
                         "Reference to the LMI_Mount instance that is being modified. " ) ]
                 LMI_MountedFileSystem REF Mount,

                 [ IN, Description (
                       "Desired mount settings. If NULL, the mount options are not "
                       "changed. If mount (or an fstab entry) should be performed "
                       "(created), the appropriate respective MountedFileSystemSetting "
                       "will be created." ) ]
                 LMI_MountedFileSystemSetting REF Goal,

                 [ IN, Description (
                         "The mode in which the configuration is to be applied to the "
                         "MountedFileSystem."
                         "\nMode 0 - Not used."
                         "\nMode 1 - IsNext = 1, IsCurrent = 1."
                         "\nMode 2 - IsNext = 1, IsCurrent not affected."
                         "\nMode 3 - Not used."
                         "\nMode 4 - IsNext = 2, IsCurrent = 2."
                         "\nMode 5 - IsNext = 2, IsCurrent not affected."
                         "\nMode 6 - Not used."
                         "\nMode 32768 - IsNext not affected, IsCurrent = 1."
                         "\nMode 32769 - IsNext not affected, IsCurrent = 2." ),
                     ValueMap { "0", "1", "2", "3", "4", "5", "6", "..", "32768", "32769" },
                     Values { "Mode 0", "Mode 1", "Mode 2", "Mode 3", "Mode 4", "Mode 5",
                                       "Mode 6", "DMTF Reserved", "Mode 32768", "Mode 32769" } ]
                 uint16 Mode
         );

         [ Description (
                 "Unmounts an existing mount." ),
             ValueMap { "0", "1", "2", "3", "4", "5", "6", "..", "4096",
                                   "4097", "4098..32767", "32768..65535" },
             Values { "Job Completed with No Error", "Not Supported",
                               "Unknown", "Timeout", "Failed", "Invalid Parameter",
                               "In Use", "DMTF Reserved",
                               "Method Parameters Checked - Job Started",
                               "Size Not Supported", "Method Reserved", "Vendor Specific" } ]
         uint32 DeleteMount(
                 [ IN(false), OUT, Description (
                         "Reference to the created job." ) ]
                 CIM_ConcreteJob REF Job,

                 [ IN, Description (
                         "An existing mount." ) ]
                 LMI_MountedFileSystem REF Mount,

                 [ IN, Description (
                         "The mode in which the configuration is to be applied to the "
                         "MountedFileSystem."
                         "\nMode 0 - Not used."
                         "\nMode 1 - IsNext = 1, IsCurrent = 1."
                         "\nMode 2 - IsNext = 1, IsCurrent not affected."
                         "\nMode 3 - Not used."
                         "\nMode 4 - IsNext = 2, IsCurrent = 2."
                         "\nMode 5 - IsNext = 2, IsCurrent not affected."
                         "\nMode 6 - Not used."
                         "\nMode 32768 - IsNext not affected, IsCurrent = 1."
                         "\nMode 32769 - IsNext not affected, IsCurrent = 2." ),
                     ValueMap { "0", "1", "2", "3", "4", "5", "6", "..", "32768", "32769" },
                     Values { "Mode 0", "Mode 1", "Mode 2", "Mode 3", "Mode 4", "Mode 5",
                                       "Mode 6", "DMTF Reserved", "Mode 32768", "Mode 32769" } ]
                 uint16 Mode
         );
};

[ Association ]
class LMI_HostedMount : CIM_Dependency
{
         [ Override("Antecedent"), Description (
                 "CIM_ComputerSystem reference." ) ]
         CIM_System REF Antecedent;

         [ Override("Dependent"), Description (
                 "LMI_MountedFileSystem reference." ) ]
         CIM_ManagedElement REF Dependent;
};

[ Association ]
class LMI_MountedFileSystemElementSettingData : CIM_ElementSettingData
{
         [ Override("ManagedElement"), Description (
                 "LMI_Mount reference." ) ]
         CIM_ManagedElement REF ManagedElement;

         [ Override("SettingData"), Description (
                 "LMI_MountSetting reference." ) ]
         CIM_SettingData REF SettingData;
};

[ Association ]
class LMI_MountElementCapabilities : CIM_ElementCapabilities
{
         [ Override("Capabilities"), Description (
                 "LMI_MountedFileSystemCapabilities reference." ) ]
         CIM_Capabilities REF Capabilities;

         [ Override("ManagedElement"), Description (
                 "LMI_MountConfigurationService reference." ) ]
         CIM_ManagedElement REF ManagedElement;
};

[ Association ]
class LMI_MountPoint: CIM_Dependency
{
         [ Override("Antecedent"), Description (
                 "CIM_Directory reference." ) ]
         CIM_Directory REF Antecedent;

         [ Override("Dependent"), Description (
                 "LMI_MountedFileSystem reference." ) ]
         CIM_ManagedElement REF Dependent;
};

[ Association ]
class LMI_AttachedFileSystem: CIM_Dependency
{
         [ Override("Antecedent"), Description (
                 "CIM_FileSystem reference." ) ]
         CIM_ManagedElement REF Antecedent;

         [ Override("Dependent"), Description (
                 "MountedFileSystem reference." ) ]
         CIM_ManagedElement REF Dependent;
};

3 Design notes

3.1 NFS shares

The CIM System schema already defines a model for remote filesystems and file exporting. It does not consider any local variant though, thus will not be used. It could, in theory, be used with our mouting model, although that would mean making it very complex (for example, there would be two service classes to create settings). Therefore, remote filesystems shall be implemented using our model.

3.2 CIM_Mount

CIM_Mount is not considered in the schema and will not be implemented. This decision is based on the fact that it is necessary to connect both Directory and FileSystem with MountedFileSystem and associating a CIM_Managed element with an association would mean breaking the original model. Instead of CIM_Mount, two additional associations were introduced (MountPoint and AttachedFileSystebm). Rest of the documentation is inlined in mounting.mof.

3.3 CreateMount() with string arguments

The FileSystemSpec and FileSystemType arguments could be specified as enums, which would lead to a cleaner design. However, 'Other' would have to be used in the enum and another string argument would have to be introduced to cope with it. Therefore, strings are used instead to simplify the API.

3.4 On modes

There are two different properties that the modes consider. They are IsNext and IsCurrent.

             Value   Meaning                                                                                   
           
 IsNext    
           
     1   Is Next. In mounting this means persistency, an entry in /etc/fstab.                      
     2   Is Not Next. No entry in /etc/fstab.                                                      
           
 IsCurrent 
           
     1   Is Current. Currently, the device is mounted. Can be thought of as an entry in /etc/mtab. 
     2   Is Not Current. The device is not mounted.                                                

Service methods perform their operations according to the mode. The table below displays only supported modes.

ModeIsNextIsCurrent
111
21Not affected.
422
52Not affected.
32768Not affected.1
32769Not affected.2

The following tables enumerate all possible combinations of how to call any of the methods.

  1. Device is not mounted and is not in /etc/fstab.
    MethodEffect
    CreateMount(Mode=1)Mount and add the corresponding entry into /etc/fstab.
    CreateMount(Mode=2)Add the corresponding entry into /etc/fstab.
    CreateMount(Mode=4)Error: no effect.
    CreateMount(Mode=5)Error: no effect.
    CreateMount(Mode=32768)Mount.
    CreateMount(Mode=32769)Error: no effect.
    ModifyMount(Mode=1)Error: not mounted or persistent.
    ModifyMount(Mode=2)Error: not persistent.
    ModifyMount(Mode=4)Error: no effect.
    ModifyMount(Mode=5)Error: no effect.
    ModifyMount(Mode=32768)Error: not mounted.
    ModifyMount(Mode=32769)Error: no effect.
    DeleteMount(Mode=1)Error: no effect.
    DeleteMount(Mode=2)Error: no effect.
    DeleteMount(Mode=4)Unmount and remove the corresponding entry from /etc/fstab.
    DeleteMount(Mode=5)Remove the corresponding entry from /etc/fstab.
    DeleteMount(Mode=32768)Error: no effect.
    DeleteMount(Mode=32769)Unmount.
  2. Is mounted and is not in fstab
    MethodEffect
    CreateMount(Mode=1)Error: already mounted.
    CreateMount(Mode=2)Add the corresponding line into /etc/fstab.
    CreateMount(Mode=4)Error: no effect.
    CreateMount(Mode=5)Error: no effect.
    CreateMount(Mode=32768)Error: already mounted.
    CreateMount(Mode=32769)Error: no effect.
    ModifyMount(Mode=1)Error: not persistent.
    ModifyMount(Mode=2)Error: not persisten.
    ModifyMount(Mode=4)Error: no effect.
    ModifyMount(Mode=5)Error: no effect.
    ModifyMount(Mode=32768)Remount with the new setting.
    ModifyMount(Mode=32769)Error: no effect.
    DeleteMount(Mode=1)Error: no effect.
    DeleteMount(Mode=2)Error: no effect.
    DeleteMount(Mode=4)Error: not persistent.
    DeleteMount(Mode=5)Error: not persistent.
    DeleteMount(Mode=32768)Error: no effect.
    DeleteMount(Mode=32769)Unmount.
  3. Device is not mounted but is in /etc/fstab
    MethodEffect
    CreateMount(Mode=1)Error: already persistent.
    CreateMount(Mode=2)Error: already persistent.
    CreateMount(Mode=4)Error: no effect.
    CreateMount(Mode=5)Error: no effect.
    CreateMount(Mode=32768)Mount.
    CreateMount(Mode=32769)Error: no effect.
    ModifyMount(Mode=1)Error: not mounted.
    ModifyMount(Mode=2)Replace the corresponding entry in /etc/fstab.
    ModifyMount(Mode=4)Error: no effect.
    ModifyMount(Mode=5)Error: no effect.
    ModifyMount(Mode=32768)Error: not mounted.
    ModifyMount(Mode=32769)Error: no effect.
    DeleteMount(Mode=1)Error: no effect.
    DeleteMount(Mode=2)Error: no effect.
    DeleteMount(Mode=4)Error: not mounted.
    DeleteMount(Mode=5)Remove the corresponding entry from /etc/fstab.
    DeleteMount(Mode=32768)Error: no effect.
    DeleteMount(Mode=32769)Error: not mounted.
  4. Device is mounted and is in fstab
    MethodEffect
    CreateMount(Mode=1)Error: already mounted and persistent.
    CreateMount(Mode=2)Error: already persistent.
    CreateMount(Mode=4)Error: no effect.
    CreateMount(Mode=5)Error: no effect.
    CreateMount(Mode=32768)Error: already mounted.
    CreateMount(Mode=32769)Error: no effect.
    ModifyMount(Mode=1)Remount and replace the respective entry in /etc/fstab.
    ModifyMount(Mode=2)Replace the corresponding entry in /etc/fstab.
    ModifyMount(Mode=4)Error: no effect.
    ModifyMount(Mode=5)Error: no effect.
    ModifyMount(Mode=32768)Remount with the new setting.
    ModifyMount(Mode=32769)Error: no effect.
    DeleteMount(Mode=1)Error: no effect.
    DeleteMount(Mode=2)Error: no effect.
    DeleteMount(Mode=4)Unmount and remove the corresponding entry from /etc/fstab.
    DeleteMount(Mode=5)Remove from /etc/fstab.
    DeleteMount(Mode=32768)Error: no effect.
    DeleteMount(Mode=32769)Unmount.

3.5 DeleteMount() note

If, after DeleteMount(), IsNext and IsCurrent are both set to 2 (device was unmounted and its persistent entry removed), the corresponding MountedFileSystem, MountedFileSystemSetting and their association are removed. This implies that there cannot be any MountedFileSystemSettingData with both IsNext and IsCurrent set to 2.

4 Use Cases

4.1 Mount a local block device and create the respective entry in /etc/fstab

/etc/mtab: nothing
/etc/fstab: nothing

device = /dev/sdb1
mntpoint = /mnt
setting = default 0 0
CreateMount(Mode=1)

/etc/mtab: /dev/sdb1  /mnt  ext4  rw,suid,dev,exec,auto,nouser,async  0 0
/etc/fstab: /dev/sdb1  /mnt  ext4  rw,suid,dev,exec,auto,nouser,async  0 0

4.2 Remount a local block device with other settings

/etc/mtab: /dev/sda1  /mnt  ext4  rw,suid,dev,exec,auto,nouser,async  0 0
/etc/fstab: anything

device = /dev/sda1
mntpoint = /mnt
newsetting = ro,noexec,user 1 1
ModifyMount(Mode=32768)

/etc/mtab: /dev/sda1  /mnt  ext4  ro,noexec,user  1 1
/etc/fstab: did not change

4.3 Replace an existing line in /etc/fstab

/etc/mtab: anything
/etc/fstab: /dev/sdc3  /mnt/local  ext4  rw,auto  0 0

device = /dev/sdc3
mntpoint = /mnt/global
setting = ro,auto,user 0 1
ModifyMount(Mode=2)

/etc/mtab: did not change
/etc/fstab: /dev/sdc3  /mnt/global  ext4  ro,auto,user  0 1

4.4 Unmount a local block device

/etc/mtab: /dev/sdd1  /mnt  ext4  rw,auto,sync  0 2
/etc/fstab: anything

device = /dev/sdd1
mntpoint = /mnt
DeleteMount(Mode=32769)

/etc/mtab: entry disappeared
/etc/fstab: did not change

4.5 Unmount a local block device and remove the corresponding line from /etc/fstab

/etc/mtab: /dev/sda1  /mnt/foo  ext2  rw,nodev,nosuid,noexec  1 3
/etc/fstab: /dev/sda1  /mnt/foo  ext2  rw,nodev,nosuid,noexec  1 3

device = /dev/sda1
mntpoint = /mnt/foo
DeleteMount(Mode=4)

/etc/mtab: entry disappeared
/etc/fstab: entry disappeared

4.6 Mount an already mounted device (with another mountpoint, will be mounted twice)

/etc/mtab: /dev/sda1  /mnt/foo  ext2  rw,nodev,nosuid,noexec  1 3
/etc/fstab: anything

device = /dev/sda1
mntpoint = /mnt/bar
setting = ro,dev,suid,exec 0 0
ModifyMount(Mode=32768)

/etc/mtab: /dev/sda1  /mnt/foo  ext2  rw,nodev,nosuid,noexec  1 3
/etc/mtab: /dev/sda1  /mnt/bar  ext2  ro,dev,suid,exec  0 0
/etc/fstab: did not change

4.7 Mount a local block device with filesystem specific options

/etc/mtab: nothing
/etc/fstab: anything

device = /dev/sda2
mntpoint = /media
setting = rw,auto 1 1
otheroptions = barrier=1,resize
ModifyMount(Mode=32768)

/etc/mtab: /dev/sda2  /media  ext4  rw,auto,barrier=1,resize  1 1
/etc/fstab: did not change

4.8 NFS mount

/etc/mtab: nothing
/etc/fstab: nothing

device = my.host.org:/pub
mntpoint = /mnt/pub
setting = ro,relatime 0 0
otheroptions = vers=4.0,proto=tcp6,timeo=600
CreateMount(Mode=32768)

/etc/mtab: my.host.org:/pub  /mnt/pub  nfs4  ro,relatime,vers=4.0,proto=tcp6,timeo=600  0 0
/etc/fstab: did not change

4.9 Bind mount

/etc/mtab: /dev/sda5  /media  ext4  rw,user,auto,sync  0 0
/etc/fstab: anything

device = /media/subfolder
mntpoint = /mnt/bind
(setting without an impact)

/etc/mtab: /dev/sda5  /media  ext4  rw,user,auto,sync  0 0
/etc/mtab: /dev/sda5  /mnt/bind  ext4  rw,user,auto,sync  0 0
/etc/fstab: did not change

5 Older versions