Error 'Posix error - Permission denied' occurred while creating

The place to discuss linux version of MakeMKV
Post Reply
Message
Author
jbnouser
Posts: 16
Joined: Thu Mar 27, 2014 8:52 pm

Error 'Posix error - Permission denied' occurred while creating

#1 Post by jbnouser » Sun Jun 27, 2021 8:23 pm

When I mount an external USB Hard Drive and then set makemkv's output folder as a directory on that hard drive, I get an error when I try to save DVDs and BluRays:

Error 'Posix error - Permission denied' occurred while creating /media/username/MovieName

I never receive this error when I try to save files in my home directory. The problem only occurs on externally mounted disks. I tried adding full permissions to that directory (chmod 0777 .), but that does not help.

Has anyone run into this problem on Linux? How can I solve it?

bmillham
Posts: 155
Joined: Mon Mar 27, 2017 12:42 am

Re: Error 'Posix error - Permission denied' occurred while creating

#2 Post by bmillham » Wed Jun 30, 2021 2:18 am

Error 'Posix error - Permission denied' occurred while creating /media/username/MovieName
Unless label of the drive is MovieName, that's your problem. The path should be:

Code: Select all

/media/username/drivelabel

jbnouser
Posts: 16
Joined: Thu Mar 27, 2014 8:52 pm

Re: Error 'Posix error - Permission denied' occurred while creating

#3 Post by jbnouser » Wed Jun 30, 2021 3:49 am

Okay. You're right. The path name in my post was incorrect. I did not want to use my real user name. When I run makemkv, I use the correct path name. It's something like:

Code: Select all

 /media/username/drivelabel/videos/MovieName
The point is that I have full write permissions in that directory. I can create files from the linux command-line. However, if I try to use that directory as the output folder in makemkv, then I get permission errors. How can I fix this?

bmillham
Posts: 155
Joined: Mon Mar 27, 2017 12:42 am

Re: Error 'Posix error - Permission denied' occurred while creating

#4 Post by bmillham » Wed Jun 30, 2021 5:30 am

I did not want to use my real user name.
I'm not sure why you are really worried about that. But.. The problem wasn't with that part of the path, it was the missing drive part.

So what happens if you try this from the shell:

Code: Select all

touch /media/username/drivelabel/videos/MovieName/testfile
And what does:

Code: Select all

ls -ld /media/username/drivelabel
show?

EDIT:
It would help to know how the drive is formatted. EXT? NTFS? FAT? etc.

You could always just try this:

Code: Select all

sudo chown -R username:username /media/username/drivelabel
to force the ownership/group of everything on the drive to be you.

jbnouser
Posts: 16
Joined: Thu Mar 27, 2014 8:52 pm

Re: Error 'Posix error - Permission denied' occurred while creating

#5 Post by jbnouser » Thu Jul 01, 2021 6:06 pm

Hi, thanks for your help.

I was able to create the testfile with the touch command.

The results of the 'ls -ld' are:

Code: Select all

> ls -ld /media/USERNAME/drivelabel/NetFlix/MovieName
drwxr-xr-x 2 USERNAME USERNAME 4096 Jul  1 14:00 /media/USERNAME/drivelabel/NetFlix/MovieName
I also tried the 'chown' command you suggested, but it did not help.

The hard drive is formatted as an NTFS drive.

The problem also persists if I mount a different partition on the main disk. That filesystem would be an ext filesystem.

bmillham
Posts: 155
Joined: Mon Mar 27, 2017 12:42 am

Re: Error 'Posix error - Permission denied' occurred while creating

#6 Post by bmillham » Fri Jul 02, 2021 3:37 am

The only think that I can think of is that MakeMKV isn't running as your user. Did you install from source?

While MakeMKV is running, what user is MakeMKV running as?

Code: Select all

ps -ef | grep -i makemkv
Will show what user makemkv is running as (and makemkvcon).

jbnouser
Posts: 16
Joined: Thu Mar 27, 2014 8:52 pm

Re: Error 'Posix error - Permission denied' occurred while creating

#7 Post by jbnouser » Fri Jul 02, 2021 4:57 am

I am running it as my user. In fact, I simply start it from the command-line.

makemkv is installed as a snap. I must admit I don't know what that is. It's installed in something like: /snap/makemkv/351 I don't know how that works so, naturally, I'm suspicious of it.

bmillham
Posts: 155
Joined: Mon Mar 27, 2017 12:42 am

Re: Error 'Posix error - Permission denied' occurred while creating

#8 Post by bmillham » Fri Jul 02, 2021 5:18 pm

Did you try the ps command that I suggested to verify what user MakeMKV is running as?

Instead of a snap, why don't you just install it? It's not that difficult.

bmillham
Posts: 155
Joined: Mon Mar 27, 2017 12:42 am

Re: Error 'Posix error - Permission denied' occurred while creating

#9 Post by bmillham » Sun Jul 04, 2021 6:19 am

I did a little digging into how snaps work, and I'm now convinced that your problem is with the snap.
You have to give the snap access removable media. Have a look at this link for more info:

https://www.linuxandubuntu.com/home/sna ... ermissions

jbnouser
Posts: 16
Joined: Thu Mar 27, 2014 8:52 pm

Re: Error 'Posix error - Permission denied' occurred while creating

#10 Post by jbnouser » Thu Jul 08, 2021 7:15 pm

I'm not sure why I used a snap originally. I followed your advice and installed makemkv directly and it works now. It allows me to save files to the externally mounted hard drive. Thank you very much for your help!

Post Reply