brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: never copy between a user share and a disk share with the same folder name

Unraid
~/tips/tip-unraid-user-share-disk-share

/mnt/user/media and /mnt/disk1/media can be the same files

Warns against copying between a user share and a disk share, which can destroy the files.

This is one of the few Unraid mistakes that can eat your files. The paths look different, so you do not see it coming.

User shares live under /mnt/user and combine folders from the array and the pools. Disk shares are single drives, such as /mnt/disk1. Both are views of the same files. A folder you see in a user share also exists under the disk share of the drive that holds it.

/mnt/user/media  and  /mnt/disk1/media  can be the same files

The docs are blunt about it. Never copy files directly between a user share and a disk share if the folder names are the same. It can corrupt or delete files, and the loss is permanent. Commands like cp and rsync cannot always tell the two views apart, so they can overwrite or delete files by accident.

Their rule is to stay in one world per operation: user share to user share, or disk to disk, never mixed. Disk shares are off by default. You turn them on under Settings, Global Share Settings, and I’d leave them off unless I have a reason.

The caveat is that this also applies to scripts and containers. A container that has /mnt/user in one path and /mnt/disk1 in another can trigger the same problem. Check what your mappings point at.

Further reading: Unraid docs: Shares, On this site: Included disk(s) keeps a share on the disks you choose, On this site: point the syslog server at the server itself to keep logs on a share

Going deeper: Guide: your Unraid cache is full and Docker stopped, how to find out why and fix it

More Unraid tips Change the RAID profile of a Unraid BTRFS pool with Balance Replace a disk in a redundant Unraid pool from the Main tab Test every Unraid drive with the DiskSpeed container See the XML behind a VM with the inline XML view in Unraid 7 Choose where a new VM's disk image is created with Unraid's storage override All Unraid tips (77) All topics

Link