I’m using Navidrome in CasaOS on a Pi for music right now and I like it quite a bit. The one thing irking me was that the network storage mounts you can define within CasaOS (Files > Location > Connect network storage) don’t persist. At least they don’t for me – every reboot or update and they’re gone.
I’ve gotten around this by creating a persistent mount within Raspbian utilizing CIFS.
SSH into your Pi, and go ahead and
to avoid having to sudo every line you input. First, make sure cifs-utils are installed (they should be, but still):
|
apt-get install cifs-utils |
Now create a credentials file for your mount to access using nano:
Populate the credfile with the credentials necessary to access your Windows share:
|
username=user password=password domain=domain (if applicable) |
Save it, then set the appropriate permissions to keep it safe from prying eyes:
|
chown root: /etc/credfile chmod 600 /etc/credfile |
Create a mount directory on your Pi to link the share to:
|
mkdir /mnt/linux_sharename |
Now open fstab:
Add your mount to the bottom of the file, changing the first path to the Windows share and the second to the mount path you created previously:
|
//WIN_SHARE_IP/share_name /mnt/linux_sharename cifs credentials=/etc/credfile,file_mode=0755,dir_mode=0755 0 0 |
Finally, reload the daemon:
And mount the share using the details you defined in fstab:
|
sudo mount /mnt/linux_sharename |
To confirm, cd to the share and confirm you can see the contents.