Closed afettouhi closed 7 years ago
When you tested FreeNAS what type of share did you set up?
No share at all. I just added one drive to pool of storage devices and made it writeable to the user.
Could you maybe try to make a smb share and see if it still works for you?
I think I am getting somewhere with this. I created a new dataset outside the smb share I have and I put my home direcotry of the freenasuser there. I now has unix permissions. Then I setup a new ssh key and copied it over to the freenas. Now if I try to set it up in the BiT UI I get this error
freenas not found in ssh_known_hosts.
Sorry, I'm quite busy at the moment so I was not able to test it with SMB share yet.
To add 'freenas' to your ssh_known_hosts file you simply need to login to freenas from Terminal with the user you are using for BiT.
I have made a new attempt getting this to work. I moved the home directory outside my smb share and made a new dataset for it under the pool I originally created. Then I have resetup the ssh key and copied it over to the freenas server. Now if I try to setup the profile in BiT UI I get
Remote host freenas doesn't support 'chmod u+rw FILE': chmod: /mnt/freenaspool/Media/tmp_QJNMZD/a: Operation not permitted
Note that I am still trying to place my backup in the smb share I have created, e.g.
/mnt/freenaspool/Media/
and I think that this causing the headache. I have also tried to place the backup in the new created dataset here I get
write permission denied.
I tried it with a new SMB share but it still works over here.
In FreeNAS web-admin please select:
Storage > Volumes > /mnt/freenaspool/Media > Change Permissions
Change Owner (user)
to freenasuser
and Owner (group)
to freenasgroup
(or what ever username and main group you now want to use). In Mode
activate all boxes for Read
and Execute
and the first and second box for Write
. Also activate Set permission recursively
and press Change
. This should fix all permission problems...
So you have chosen Unix as permission type then? Because if it is set to Windows the Mode boxes are greyed out.
Yes! Permission Type need to be Unix! And make sure all Apply ...
options are activated
Still fails with this error
Remote host freenas doesn't support 'chmod u+rw FILE': chmod: /mnt/freenaspool/Media/tmp_W293CO/a: Operation not permitted
What happens if you log in and change permissions manually:
ssh freenasuser@freenas
mkdir /mnt/freenaspool/Media/test
echo "foo" > /mnt/freenaspool/Media/test/a
chmod u+rw /mnt/freenaspool/Media/test/a
Alternative you can install current development version from ppa:bit-team/testing
which won't need chmod anymore.
This happens:
[af@andre ~]$ ssh freenasuser@freenas
Enter passphrase for key '/home/af/.ssh/id_rsa':
Last login: Tue Dec 13 20:33:29 2016 from 192.168.0.10
FreeBSD 10.3-STABLE (FreeNAS.amd64) #0 r295946+07c41cd(9.10-STABLE): Wed Nov 9 00:19:25 UTC 2016
FreeNAS (c) 2009-2016, The FreeNAS Development Team
All rights reserved.
FreeNAS is released under the modified BSD license.
For more information, documentation, help or support, go here:
http://freenas.org
Welcome to FreeNAS
[freenasuser@freenas ~]$ mkdir /mnt/freenaspool/Media/test
[freenasuser@freenas ~]$ echo "foo" > /mnt/freenaspool/Media/test/a
[freenasuser@freenas ~]$ chmod u+rw /mnt/freenaspool/Media/test/a
chmod: /mnt/freenaspool/Media/test/a: Operation not permitted
Hmm, I don't get it. It does work over here. Do you have any special ACLs which do not permit this? What's the output of
getfacl /mnt/freenaspool/Media/test/a
[freenasuser@freenas ~]$ getfacl /mnt/freenaspool/Media/test/a
# file: /mnt/freenaspool/Media/test/a
# owner: freenasuser
# group: freenasgroup
owner@:rwxpDdaARWcCos:------I:allow
group@:rwxpDdaARWcCos:------I:allow
everyone@:r-x---a-R-c---:------I:allow
I finally got it working. Seems like the permissions in my shares where messed up. So I tried to create afresh dataset via the FreeNAS GUI and make it my backup location. Then finally the BiT GUI accepted the path.
Well, I finally got my new FreeNAS 9.10 server up an running and I am in the process of setting up a new profile in the backintime GUI with SSH this time. I have set up access ssh on my freenas and turned it on. Then I followed what the man backintime page said, e.g. installed sshfs and added my user to the fuse group. Then I did
ssh-keygen -t rsa
and finally
ssh-copy-id -i ~/.ssh/id_rsa.pub freenasuser@freenas
then I went into the settings dialog entered everything as described but when I try to save the new profile it complains about not finding the freenasuser@freenas. What am I doing wrong?