NFS share. "Can't open ... for modifying"

Status
Not open for further replies.

rendagar

Cadet
Joined
Aug 6, 2012
Messages
3
I have been trying to solve this for some time now but so far no luck. The situation is this.

I share the files on my FreeNAS box using NFS. Mounting the shares and everything seems to work as intended (I can edit, change and delete file and directories as I like) with the exception of one problem. I have my music library stored on the NAS and would like to normalize the volume of all the files. To do so on my main PC (an Arch Linux installation) I use

> find ./Music/ -iname *.mp3 -execdir mp3gain -c -p -r -k {} \;

which works just fine as long as I have the files on a local disk. However when I try to execute the same command on the mounted NFS share the program is able to analyse the file but for some reason can't apply the change (hangs). Running the command above as a superuser yields the following message.

"Can't open 01 Scissorlips.mp3 for modifying." Which I don't understand because it even happens with the following permission settings

> -rwxrwxrwx 1 rendagar torrent 5484254 Sep 16 18:07 01 Scissorlips.mp3

Also trying applying mp3gain directly on the file (so not using find) shows the exact same results. The relevant fstab entry for the mount is:

> 0.0.0.0:/mnt/mainPool/Music/ /mnt/nas/Music nfs user,rw,noauto,nolock,intr 0 0
(Not the actual IP)

I suspect the problem is due to some form of permissions I'm not aware of however I'm stumped. I hope anyone has any idea what is going on.
 

Nick2253

Wizard
Joined
Apr 21, 2014
Messages
1,633
It sounds like it's a problem with the mp3gain program, not an NFS permissions issue. Permissions on NFS are pretty simple.
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Actually, I tend to think it may be more with permissions than NFS itself. For example, if mp3gain creates a new file with the proper properties, then deletes the old file and renames the temp file to the correct name and you have no write permissions to the directory but do to the files themselves, that would be a problem.

Now it is also possible to be an NFS issue. For example, if mp3gain wants to lock a file and can't, then it may be throwing that error.


Unfortunately this is something you'll have to dig deep and troubleshoot for yourself. :/
 
Status
Not open for further replies.
Top