Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Directory structure

Featured Replies

So far I have been treating subfolders of subfolders of /mnt as interchangeable.  But from the terminal, if I go to what I thought was the same directory mapped differently, one folder contains a lot more.  Can someone explain how/why the directories are set up this way?

disk1.PNG

user.PNG

https://wiki.unraid.net/UnRAID_Manual_6#User_Shares

 

Your first shot is only /mnt/disk1, the second is /mnt/user, which shows all the disks.

 

Same files, different view. Don't copy or move files between the two different folder structures without understanding exactly what is going on behind the scenes. You WILL erase your data if you do it wrong.

  • Author

Thanks, that is quite helpful.  But just to confirm before I accidentally erase any data...

 

My goal is to create a command in User Scripts to auto move, rename and sort photos from /Incoming into /Sorted. 

exiftool '-filename<$EXIF:DateTimeOriginal' -d '/mnt/user/Photos/%Y-%m/%Y-%m-%d-%H%M%S%%-c.%%e' -r /mnt/user/Incoming

Both folders are user shares.   /Incoming is public and /Photos is secure.  The windows user has r/w access to /Photos and I am assuming User Scripts is running scripts as root which should have access to all shares.  What is the proper way to reference the shares Photos and Incoming?

 

Also, for the most part I am using the files from as the windows user via SMB.  I would assume SMB shares by design prevent users from accidentally screwing anything up.  However sometimes windows wants to download then re-upload files (I think when they are different shares), I am doing a lot of the initial sorting via a Krusader docker.  That is running as root, so when you are using the gui, you are root.  If I am moving files from place to place between the two shares, I would assume the proper path to the share is the same as above, correct?

 

Finally - and I assume this is the same answer here too - I am using a dupeguru docker to go through the /Photos share to find duplicates and move them out to a separate /Duplicated share.  Same path?

48 minutes ago, RadOD said:

I would assume SMB shares by design prevent users from accidentally screwing anything up.

As long as you don't enable disk shares, you are ok with SMB.

 

When working with /mnt paths, as long as you stay totally within /mnt/user you are totally fine.

 

Don't mess with /mnt/diskX or /mnt/cache until you understand exactly why I'm telling you not to. When you understand what's happening behind the scenes, it's easy to avoid corrupting data, but until you have a good grasp, it's safer just to stick with /mnt/user.

 

As you've figured out correctly, user shares are simply the contents of /mnt/user. Keep in mind that windows can't handle folders with case differences, but the command line can. So writing files to /mnt/user/Photos and /mnt/user/photos is going to cause confusion in windows, but your scripts on Unraid won't care, it's two different folders to Unraid. Be careful to stay case consistent.

 

Docker containers add a wrinkle, the paths inside the container are mapped to paths on the host. So, if you have dupeguru mapped with

 

host - /mnt/user

container - /UNRAID

 

for example, you would find all your user share folders in the /UNRAID folder inside dupeguru.

 

All this and more is covered in the FAQ's pinned around the forum.

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.