FTP create directory: Operation not permitted

Status
Not open for further replies.

Myopia

Dabbler
Joined
Jan 13, 2016
Messages
16
Hi all,

I hoped to enjoy my new nas more with Freenas, but unfortunately there are some bears to shoot.

My configuration:
1 volume: redz
1.1 dataset: redz\media
1.2 dataset: redz\reddataset

Group 1004 admin
User 1002 media homedir: redz\media
User 1003 reddataset homedir: redz\reddataset

Users have all checkboxes checked read write execute
User have Auxiliary groups: admin;ftp

FTP
path: mnt\redz
allow local user login checked
File permission all is checked for read write
Directory permission all is checked for read write execute

I can upload files and create new files. But when I create a directory I get the following error:
Response: 550 DIRNAME: Operation not permitted
Jan 19 17:52:30 freenas proftpd[65302]: 127.0.0.1 (192.168.1.121[192.168.1.121]) - chmod(/s/.dstOUvNtkFO) failed: Operation not permitted


Why can't I create directories?
 

Attachments

  • volumes.PNG
    volumes.PNG
    6 KB · Views: 352
  • group-admin.PNG
    group-admin.PNG
    10.7 KB · Views: 342
  • users.PNG
    users.PNG
    8.5 KB · Views: 367
  • ds-redz.PNG
    ds-redz.PNG
    11.5 KB · Views: 407
  • ds-media.PNG
    ds-media.PNG
    11.4 KB · Views: 359
  • ftp.PNG
    ftp.PNG
    15.2 KB · Views: 400

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
You have the permissions type set to "windows". This prevents you from being able to chmod files. FYI, you shouldn't share the same dataset via FTP and CIFS simultaneously. The FTP server doesn't understand windows oplocks, which are used to agressively cache things client-side, and it can lead to file corruption.
 

Myopia

Dabbler
Joined
Jan 13, 2016
Messages
16
I want to have one dataset MEDIA which I can access via FTP and CIFS. But after reading your comment, this is not possible? Is there a solution to deal with this approach? Different filesystem?
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
I want to have one dataset MEDIA which I can access via FTP and CIFS. But after reading your comment, this is not possible? Is there a solution to deal with this approach? Different filesystem?
It's better to just select a single method of sharing files and stick with it. Use a VPN to provide remote access (if needed).
 

Maranatha

Cadet
Joined
Aug 29, 2016
Messages
1
I found a quick and dirty fix for this... I too wanted to share a volumn with both FTP and CIFS.
I wanted CIFS readonly and FTP as my upload.

My issue was that I created with Windows permissions to begin with and no matter what I did with freenas GUI, I couldn't change that to Unix.
I checked with the shell and everything still had "+" at the very end.
So I ended up forcefully dropping all Windows ACL with this from that root directory of my volumn:

Code:
find . -exec setfacl -b {} \;


If anyone is out to try quick and dirty fix... welcome to try this. But I will not take any responsibility for any loss of data (not that changing permission would do that).
Feel free to suggest me better solution if anyone has one. Thanks!
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
I found a quick and dirty fix for this... I too wanted to share a volumn with both FTP and CIFS.
I wanted CIFS readonly and FTP as my upload.

My issue was that I created with Windows permissions to begin with and no matter what I did with freenas GUI, I couldn't change that to Unix.
I checked with the shell and everything still had "+" at the very end.
So I ended up forcefully dropping all Windows ACL with this from that root directory of my volumn:

Code:
find . -exec setfacl -b {} \;


If anyone is out to try quick and dirty fix... welcome to try this. But I will not take any responsibility for any loss of data (not that changing permission would do that).
Feel free to suggest me better solution if anyone has one. Thanks!

It's probably a better idea to specify the path to the directory you wish to run this command on. Also, you will need to be careful what actions you perform from the FreeNAS webgui as some actions will set a non-trivial ACL on the samba share.
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
Do you have jails? Do they still work after running this?

Sent from my Nexus 5X using Tapatalk
 
Status
Not open for further replies.
Top