1st time ever with a Freenas Install-Delete Errors after Freenas loaded with testdata

Status
Not open for further replies.

rst6616

Cadet
Joined
Oct 3, 2012
Messages
4
WARNING: LONG
Believe me I have tried to read enough to setup and get a properly working NAS. I followed the step by step instructions given by Maximumpc recent article on "Roll your own Home Server" Oct 2012 issue. For this being by 1st ever install, I think I have done well. I managed to set up a mostly working freeNAS (version 8.2.0) without much difficulty. My problems are probably from not understanding some of the setup options correctly, but unfortunately I don't know which ones. I have completed the install as follows:

My hardware is using 8 2tb drives (I have a lot of data to store).

1. Install the OS. (on to a 4gb flash drive) This worked perfectly and boots right into freenas8.2.0. I have changed the admin password, added the root account email address, & console logging as per the Maximumpc instructions. Booted up and typed into the 192.168.0.189 address on another separate windows7 computer & brought up the NAS server.

2. Set up Storage. I have created a volume name and selected the 8 drives, zfs filesystem and RAIDZ2. My 8 drives create a volume with approx 10.7TB. I then created only one dataset with compression level "inherit", enable atime "inherit", Quota for this dataset/Quota for this dataset & all children/Reserved space for this dataset/Reserved space for this dataset & all children" all to zero.

3.Add Users & Groups. I created a new user username: Ron; Create a new primary group for the user: checked; ; Home directory: /mnt/RSVOL/RSDATASET; My home directory mode: ALL 9 boxes Owner/Group/Other & Read/Write/Execute checked; Shell: csh; Disable password logons checked; and SSH Public Key completely blank.

4.Configure Permissions. I clicked on Change Permissions and selected Owner: Ron ; Owner(group) wheel(SHOULD THIS BE "Ron"?); mode has ALL 9 boxes Owner/Group/Other & Read/Write/Execute checked; Type of ACL: unix; set permissions recursively: unchecked. My goal with these settings is to have complete read/write/execute permission for ALL files and directories on the entire volume and dataset.

5.Set up a Media Share. Went to "Sharing then Add Windows (CIFS) share"; dataset name: All_FreenasData" and set the dataset path to /mnt/RSVOL/RSDATASET; export read only:unchecked; Browsable to Network Clients: checked; Inherit Owner: checked; Inherit Permissions: checked; Export recycle bin: unchecked;Show hidden files: unchecked;Allow guest access: checked; Only Allow Guest Access: unchecked;

6. Go to my Media Share and copied ONE main directory (from my window7 computer) with many sub-directories and many sub-sub directories with lots of deep sub-directories into the freenas dataset. About 15,000 files in all. Took less than 1 hour. Everything seemed to be ok except the following:

A) Before I copied this one main directory into the freenas newly created dataset, it already had the following files in the dataset: ".cshrc .login .login_conf .mail_aliases .mailrc .profile .rhossts .shrc" listed in the root. WHY?
B) As a 1st test, after I copied my one main directory and all of its sub-directories and 15,000 files from the Windows7 computer to the freenas share, in windows7 again, I tried to do the reverse by selecting my just created root directory in the freenas share and hitting the delete windows command. Windows preceded to delete many of the sub-directories BUT refused to delete some of the sub-directories complaining that the sub-directories were not empty. In order to complete the full deletion, I needed to to manually travel down to lower sub-directories, open them, and then select and delete these files separately. Some directories & sub-directories & files were correctly completely deleted while others sub-directories and files had to be emptied manually. WHY?

Thanks to all that at least read my question. Much appreciated.

Ron
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
A) Before I copied this one main directory into the freenas newly created dataset, it already had the following files in the dataset: ".cshrc .login .login_conf .mail_aliases .mailrc .profile .rhossts .shrc" listed in the root. WHY?
Ron

Hi Ron,

Not sure about your second question, too many variables.

On your first question. When you created the account for yourself, did you make the "home directory" the same folder as your new dataset?

My guess is the answer is yes. These are basic user files (templates) that are created for a new user and by default are created in that user's home directory.
 

rst6616

Cadet
Joined
Oct 3, 2012
Messages
4
Hi protosd,
Thank you for reading my post and then kindly giving me some response.

I guess I should have left the user's home directory the default: /nonexistant ?

Ron
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
I guess I should have left the user's home directory the default: /nonexistant ?


You could have, if all you're really going to use the account for is connecting with CIFS. You could also just create another directory or dataset and edit the account to point to one of those locations.

I was thinking about your other question. Even though you set all of those permissions etc. when setting up FreeNAS, when you copied over those files, whatever permissions they had before they should have after you copied them. My guess is that if you tried to delete them from the location you copied them from you would have the same problem (or not), except probably where they are now, you do have permission to delete them.

I usually just avoid using the GUI to change permissions. Each operating system has it's own type of permissions and they don't always work the same on different OS's. It can get really tricky unless you really understand how things are supposed to work on each OS.
 

rst6616

Cadet
Joined
Oct 3, 2012
Messages
4
protosd,
I am trying to keep this server simple by only setting up one volume with one dataset holding all for my 4tb of data and growing. I would then divide the dataset into one root directory for each interest containing everything to do with a topic(ie pictures/photography&Cameras/Computer Programs/Computer ArticlesbyOS/Corals&SaltWaterFish/Computer Hardware/Computer Software/etc/etc. To many interests and hobbies including my serious love for photography.

At any rate, it is a real pain if I want to delete one of these main root directories and only a portion of them actually get deleted due to some "(sub)directory not empty" error. The weird part is that while deleting the main directory from the root, there are thousands of (sub)directories within that don't give this error and get deleted without complaining all in the same root directory tree. I don't understand what a directory not empty error has anything to do with the permissions and then these same sub-directories that were in error can easily get deleted just by going down the directory tree and then issuing the delete command again and then the delete of that sub-directory suddenly works! Very hard to understand.

Sorry for my rant. I just wanted to thank you for your attention.
Ron
 

pete_c20

Dabbler
Joined
Nov 23, 2012
Messages
23
I know this thread is a little old but something that may help others too.
Like yourself I've seen this refusal to remove some directories by Windows, in this case Win Xp SP3. After quite a bit of experimentation here's some things that I've found that may help.
1) Delete files and/or directories with them in the right hand window of explorer, not the left hand window.
2) Before attempting to delete huge numbers of files, right click the properties box for the top of the tree, and set or unset properties and/or permissions for everything below it. As protosd says when crossing OSs this may cause issues.
3) And this may be one to watch out for in long backup jobs - In Windows make sure the total pathname length does not exceed about 240 characters. From memory I think the max is about 255 chars before problems set in. Sometimes you can get funny errors or aborted backups if the paths are too long. Sometimes a copy or other action might go through ok, and then another might not.
There are some good freeware tools about to search out long pathnames.

My guess is that these problems are a Windows issue not a freeNAS issue.

Hope that helps.
 
Status
Not open for further replies.
Top