You need permission to access this server error...

Status
Not open for further replies.

GlueFactoryBJJ

Dabbler
Joined
Oct 15, 2015
Messages
32
Warning: n00b alert! Please be aware that this is long so other can learn from my (many) mistakes!

OK, here are the basics:

Motherboard: Gigabyte F2A88XM-D3H
CPU: A6-5400K 8-core AMD APU
RAM: 16GB DDR3 (non-ECC)
SSD: Sandisk 120GB (Boot)
HDD: 6 x WD RED 4TB in ZRAID2 (16TB net storage)
NIC: Intel Pro D33745 1-Gigabit
Generic Case with multiple fans
FreeNAS Version: FreeNAS-9.10.1 (d989edd), but my initial install version was 9.3.n

FWIW, I don't think any of the above are responsible for my, admittedly, semi-self-inflicted wound. I need to note that this server has been running perfectly for at least 3 months before I recently messed things up.

A few days ago, I was possessed by the thought of being able to access my movie collection via my FreeNAS server. So I did a BUNCH of things at the same time. Yeah, I know, BIG mistake! (I plead exhaustion because most of this happened well past midnight... :-/ )

Initially, I was going to use some form of DLNA, but since there isn't a "native" plug-in for DLNA, I thought that the Plex server plugin would work well. I also thought it would be good to finally set up an email address so I could get alerts if there were problems with the FreeNAS server.

How to mess up a FreeNAS server's settings in 4 easy steps

After fighting with this problem so long, I don't remember the exact order I started doing this, but this is my best guess:

1. Set up email address. More accurately, probably messed up setting up email address.

2. Tried getting the Plex server plugin working. I did this by trying to "religiously" following the FreeNAS Team's Plex Server Install video below:

FreeNAS® 9.2.1: Plex Media Server Plugin

3. I tried multiple things after reading many posts. Many of these were (seemingly) much more complicated than whatever I did to mess things up.

4. Succeeded (kind of) with #1, failed miserably with #2 and #3.

#1 - Set up email address

Ok, let's get #1 out of the way, especially since it was a combination success/failure (and might be the "real" source of the problem?).

So I signed into the FreeNAS server as root. I clicked the "Email" tab under "System". I entered the correct information and clicked "Send Test Message". I didn't receive anything. Then I realized there wasn't a "To:" address for the email. Then I saw the, "HINT: Test e-mails are sent to root user. To configure it use Account -> Users -> View Users -> root -> Change E-mail" text and realized I needed to set up an email address to receive these messages for/from root.

