LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   File execution denied (https://www.linuxquestions.org/questions/linux-kernel-70/file-execution-denied-538685/)

timyang 03-19-2007 06:33 AM

File execution denied
 
I have a SUSE Linux on my notebook as a partition. It can be run directly with its native kernel with version 2.6.13-8-default, or run within MS-Windows with a CoLinux kernel version 2.6.11-co-0.6.4.

I found a strange behavior on this system that I have not observed my other Linux boxes.
It refuses to excute a file if it is not in certain directories. I have compiled a hello.c and no matter how I set the file permission, it refuses to execute the a.out, or any name it turns into. The failure reported by bash is "Permission Denied". If I copied this file into /usr/bin, then it excutes correctly. I copied some file from /usr/bin into my home directory, for example bzip2 and type ./bzip2. The same error happens. I logged in as root, and the same happens.

Since two different kernels behaves the same, I think this is not a problem of kernel configuration.
Is this certain security check enabled somewhere, or is there something wrong with this system?

Valkyrie_of_valhalla 03-19-2007 06:39 AM

are you sure you aren't mounting the partition with certain parameters that don't let you modify permissions?
my first shot would be to check fstab

nx5000 03-19-2007 06:41 AM

File systems can be mounted with option:
NO execute

The result is that no executable can be run from there.

Check:

mount

If you see noexec, you know where the problem is.

You can manually change the options in runtime (means its transparent and harmless for apps):
mount -o remount,exec /home

timyang 03-19-2007 06:49 AM

Ok. I checked the mount, and the /home partition is noexec.

Thanks for the quick answer.


All times are GMT -5. The time now is 12:39 PM.