New files are getting "root/root" instead of "nobody/users"


Recommended Posts

My unraid server has gone from an upgrade of 4.7 to 5.0-beta-13 and now to 5.0-beta-rc2

 

I have been trying to troubleshoot why new files created aren't accessible until I run the "new-permissions" script. 

 

Once I run the "new permissions" script -- everything is fine.  UNTIL I put new files again.  Then I can't access those new files from other machines,  and if I re-run the "new permissions" script -- everything is fine again.

 

I can't correlate any consistency on which machine 'created' the file and the problem.

 

I did totally blow-away my flash, installed brand-new 5.0-beta-rc2 and re-setup my UNMENU, etc on it...  same problem.

 

I guess my fundamental question is -- what/where is the mechanism that controls what permissions a NEW file gets.

 

Example of a file with correct permissions -- "nobody / users" -- got "correct" permissions by running the permissions utility...  all systems in my network can access it.

 

root@unraid:/mnt/disk4/Videos#
root@unraid:/mnt/disk4/Videos# ls -l S*
-rw-rw---- 1 nobody users 734554112 Apr  6 17:21 Stomp\ Out\ Loud\ +\ Brooms.avi
root@unraid:/mnt/disk4/Videos#

 

Example of a file created after the permissions script was run....  is "automatically" set to "root / root" -- and has access problems from other machines

 

root@unraid:/mnt/disk10/Videos# ls -l
total 1772537
-rw-rw---- 1 root root 1813305348 May  7 09:34 The.Amazing.Race.S20E11E12.HDTV.XviD-AFG.avi
root@unraid:/mnt/disk10/Videos#
root@unraid:/mnt/disk10/Videos#

 

Link to comment

create a new user via the unRAID webUI and use that login if you have authentication set up on the server.  Do not use the root user unless you need to log in via telnet or the like.

 

Yes, I am using a non-root user account to access the Unraid server.  Same issue. 

Link to comment
  • 3 weeks later...

did you get anywhere with this, Chuck? I am having the same problem; I don't know if its related to my upgrade to a Pro key, or my upgrade to RC2, both of which I did at the same time.

My guess is the RC2 upgrade -- I had a pro key forever, and that other than the # of drives supported, I don't think it changes any internals that would relate to this issue.

 

As far as my progress -- well, it's been fits and starts -- I had been temporarly satisfied by just re-running the permissions script after uploading a new DVD or something...

 

I then read somewhere (here? maybe) about creating a /boot/config/smb-extra.conf file -- mine looks like this:

 

[Global]

  force create mode = 0666

  force directory mode = 0777

  force user = nobody

  force group = users

  create mask = 0666

 

Now, that seems to me to be a brute-force solution to using a user/group of demand.

 

I also, though, have upgraded to RC3 as well.

 

Just did a quick test...  with the new conf file and RC3 and it looks like I am getting correct ownership/group info:

 

 

mkdir test2

 

result:

drwxrwxrwx 1 nobody users        48 May 23 06:40 test2/

 

 

echo test > file_test

 

result:

-rw-rw-rw- 1 nobody users 7 May 23 06:41 file_test

 

~Updated:  Is no longer good advice -- upgrade to a newer version of 5.0 instead.

Link to comment
  • 8 months later...

 

I then read somewhere (here? maybe) about creating a /boot/config/smb-extra.conf file -- mine looks like this:

 

[Global]

  force create mode = 0666

  force directory mode = 0777

  force user = nobody

  force group = users

  create mask = 0666

 

Now, that seems to me to be a brute-force solution to using a user/group of demand.

 

I also, though, have upgraded to RC3 as well.

 

Just did a quick test...  with the new conf file and RC3 and it looks like I am getting correct ownership/group info:

 

 

mkdir test2

 

result:

drwxrwxrwx 1 nobody users        48 May 23 06:40 test2/

 

 

echo test > file_test

 

result:

-rw-rw-rw- 1 nobody users 7 May 23 06:41 file_test

 

I tried adding this to my smb-extra.conf file but it did not take.

Do I need to restart the machine for the changers to take place?

I am running unRAID Server Pro  version: 5.0-rc8a

 

Link to comment

I think a better idea would be to upgrade to UnRAID v5.0-rc11, and run the *new* NewPerms utility.  I believe it takes care of that new files ownership problem.

 

If you still want to try the smb conf edits, you may just need to restart Samba:

 

samba stop
samba start

 

If it doesn't help, then yes, reboot.

Link to comment

I think a better idea would be to upgrade to UnRAID v5.0-rc11, and run the *new* NewPerms utility.  I believe it takes care of that new files ownership problem.

 

Concur.  I just edited my "old" post to strike-out my prior attempts.  Upgrading the version level of 5.0 and running the New Permissions is a MUCH better solution.

 

@Others - So is, ensuring, that you are NEVER using 'root' to mount shares, etc -- I think that got disabled {so you can't} -- but in any case, don't do it :)  Create a user account using the menus in UnRaid and always access your shares that way.    The difficulty I and others encountered with changing to this, is that WIndows has a nasty habit of 'caching' credentials -- so it may require to also change the password of 'root' so that you force Windows not to connect with old credentials.

Link to comment

My unraid server has gone from an upgrade of 4.7 to 5.0-beta-13 and now to 5.0-beta-rc2

 

I have been trying to troubleshoot why new files created aren't accessible until I run the "new-permissions" script. 

 

Once I run the "new permissions" script -- everything is fine.  UNTIL I put new files again.  Then I can't access those new files from other machines,  and if I re-run the "new permissions" script -- everything is fine again.

 

I can't correlate any consistency on which machine 'created' the file and the problem.

 

I did totally blow-away my flash, installed brand-new 5.0-beta-rc2 and re-setup my UNMENU, etc on it...  same problem.

 

I guess my fundamental question is -- what/where is the mechanism that controls what permissions a NEW file gets.

 

Example of a file with correct permissions -- "nobody / users" -- got "correct" permissions by running the permissions utility...  all systems in my network can access it.

 

root@unraid:/mnt/disk4/Videos#
root@unraid:/mnt/disk4/Videos# ls -l S*
-rw-rw---- 1 nobody users 734554112 Apr  6 17:21 Stomp\ Out\ Loud\ +\ Brooms.avi
root@unraid:/mnt/disk4/Videos#

 

Example of a file created after the permissions script was run....  is "automatically" set to "root / root" -- and has access problems from other machines

 

root@unraid:/mnt/disk10/Videos# ls -l
total 1772537
-rw-rw---- 1 root root 1813305348 May  7 09:34 The.Amazing.Race.S20E11E12.HDTV.XviD-AFG.avi
root@unraid:/mnt/disk10/Videos#
root@unraid:/mnt/disk10/Videos#

 

How is Amazing.Race being created?

Link to comment

How is Amazing.Race being created?

 

Not sure I remember -- Quote from: chuck23322 on May 07, 2012, 12:00:09 PM

 

Probably was a torrent...  most of my avi's then were.

 

My issues were solved by upgrading my 5.0 and me no longer using "root" to mount shares.  And working out my Windows boxes who were caching credentials still to 'root' (changed root's PW to fix that and used a 'user' account) 

 

Another user 'bumped' this thread having similar problems.

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.