| 
  • If you are citizen of an European Union member nation, you may not use this service unless you are at least 16 years old.

  • Stop wasting time looking for files and revisions. Connect your Gmail, DriveDropbox, and Slack accounts and in less than 2 minutes, Dokkio will automatically organize all your file attachments. Learn more and claim your free account.

View
 

NFS Issues - Invalid arguments when copying files

Page history last edited by Tim 10 years, 4 months ago

I ran into an problem with copying files via NFS to the NAS.

 

  user@machine /mnt/ss4200> cp ~/somefile .

  cp: cannot create regular file `./somefile': Invalid argument

 

There would now be a zero byte file called "somefile".  However, if you ran the copy again now that the file exists, you could write to it.

 

I could not configure the users/groups/shares in the web gui in such a manner so that this would work.  Copying the same files under SMB was fine.

 

I finally figured this was due to ACLs being set on the filesystem which is (for whatever reason) affecting file copying under NFS.

First enable SSH on the SS4200 and log in as root.

To show your current ACLs:

 

  # getfacl /mnt/soho_storage/samba/shares/test

 

To clear these out:

 

  # setfacl -b /mnt/soho_storage/samba/shares/test

 

After doing this, I could now copy/create files without first creating the zero byte files.

 

This is not a complete fix however, as if you change the access lists in the web  gui it could be reset.  I also have not tried yet whether this persists after a  reboot.  It also opens the files to everyone.

 

It is likely possible to fix this permanently, or at least adjust the ACLs more correctly rather than just clearing them.  I have not looked into this yet.

Comments (0)

You don't have permission to comment on this page.