Setting permissions on 207gb filesystem, how long?

paradoxiom

Patron
Joined
Jun 16, 2015
Messages
239
So I'm tidying up my data after upgrading to TrueNAS-12.0-U4 from FreeNAS 11 and having permissions issues.

I cleared all my SMB shares, deleted all mount points for jails, deleted all my jails, and moved the iocage to another spare drive for now.

I've been tidying up the permissions with:
root@truenas[~]# find /mnt/OrbitalHub/ -type f -exec setfacl -b {} \;
root@truenas[~]# find /mnt/OrbitalHub/ -type d -exec setfacl -b {} \;

On each pool/dataset.
All has been fine, but when running that on my Plex dataset (which holds 207gb of metadata / settings), the console seems to either hang, or is just working in the background and I have no idea if it's doing anything, is there any way I can get a progress bar or find out if it's actually doing anything?

5V3c0ZV.png


Running:
root@truenas[~]# find "/mnt/Orbital-System/Plex Media Server" -type f -exec setfacl -b {} \;

And like I say the console is just hanging on that command, is it taking a long time due to the amount of files on there? Any idea how long I should wait?

After this is done I'm planning to move the iocage back to Orbital-System, setup my SMB shares, create a new Jail for plex, install plex on the jail (Q: Should I use the plugin or manually in a jail?), add the mount point:
/mnt/Orbital-System/Plex Media Server -TO- /mnt/Orbital-System/iocage/jails/plexmediaserver-plexpass/root/Plex Media Server, and that should restore all my metadata and plex settings, as well as adding the mount points for all my data on other pools.

Just a general sanity check there, this should work right? But mostly concerned with how long it is (or isn't) taking to apply the setfacl command to that dataset.

Thanks in advance.
 
Joined
Jan 7, 2015
Messages
1,155
And like I say the console is just hanging on that command, is it taking a long time due to the amount of files on there? Any idea how long I should wait?

After this is done I'm planning to move the iocage back to Orbital-System, setup my SMB shares, create a new Jail for plex, install plex on the jail (Q: Should I use the plugin or manually in a jail?), add the mount point:
/mnt/Orbital-System/Plex Media Server -TO- /mnt/Orbital-System/iocage/jails/plexmediaserver-plexpass/root/Plex Media Server, and that should restore all my metadata and plex settings, as well as adding the mount points for all my data on other pools.
You should just install plex manually in a regular vnet jail.

There are lots of files on that Plex dataset, it could take awhile especially with a huge metadata collection. You should wait until the command completes and you return to your root prompt. Use the built in utility "screen" if you have any long running commands, its working, just tons of files.
 

paradoxiom

Patron
Joined
Jun 16, 2015
Messages
239
It's been running for a few hours now via ssh and still hasn't returned to the prompt, will doing -type d -exec setfacl -b {} \; after f take the same amount of time?

Can I install / setup the jail on the same drive without it slowing it down or should I wait?

Edit: The first one just finished, running the d one now.

Edit2: Should I use default (clone jail) or basejail option?

Edit3: Second command finished.
 
Last edited:
Joined
Jan 7, 2015
Messages
1,155
The command i use from the CLI to make a plex jail should be along the lines of this
iocage create -n "Plex" -r 12.2-RELEASE ip4_addr="vnet0|192.168.100.111/24" defaultrouter="192.168.100.1" boot="on" host_hostname="PLEX" vnet="on"

Adjust for your IP Scheme

I say do everything you can, I do. You can certainly be making a jail and updating the ports tree, installing plex, etc..
 

paradoxiom

Patron
Joined
Jun 16, 2015
Messages
239
Alright. All datasets / pools reset, new jail created and plex metadata mounted along with everything else - all runs perfectly fine - EXCEPT one pool that it doesn't seem to be able to find any media on, which is the main reason why I did this all in the first place.

It has the same permissions as every other drive/dataset I added and mounted, and all of those work fine, but not this one - I can see the files there via SMB.

Where do I go from here? Obviously plex doesn't seem to be able to see them, but I don't understand why, what kind of logs / commands can I run to show output and post here?

Thanks again / in advance anyone.
 

paradoxiom

Patron
Joined
Jun 16, 2015
Messages
239
Here's the setup:
Plex:
7EE4UQn.png


Samba:
Lr1z5ni.png


Samba:
12QIPtG.png


Jail Mount Point:
YlpPJtW.png


Is there any problems at first glance?
Every other storage / mount point works fine.
 
Joined
Jan 7, 2015
Messages
1,155
You should see who owns the datasets according to the TrueNAS host. Plex runs as the user/group plex, so this user/group needs access to all your media files. Alternatively, I prefer to run plex as a different user than plex. For instance whatever user can "browse' these files from Windows. There are many guides and tutorials on this, but in a nutshell..

Add user plex in the Truenas GUI, make him have the UID/GID of 972. Then allow this user full read/write to your media datasets.. This should fix it.
 

paradoxiom

Patron
Joined
Jun 16, 2015
Messages
239
Add user plex in the Truenas GUI, make him have the UID/GID of 972. Then allow this user full read/write to your media datasets.. This should fix it.

I'll try this. Should I set an aux group (wheel) for the user?

I need to create ACLs to be able to give the user plex access,right?
Should I use a preset when doing the ACLs?
cG8oYPn.png


Edit: Created an 'open' preset and changed the user to 'plex', seems to be able to access it now.
Thanks for all the help.
 
Last edited:
Joined
Jan 7, 2015
Messages
1,155
Yes create ACL permissions so user plex (972) has read write access on all media.. Allowing plex to be in the wheel group could compromise things, I would not do that.

You can use a preset or not up to you.

In future when something needs access to media join them to the AUX group plex (972). root, your user, etc..
 
Last edited:

paradoxiom

Patron
Joined
Jun 16, 2015
Messages
239
Created an 'open' preset and changed the user to 'plex', seems to be able to access it now.
Thanks for all the help.
 
Joined
Jan 7, 2015
Messages
1,155
Your welcome.. Follow these basic principles with all of your jails/softwares and you will be ok..
 
Top