How to manually fix permissions.


Go to solution Solved by BRiT,

Recommended Posts

I'm trying trying to fix permissions recursively to the standard unraid permissions at the end of a User Script but I can't figure out how.

So far I have:

 

chown -R nobody:users /mnt/user/backups-gdrive/
chmod -R u=rw,go=rw /mnt/user/backups-gdrive/
 

But I know that directories should also have +x.

 

What would be the correct chmod command?

 

Link to comment

Unraid GUI > Tools > New Permissions is a once off tool to clean up perms, it also shows the reference permissions/ownership that are set.

 

(New Permissions tool)...changes file and directory ownership to nobody/users (i.e., uid/gid to 99/100), 
and sets permissions as follows:

For directories:
  drwxrwxrwx

For read/write files:
  -rw-rw-rw-

For readonly files:
  -r--r--r--

 

Edited by tjb_altf4
Link to comment
55 minutes ago, frank-unr said:

Thanks! That should work. I didn't know about this newperms command.

There is also a Docker-Safe NewPerms command too, but I'm not sure where that's actually at and have only invoked it from the UI. I forget which CA-plugin provides it, if it's from the main "Community Applications" or one of the addons.

 

As long as you don't run that newperms script against your "appdata" location or where you have dockers setup, you should be fine.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.