Simple question for the experts...


Recommended Posts

Since I plan to use my unRAID as my main storage for almost everything that doesn't need installation I wonder if the following scenario will work.

 

I plan on building a root folder structure for example:

 

Emulators

Personal

Audio

Video

...(about 10-15 such folders)

 

and make the same structure on ALL my array disks. Say it again in a single phrase: All upper level folders on all the disks.

 

Will this allow me to effectively (through user shares) use all my disks to spread all data of all the above folders transparently?

(I don't plan to use the single disk shares)

 

And what happens if I create a new folder INSIDE one of those folders (through the share not locally from unRAID)? Will it be created randomly on one of the disks that contain the top level folder or on all disks?

 

I read FAQ and instructions but was not too clear on the matter.

 

 

Link to comment

I'm not using the user shares function currently for writing, but I can tell you that if I access the 'video' folder on my Unraid, I see all of the files that are on all of the disks that have the 'video' folder on the root. So, I believe the answer to your question is YES. Also, I have folders on all of my drives that are one level down from the root directory and they operate in the same fashion.. i.e. I can see all files on all disks that share the same directory name. /Video/DVD_Movies/ for example shows all files on all disks in the DVD_Movies folder.

 

Hope this helps!

 

Scott

Link to comment

yes it helps

 

still I don't get:

 

if I have a folder "movies" in all my disks, ok I see it as one share - got that

BUT

if THROUGH WINDOWS (not locally on unRAID terminal) I creat a folder "Documentaries" UNDER folder "movies", will this folder be created in all disks with folder "movies" or something else will happen?

 

 

Link to comment

yes it helps

 

still I don't get:

 

if I have a folder "movies" in all my disks, ok I see it as one share - got that

BUT

if THROUGH WINDOWS (not locally on unRAID terminal) I creat a folder "Documentaries" UNDER folder "movies", will this folder be created in all disks with folder "movies" or something else will happen?

 

 

I had a user share "Movies" as you described.  Using Windows explorer I made a folder within it named "HT-Pictures."

When I look at the disks on my server the new "HT-Pictures" folder was created only in /mnt/disk4/Movies. It did not create it in all the disks.  I have no idea what it will do when disk4 is full if I continue to add pictures to "HT-Pictures"  Movies is set up as "High Water" allocation with a split level of 0.

 

Joe L.

Link to comment

I think that the shares is a fairly undocumented feature.  I read the manual at least 3 times and still was not sure why they worked the way the did.  When I first setup my server I had 3 drives with the parity.  I created Movies share and the directory was created on the 2 drives no prob.  When I added a drive I thought Movies should be created automatically.  Wrong.  I tried stopping and starting and rebooting, nope.  When I started adding more files to movies, then it created movies on the other disk.  The same thing seems to happen with subs.  As you add more and more files it will add the directories to the other drive based on your filling rules ie high water.  One thing that really caused me a lot of trouble was the split level.  It is set I think at 1 by default, I think the default should be higher.  If it is set at one it will not created the other subdirectories on the other drives.  I just set mine at 99, as I do not plan on having more than a couple of directories deep anyway.

Link to comment

but what has the split level have to do with how deep you plan to have your folder tree?

 

(yes I am confused)

 

edit: and Tom is nowhere again (plus hasn't responded my 10 days old email or my PM ...that was about my email - which in fact a reply to a question he asked me on PM, so I expected he would read)

 

 

Link to comment

Yes I agree 'split level' is very confusing & hopefully we'll figure out a better solution.

 

It might help to understand what is the problem we are trying to solve:

 

1. On the one hand, we want to let the system store files under one network share across multiple disks.

2. On the other hand, there are times when we want certain "sets" of files to be stored on a single disk.

 

What is a case of a set of files that we want to store on a single disk?  Well it's the set of files that make up a single media.  For a movie, it's the IFO, VOB, folder JPG, XML metadata, etc. files.  For music, it's all the files associated with a single album (the music data and cover art files).

 

We want these files to be on the same disk so that as we read the media there won't be a 'pause' when the player accesses a file on a different disk which happens to be spun down.

 

Getting back to 'split-level' - realize first that individual files can never be split across disks - that is, suppose you want to create a single 1GB file - well it will exist as a single file on a single disk - there's no way we can put say 100MB of it on one disk and 900MB on another.  If we used one large file system spanning multiple disks then of course this could easily happen - but not with unRAID because each disk has it's own file system.

 

So, when we talk about "splitting", it means splitting a directory.

 

Now say we want to create a file.  That file will always be in some parent directory.  So we find out which disk the directory is on and create the file in that directory on that disk.  But what if the disk is too full?  So we pick another disk.  If the parent directory does not exist on the disk we picked, then we must create it on that disk first, then create the file.  Note that we have just split the directory.  We also have a situation where the same directory exists on more than one disk.  The "share" file system which is part of unRAID OS sorts this out and presents all the files which exist under that same directory on all the disks as if they were all on just one disk.

 

Now back to the case where we don't want to have a directory split.  Say the file we are trying to create is the 2nd VOB file of a movie.  We need to guarantee that this file will get created on the disk where the parent directory exists, regardless of how full that disk is becoming.

 

Well the way we accomplish this is by looking at how deep in the heirarchy is the parent directory.  Say the name of the parent directory is "Maui2007", and the grandparent is "Videos" - further, the "Videos" directory is also the top-level directory, which means it's the share name.

 

We're going to say that the top level (share name) directory is level "1" (the "Videos" directory is then level 1).  The "Maui2007" directory would be level 2.  Any object (file or directory) under the "Maui2007" directory would be level 3.

 

We will set the "split level" to 1, which says the system has permission to split any directory at level 1 (or lower) across multiple drives if it needs to.  So if we create a new object (file or directory) under "Videos", then we can pick which disk to actually create it in.  So when we created the "Maui2007" directory, the system was free to pick which disk to create it on.  But if we create a new object under "Maui2007" (which is level 2, which is greater than split level), then the system can not pick any disk to  put the object on - it must use the same disk that it's parent directory is on.  Hence, all the files in "Maui2007" directory will be kept together on the same hard disk - make sense?

 

Note - when a share is created which is permitted to span multiple disks (ie, split level > 0), the actual directories do not get created until they are needed.  That is why when you create a share, it's corresponding top-level directory is only on one disk.  As you add files to the share, it will eventually spill over to another disk and at that time the parent directory(s) will be created.

 

If you set split level to 0, that means which ever disk the system picked to create the top-level directory on, all objects created in that directory will be on that same disk.

 

If you set the split level very high, say 99, then any time the system creates a new object (file or directory) it is free to pick which disk to create the object on.  If you always have all your drives spun up, or you don't mind waiting for a drive spin up, this setting would assure the most even distribution of files across all your disks.

Link to comment

OK one more question to this then: If we set it to split level 1 and yet the file we are trying to save (under the level 1, say in "Videos") does NOT fit the disk that your filesystem would normally try to keep it in, will it report an error (disk full) or contrary to my prefs WILL use another disk?

 

Either way (I prefer the second option) - it is an idea to make it configurable.

 

Ah... and you should probably find my mail at last...

 

 

Link to comment

if you set the include disks as well as split level, then it shouldn't roll over to another disk. It should only create the new folders on the disks in the "include disks", from the way I understand it.

 

Right you are.  I didn't add discussion of "Included disks" and "Excluded disks" because the post was long enough as is  :)

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.