LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 12-16-2004, 11:58 AM   #1
Dasc
Member
 
Registered: Jul 2004
Posts: 47

Rep: Reputation: 15
I can't execute scripts in mounted fs


Hello

I'm having a problem with executing scripts if they are in my mounted fat partition
I get a permission denied error
bash: ./test.sh: Permission denied

while the file permissions should allow execution:
-rwxrwxrwx 1 root root 18 2004-12-16 00:53 test.sh

that partition line in /etc/fstab is this:
/dev/hdb1 /mnt/hdb1 rw,user,auto,umask=000 0 0

I can correctly read/write files, the problem reguards only execution.

is it supposed to work like this or am I doing something wrong?
 
Old 12-16-2004, 02:57 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,005
Blog Entries: 11

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
First of all I can't see a file-system in that fstab
entry ...


Cheers,
Tink
 
Old 12-16-2004, 05:12 PM   #3
kevinalm
Member
 
Registered: Oct 2003
Location: Iowa
Distribution: LFS 5.0, building 6.3, win98se, multiboot
Posts: 288

Rep: Reputation: 30
That problem is a sneaky one. What you need to remember is that mount options override filesystem perms. The mount options must include exec in order to execute a file on a mounted fs.

And yes there really should be an fstype entry, but mount is pretty good at guessing fstypes.
 
Old 12-16-2004, 07:36 PM   #4
Dasc
Member
 
Registered: Jul 2004
Posts: 47

Original Poster
Rep: Reputation: 15
sorry, my fault. there IS a fstype entry (vfat), it's just that for some reason I didn't copy-pasted the line but I copied it manually and forgot that -_-'

anyway the exec parameter made it work, thanks!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't execute NFS mounted script hexbox Linux - Networking 2 02-03-2005 06:59 PM
Unable to execute sh scripts zowey Mandriva 2 12-23-2004 04:59 PM
execute bash scripts vapor Programming 9 07-14-2003 03:54 PM
cant execute any scripts Phonics3k Linux - Newbie 2 06-19-2002 09:00 AM
How to execute Linux scripts LenkaNguyen Linux - General 2 12-07-2001 04:12 PM


All times are GMT -5. The time now is 06:25 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration