April 6, 2010

Why Permission denied running off CD

I have a program that I can run off a CD on many different distros but when I try it on an old Fedora6 machine it gives Permission denied, even though I'm in root and the program on the CD shows -r-xr-xr-x

It runs fine of the HD but not off the CD. I disabled SELinux. What else could it be?

 

This happened to me when I tried Slackware, the users and root were not in...

This happened to me when I tried Slackware, the users and root were not in the CDROM group in /etc/group. To fix this error I added the user and root the the CDROM group.
I know Fedora and Slackware are different distributions, and I am not sure if this is the problem also.

Like  (0 likes)

ok now try mounting the cdrom like this:...

ok now try mounting the cdrom like this:

mount -o remount,defaults,exec /media/A1TEST2

Check with mount that the options are ok and test. If this doesn't work mount the CD in a distribution that works and try with the options you see.

If this still doesn't work I'd say it smells like selinux so as a last resort put it in permissive mode or disable it and try again.

Thanks, that works! I tried setting SELinux to permissive and just disabling it. Don't know what else it could be other than demon-possesion. >:-]

Like  (0 likes)

Is the program trying to write in the CD? Maybe it creates some files and...

Is the program trying to write in the CD? Maybe it creates some files and need write permissions, that in the CD is not possible. Copy the program to HD and run it.

Yes, the program does attempt to write a log file, but only after it runs for several minutes. How would the system know the program is capable of writing up front?

Like  (0 likes)

ok now try mounting the cdrom like this:...

ok now try mounting the cdrom like this:

mount -o remount,defaults,exec /media/A1TEST2

Check with mount that the options are ok and test. If this doesn't work mount the CD in a distribution that works and try with the options you see.

If this still doesn't work I'd say it smells like selinux so as a last resort put it in permissive mode or disable it and try again.

Like  (0 likes)

Is the program trying to write in the CD? Maybe it creates some files and...

Is the program trying to write in the CD? Maybe it creates some files and need write permissions, that in the CD is not possible. Copy the program to HD and run it.

Like  (0 likes)

mount shows:...

mount shows:

automount(pid1691) on /net type autofs (rw,fd=4,pgrp=1691,minproto=2,maxproto=4)
/dev/hdc on /media/A1TEST2 type iso9660 (ro,noexec,nosuid,nodev,uid=500)

so I fed it:

mount -o remount,ro,nosuid,nosuid,nodev,uid=500 /media/A1TEST2

and it still gives Permission denied. Am I missing something?

type mount in a shell and look at the options there are for the cdrom. There should be a 'noexec' one ( it means no executable so impossible to launch a program from it ).

If there is, copy all the options minus noexec and type as root or sudo in a shell ( change the path and the options with wath you have ):

mount -o remount,option1,option2,optionN /path/to/cd

Like  (0 likes)

type mount in a shell and look at the options there are for the cdrom. There...

type mount in a shell and look at the options there are for the cdrom. There should be a 'noexec' one ( it means no executable so impossible to launch a program from it ).

If there is, copy all the options minus noexec and type as root or sudo in a shell ( change the path and the options with wath you have ):

mount -o remount,option1,option2,optionN /path/to/cd

Like  (0 likes)

Is the cdrom automonted? Try to umount and mount manually, maybe it's a...

Is the cdrom automonted? Try to umount and mount manually, maybe it's a problem with automount or fstab options.

Like  (0 likes)

Maybe take a look and see if there is a cdrom group in those older distros...

Maybe take a look and see if there is a cdrom group in those older distros and see how it's owned.
Maybe it's reading the cdrom permissions incorrectly, and/or trying a write to the cdrom.
Maybe the different versions of hal are not doing the hardware recognition correctly.
I'm just thinking out loud here, but the first thing I would look at would be to check how the cdrom is viewed by each of the different versions of fedora, and see if the properties and permissions are the same in each version.
I may be totally off base, but that's my $.02 cents.

Like  (0 likes)

Of course both sudo and su give the same Permission denied. I just discovered...

Of course both sudo and su give the same Permission denied. I just discovered the same problem with Fedora5 too, but not Fedora4 and Fedora7. What going on???

Like  (0 likes)

Pages

Click Here!