So I ALMOST did what it said in the above quote, with the exception of "Change Email" part (Fail #1). I missed the button(s) at the bottom of the screen because everything else is at the top. So I double clicked "root" and saw the "Email" field and filled it out. (NOTE) Since there was a password field just below the email field, I ASSUMEd that it was for the email password (Fail #2)! Oops!

I later realized, when I couldn't sign into the server, that the password fields were NOT for the email address, but rather for the "root" account login. So I used the "email" password to sign into the server and changed the password back to what it was before I changed it.

Anyway, the server is sending out emails and I'm getting them. So mission "accomplished".

#2 - Setting up the Plex Media Server plug-in according to the "FreeNAS Team" video

Strangely, before starting this part, I noticed that I, somehow, had TWO instances of the Plex Media Server installed when I looked under the Jails tab. Of course, I first uninstalled both of those by .

Because I'm such a n00b with FreeNAS and FreeBSD/Unix/Linux, I decided to follow the instructions in the video EXACTLY. (Note: Fail #1)

I have an existing dataset/CIFS share on my (home) server called, say, "backups". I initially thought I'd use that dataset/CIFS share. I later tried following the instructions more carefully my creating a "yourshare" dataset and "yourvideos" CIFS share, but with no luck.

After "creating" (i.e. using the existing dataset) the "backups" dataset, I followed the instructions and clicked the "Change Permissions" button. The video (~3:20 min) says to click the "Write" option under "Other" to set the correct permissions (the "Unix" radio button is clicked in the video).

Hmm, that's strange. MY dataset has the "Windows" radio button clicked. So, trying to be "faithful" to the instructions, I change it from "Windows" to "Unix" and click the "Write" box under "Other", click the "Set permission recursively" box and click, "Change" (Fail #3). It takes awhile because I have a LOT of files backed up on this server. After about 5 minutes, the recursive permission change appears to have completed without error and I'm starting to feel pretty good about this so far (sigh!).

Since the "jails" dataset had already been created with my (apparent, but not remembered) previous Plex Media Server installs, I decided to skip to the "CIFS Shares" creation part (~4:25 min). I added a "MediaShare" CIFS share exactly as described in the video, with the exception that the dataset/directory were different (backups/movie directory) and set the share to "Allow Guest Access".

Here is the current "Storage" tab:

FreeNAS Storage Tab Info.jpg


The new CIFS share was started. I could verify that I could see the correct directory when I connected to the share. I tried to copy a movie file to that share and... "Red Alert!" I was unable to copy a file to that directory. I was also unable to move files around that are already on the server.

The error I received when trying to move, copy, etc. files with Windows Explorer was, "You need permission from GOOBER/root to make changes to this file". Strange.

Error popup when trying to delete a file.jpg


#3 - Trying many different things to fix this problem

So, among the MANY things I've tried to resolve this are the following:

1. I looked at the "Change Permissions" button options and... as outlined in SO many posts, the "Write" box under "Other" was not checked. I tried checking the box and recursively apply this setting. While the "Change" button changed to "Please wait..." for quite some time (as usual), when I went back into the permissions, the "Write" box was still unchecked. I tried this at least 20 times.

2. I tried changing it back to "Windows" and applying the permission change recursively (at least 10 times) with no luck.

3. I tried changing it back and forth from Windows to Unix and back again many times (at least 5 times) with no luck.

4. Creating new datasets and CIFS shares. I created these EXACTLY (this time) as described in the video with no luck.

5. I changed the permissions on the various datasets to "Windows" and then tried managing the permission from Windows with no luck.

6. I have checked and rechecked "root" to see if I can see anything there that is different between what I can remember seeing before this problem (when I had full access to my files) and now that I can't copy/delete/

Because of this problem, I now cannot write ANY files to any dataset/share I create on this server. I can read all of them just fine, but no copy/delete/change for any files on the server. Because of this, as you can imagine, none of my local PC backups are taking place.

I can't just replace this server (or do anything to endanger my files) because I don't have sufficient other backup storage to back up this server, reinstall, and copy the data back. I currently have about 13.5TB of data on the server. Many duplications, but I haven't had time to finish the file consolidations yet (many duplications of files on the local PCs). I had thought of deleting all datasets and recreating them, but then I'd be deleting the data, correct?

Anyway, I do not have any idea of how to get this server working again that does not include formatting the drives and starting over.

Oh, and I don't have a backup of the server boot drive that I could use to restore the server to "pre-my messing everything up" settings. Yeah, that will be one of the first things I'm going to do when I get this working again.

I've even thought of loading the FreeNAS 10 beta to see if that will help iron out my problems, but I'm afraid that will just mess things up worse since there are problems with my current 9.10 install.

I really need some help. I hope y'all can provide some insight as to how I can fix this! Thanks!

Scott
 
Last edited by a moderator:

GlueFactoryBJJ

Dabbler
Joined
Oct 15, 2015
Messages
32
One other thing I forgot to mention is that there was an update that happened AROUND this time. However, I cannot clearly remember whether or not it was before or during the time I first noticed this problem.

Scott
 

nojohnny101

Wizard
Joined
Dec 3, 2015
Messages
1,478
some advice and guidance of why you are not getting any responses. You are much more likely to get a response if you are very specific and limited in scope. Sometimes posting long winded and scattershot posts reduces your chances of someone wanting to help you with your problem. I'm just saying this to try and help you out in the future.

With that being said, I'll try and contribute something:

1) I don't see any problem here. you added an email to root user, accidentally changed the password (which is also the password for accessing the GUI) and then you changed the password back. no problem there.

2 & 3) I really don't know where to start with this one. you should be able to login as the root user to the dataset that you are having permissions problems on correct? then maybe you can do a "chmod owner:user group:user". Are your permissions right now windows or unix? When you say you "change it back and forth between windows and unix permissions" but nothing happens does the GUI give you an error message? One last thing I will mention. If you can access your files through a SFTP client then that might give you the power to change permissions easily. Sounds like you are on windows but I use cyberduck on mac. I had a weird permission problem once where it would not let me change from the GUI but once I browsed the files through SFTP and cyberduck, I was able to change the permissions though.

