Can't execute an executable, even as sudo.
I've just compiled a C program and get a permission denied error when trying to run thing.
Let's call my username 'dave'.
I've got a directory for common use for all users (and distros) on a separate partition called /data
My code is in /data/work/mycode, so if I do an 'ls -l' I get something like:
-rw-rw-r-- 1 dave users 50 2008-06-25 10:46 myprog.c
-rwxrwxr-x 1 dave users 9501 2008-06-25 10:47 myprog
So the 'x' flags are set on my executable, but I get a permission denied when typing './myprog'. I try 'sudo ./myprog' and get the same response.
I've copied the file up to /data and get the same problem.
If I do a 'ls -l' I get (for the /data part only):
drwxrwxrwx 5 root root 4096 2008-06-21 20:11 data
So it should be executable for everyone, surely? I've clearly got write permissions to the directory (and subdirectories) and I'm generating and copying files to it.
I'm currently doing this from my Suse 10.2 distro (64-bit), and I'm sure I'm not having this problem when I use my Ubuntu distro.
I feel I'm missing something really obvious!?
Does the file system have the execute permission disabled ?
Ah yes! The /etc/fstab file needed adjusting. It works fine now. I knew it had to be something simple for me to overlook it! Thanks for the help.
|All times are GMT -5. The time now is 03:31 AM.|