Change Disk mount by UUID to LABEL on RaspberryPi4

  • I am rather new to Linux and Open Media Vault, this is my first post. I am running OMV5 on a Raspberry Pi 4 using Debian Buster, with a Samsung 1TB SSD, and occasionally with a 2TB External USB HD to backup the NAS data.


    When OMV was installed it automatically setup the the harddrives mount by using the UUID vice the Label name of the drive. I would like to change this to mounting by Label. I have since read a whole bunch of stuff online about why using UUID is better than using the Label (and I understand them), but since this is a very modest home based NAS, I don't think the reasons for using UUID versus label really apply here as it will only ever have the one SSD installed and occasionally the external hard drive. So I want to change from UUID to the Label NASData to identify my drives and their path.


    I'm hoping the change is as simple as the following:


    First note that:

    a. /dev/disk/by-UUID has the following line (xx's replace actual values):

    xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx -> ../../sda1

    b. and /dev/disk/by-label already has the following line:

    NASData -> ../../sda1


    1. In OpenMedia Vault unmount the SSD;

    2. Using Putty:

    a. create new folder: mkdir /srv/NASData

    b. then edit etc/fstab and change the line from mount by UUID to mount by Label.


    (this is the line originally created by Open Media Vault)

    /dev/disk/by-uuid/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx /srv/dev-disk-by-uuid-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx ext4 defaults,nofail,user_xattr,usrjquota=aquota.user,grpjquota=aquota.group,jqfmt=vfsv0,acl 0 2


    I suspect I want to change it to the following:

    LABEL=NASData /srv/NASData ext4 defaults,nofail,user_xattr,usrjquota=aquota.user,grpjquota=aquota.group,jqfmt=vfsv0,acl 0 2


    4. Save fstab

    5. Reboot


    6. Go back in OMV and:

    a. under Disks find the new Disk by label

    b. under Filesystems find the new disk and Mount it

    c. under Shared Folders add the folders

    d. under SMB/CIFS and then Shares Tab add the shared folders as reqd.


    Then voila all is working again.

    Repeat for the External Harddrive.


    At the end I am hoping to to have new folder with the much easier to type label NASData that I can access all the folders on the hard drive vice the current dev-disk-by-uuid-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx .


    Is it as easy as this or is there an easier way within OMV? Did I miss any steps? Am I outta my mind if I think this is easy?


    Thanks for any help, Pat.:)

    ----------------------------------------------------------------------------------------------------

    Raspberry PI4 - 4GB w/ Debian Bullseye using Deskpi-Pro case :)

    OMV 6.6.0-2 (Shaitan)

  • Thanks Macom, after reading up now on symlinks, I see how that would help in using the CLI with Putty.


    Since I don't have lot invested in this at this time and could start over is there a way during the original setup where I could just set this up using Labels instead of UUID? I ask because last fall when I was just starting to play with this on a Raspberry Pi3 and OMV5 it actually set it up using Labels vice UUID, mounted as srv/DataFiles. However, this time it used UUID and I don't remember doing anything different - just followed the guide.

    ----------------------------------------------------------------------------------------------------

    Raspberry PI4 - 4GB w/ Debian Bullseye using Deskpi-Pro case :)

    OMV 6.6.0-2 (Shaitan)

  • Well good to know and many thanks for the help. :)

    ----------------------------------------------------------------------------------------------------

    Raspberry PI4 - 4GB w/ Debian Bullseye using Deskpi-Pro case :)

    OMV 6.6.0-2 (Shaitan)

  • scarappypappy

    Hat das Label gelöst hinzugefügt.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!