Oh, and I don't have a backup of the server boot drive that I could use to restore the server to "pre-my messing everything up" settings. Yeah, that will be one of the first things I'm going to do when I get this working again.
Yea get that taken care of. Many ways to do it, numerous ones you'll find on here just by searching but this is the one I use:
Configuration File Automatic Backup
 

m0nkey_

MVP
Joined
Oct 27, 2015
Messages
2,739
Sounds like you messed up your permissions. Check out my Samba permissions video in my signature.
 

GlueFactoryBJJ

Dabbler
Joined
Oct 15, 2015
Messages
32
2 & 3) I really don't know where to start with this one. you should be able to login as the root user to the dataset that you are having permissions problems on correct? then maybe you can do a "chmod owner:user group:user". Are your permissions right now windows or unix? When you say you "change it back and forth between windows and unix permissions" but nothing happens does the GUI give you an error message? One last thing I will mention. If you can access your files through a SFTP client then that might give you the power to change permissions easily. Sounds like you are on windows but I use cyberduck on mac. I had a weird permission problem once where it would not let me change from the GUI but once I browsed the files through SFTP and cyberduck, I was able to change the permissions though.


Yea get that taken care of. Many ways to do it, numerous ones you'll find on here just by searching but this is the one I use:
Configuration File Automatic Backup

When I said I changed the permissions "back and forth between Windows and Unix permissions", I meant that I alternatively change them from Windows to Unix (set to what should have been 777 (all boxes checked)), clicked the recursive box and clicked the "Change" button. The permissions type would change from Windows to Unix, but the permissions box would not reflect the additional Write box in "Other" and I still wouldn't be able to copy/write/delete any files on the share.

Then I'd try changing back to Windows. The change would appear to take affect (permissions would have the Windows radio button "checked"), but I would not be able to either change the permissions or copy/write/delete any files on the share.

I'm going to download that backup script and definitely get it going so I won't run into this kind of problem again!

HOWEVER, I was able to resolve this problem. Unfortunately, I really don't understand why (see post below)...
 

GlueFactoryBJJ

Dabbler
Joined
Oct 15, 2015
Messages
32
There was another post on this thread (YouTube channel m0nkey_ ?) that suggested I check out his videos on Samba/CIFS permissions, but that post appears to have disappeared (at least for now). I wanted to be sure to credit him with the "solution".

Ok, this is where it gets kind of weird. I watched his video (FreeNAS and Samba (CIFS) permissions). As I was watching him create new datasets, groups, users, and shares, I noted that he used the Unix group "nobody" as the Owner (group). When I created the original dataset (and others to try to get this to work), I had used the default Owner (user) and Owner (group), root and wheel, respectively.

This time I was going to make only one change at a time so that I would KNOW where the fix happened. For whatever reason, I fixated on his use of the "nobody" group. So I thought, "What the heck" and went into the "Change Permissions" for the original dataset that I couldn't change (basically read-only) AND changed the Owner (group) setting from "wheel" to "nobody". The permission type was "Unix" and to implement this change throughout the dataset, I checked the "Set permission recursively" box and clicked the "Change" button.

It took its normal minute or two to make the change. With little hope I tried to copy a file from one directory to another and, "Voila!" IT WORKED! I know it was this change that made things work because I had just tried to copy a file to the directory just before making the change.

I don't know why making this change in the Owner (group) from "wheel" to "nobody" would have this effect. Especially since I was able to do everything I needed to the server (backups, copying, deleting, etc.) for MONTHS with the Owner (group) set to "wheel".

Anyway, this small change has resulted in my having full access to my server again! Thanks to everyone with their suggestions! A special thanks to "m0nkey_" (you know who you are... ;-) ).

I'm half tempted to change the Owner (group) back to "wheel" just to see if I go back to the problem again, but I'm kind of paranoid right now and don't want to mess it up again and possibly "break" the "nobody" group.

Unfortunately, this still doesn't resolve my original task of setting up the Plex Media Server... However, that is a question for another thread!

Thanks again!
 

m0nkey_

MVP
Joined
Oct 27, 2015
Messages
2,739
There was another post on this thread (YouTube channel m0nkey_ ?) that suggested I check out his videos on Samba/CIFS permissions, but that post appears to have disappeared (at least for now). I wanted to be sure to credit him with the "solution".
Thread still exists. See the link in my signature.
 
Status
Not open for further replies.
Top