Bare with me while I try to explain exactly what I want to accomplish here. My main goal is to setup remote access through SFTP for certain users and have them locked to their own home directories. Also I want to have my own account be able to delete, copy or add files to any directory on the volume from any PC on my LAN through both CIFS, SFTP and NFS.
I have a FreeNAS setup with 1 volume which houses all of my data. I have setup SSH as per the FreeNAS SSH WiKi here: http://doc.freenas.org/index.php/SSH to allow remote users to connect. This actually works and they are locked to their respective home directories.
There are 2 users and 3 groups that I have created in FreeNAS.
Users
me(my account)
User1(remote user)
Groups
Friends
me(my own group)
SFTP
My account has the primary group as my own group. I have added the wheel group to my account under auxiliary groups. I have also added my group to the "wheel" group under members.
User1's primary group is "friends" and he is also attached to the SFTP group to allow SSH (SFTP) to function.
Now down to the main issue I have is that after setting up the SFTP access for the remote users, I cannot write to the dataset that I created for user1. So if I want to added or remove files from user1's dataset I would need to login as root through SSH or SFTP. I do not want to have to do this, I want to be able to use my account to manage all the files on the volume.
In order for user1 to be able to chroot into their home directory I needed to setup the Main volume's dataset and user1's dataset as follows:
. All folders under "Data" (the main volume's dataset) have permissions setup as 755.
So basically as I stated above this comes down to not being able to write files to user1's dataset while accessing the share as my account which is associated with the wheel account and therefore should have rights to delete or add files to any dataset on the volume.
I have a FreeNAS setup with 1 volume which houses all of my data. I have setup SSH as per the FreeNAS SSH WiKi here: http://doc.freenas.org/index.php/SSH to allow remote users to connect. This actually works and they are locked to their respective home directories.
There are 2 users and 3 groups that I have created in FreeNAS.
Users
me(my account)
User1(remote user)
Groups
Friends
me(my own group)
SFTP
My account has the primary group as my own group. I have added the wheel group to my account under auxiliary groups. I have also added my group to the "wheel" group under members.
User1's primary group is "friends" and he is also attached to the SFTP group to allow SSH (SFTP) to function.
Now down to the main issue I have is that after setting up the SFTP access for the remote users, I cannot write to the dataset that I created for user1. So if I want to added or remove files from user1's dataset I would need to login as root through SSH or SFTP. I do not want to have to do this, I want to be able to use my account to manage all the files on the volume.
In order for user1 to be able to chroot into their home directory I needed to setup the Main volume's dataset and user1's dataset as follows:

So basically as I stated above this comes down to not being able to write files to user1's dataset while accessing the share as my account which is associated with the wheel account and therefore should have rights to delete or add files to any dataset on the volume.