Recommended directory structure for media server

Status
Not open for further replies.

tundelas

Dabbler
Joined
Dec 24, 2012
Messages
12
Hi guys, sorry for this extremely noob question, but I'm very new to Linux and FreeNAS. I managed to get a RAIDZ1 setup to backup my external drives into. Currently all the data I transferred from external drives are under /mnt/storage/externaldrive1, /mnt/storage/externaldrive2, etc.
I have many random media files (movies, photos, music) inside the externaldrive1 and externaldrive2 directories, but I'd like to know if it's advisable/recommended that I organize all of my files from the /mnt directory to the /media directory. I'm new to the world of mounts and volumes, so if I cleaned out the directories from /mnt into /media/movies, /media/photos, /media/music, would it be as simple as file move commands or do I have to setup new mounts on /media?

Thanks.
 

HolyK

Ninja Turtle
Moderator
Joined
May 26, 2011
Messages
654
I am using stubs/datasets for the main organize. Good thing about this is that i can choose where i want compression a where not. So for the already compressed things like encoded movies, ISOs, mp3, ... etc i am using separated datasets where i have compression off, for the rest like RAW video/photo, FLAC audio, documents, ... i have datasets with enabled compression.

From the client point of view it looks like directory, you can set permissions, share, whatever you want :]
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
From the perspective of if you plan to share your media over the network, like to a BluRay player (TV) or stream music and/or photos, then organization is important. In my personal experience I have found it better to organize these shared items as follows and these are examples, you can change the names as you wish, just do not use spaces in the names, use an underscore...
/media/movies
/media/music
/media/photos

If you have a ton of movies you might organize them like so...
/media/movies/A_M
/media/movies/N_Z

Music is something you can easily exceed thousands of songs, although I have not yet run into a streaming service which would not handle a huge library, you could also break it apart like above.

I personally have several datasets, which you can add or remove to your pool anytime you want. I have the following: Backups, Movies, Photos, Music, Data, FTP. I don't stream photos or music so I have them separate where my family cannot get to them and I place a copy of that data on their computers for them to screw up. I also copy all photos and music to DVD-R periodically. In the Data set I place all my various software, drivers, downloads, etc... and no one can directly access it easily. The FTP is for when one of my sons need a file from me, they can download it and the FTP dataset is isolated from the other datasets in case they upload something to me. I'm sure there are many ways to organize your data but it will be whatever you personally like.

Since you just setup your system it's very probable you will change your mind on how you want to organize things, you might want to change your datasets, all of it or none of it. During this period of time do not store data on you machine that isn't backed up elsewhere. Critical data should always be backed up no matter what because trust me, something will happen, probably at your own hand and you will delete data without knowing it will have screwed you over. Backup your data. Once you feel you have settled on the format of your drives then you should continue to backup critical data. If it's not in more than one place, odds are you will loose it.

I hope this wasn't confusing, I got up to let the dog out, I hit the computer for a few seconds and saw this posting. Banged away at the keys for 20 minutes, now time to go back to bed.
 

tundelas

Dabbler
Joined
Dec 24, 2012
Messages
12
Wow thanks guys, great suggestions. My df -k results are as follows:

[root@freenas /]# df -k
Filesystem 1024-blocks Used Avail Capacity Mounted on
/dev/ufs/FreeNASs1a 948903 642274 230716 74% /
devfs 1 1 0 100% /dev
/dev/md0 4663 3306 984 77% /etc
/dev/md1 823 2 756 0% /mnt
/dev/md2 152791 10414 130154 7% /var
/dev/ufs/FreeNASs4 20263 559 18083 3% /data
storage 5567618834 5361133422 206485412 96% /mnt/storage

Since I'm new to Linux, I'm not sure what this means. If I start moving files from /mnt/storage into /media will I have enough room under /media? What commands to I need to run?

[root@freenas /]# df -k /media
Filesystem 1024-blocks Used Avail Capacity Mounted on
/dev/ufs/FreeNASs1a 948903 642274 230716 74% /
 

SmallGuy

Guru
Joined
Jun 7, 2013
Messages
560
Keep in mind that the size of the jail is very limited, so you can't store all your medias inside it, you have to create mount points:
Directory Source-->Directory Destination.
Physicaly your datas stay on freenas but are accessible on the jail.
This mean you have to organize your data as your convenience on freenas (create datasets, set quotas, create directories, set permissions...), create directories under /media on the jail and then create mount points.
http://doc.freenas.org/index.php/Adding_Jails#Adding_Storage

[EDIT]Think I have aswered the oldest topic of the forum: is there a trophy for that?:oops:
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
Status
Not open for further replies.
Top