LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   fstab extended partitions (http://www.linuxquestions.org/questions/slackware-14/fstab-extended-partitions-273451/)

Chrax 01-03-2005 06:58 PM

fstab extended partitions
 
I was cleaning up my computer this morning, and I decided to move my programming projects to another partition that I wouldn't wipe out in the event of a reinstall. This partition happens to be a logical drive on an extended partition.

I've found I cannot execute any scripts from that drive (you may recall my previous troubles with nvidia) without explicit declaration of the interpreter in the command line (eg. perl stats.pl).

Using the mount command
Code:

$mount
/dev/hda2 on / type reiserfs (rw)
proc on /proc type proc (rw)
/dev/hda4 on /home type reiserfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
/dev/hda5 on /media type reiserfs (rw,noexec,nosuid,nodev)
/dev/hda6 on /asdf type reiserfs (rw,noexec,nosuid,nodev)
/dev/hdc on /mnt/cdrom type iso9660 (ro,nosuid,nodev)
/asdf/iso/slack/slackware-10.0-install-d1.iso on /mnt/slack1 type iso9660 (ro,nosuid,nodev,loop=/dev/loop0)
/asdf/iso/slack/slackware-10.0-install-d2.iso on /mnt/slack2 type iso9660 (ro,nosuid,nodev,loop=/dev/loop1)
/asdf/iso/slack/slackware-10.0-source-d3.iso on /mnt/slack3 type iso9660 (ro,nosuid,nodev,loop=/dev/loop2)
/asdf/iso/slack/slackware-10.0-source-d4.iso on /mnt/slack4 type iso9660 (ro,nosuid,nodev,loop=/dev/loop3)

I find that /asdf has the noexec option engaged.

So I've been mucking about with fstab and have been failing to see why I should be able to execute off of my /home partition but not my /asdf.

Code:

/dev/hda1        swap                swap                defaults                0 0
/dev/hda2        /                reiserfs        defaults                1 1
/dev/hda4        /home                reiserfs        defaults                1 2
/dev/hda5        /media                reiserfs        defaults,users,rw        1 2
/dev/hda6        /asdf                reiserfs        defaults,users,rw        1 2
/dev/hdc        /mnt/cdrom        iso9660                auto,owner,ro                0 0
/usr/iso/slack1        /mnt/slack1        iso9660                loop,auto,owner,ro        0 0
/usr/iso/slack2        /mnt/slack2        iso9660                loop,auto,owner,ro        0 0
/usr/iso/slack3        /mnt/slack3        iso9660                loop,auto,owner,ro        0 0
/usr/iso/slack4        /mnt/slack4        iso9660                loop,auto,owner,ro        0 0
devpts                /dev/pts        devpts                gid=5,mode=620                0 0
proc                /proc                proc                defaults                0 0
/dev/sda1        /mnt/usb1        vfat                noauto,users,rw                0 0
/dev/sdb1        /mnt/usb2        vfat                noauto,users,rw                0 0
/dev/sdc1        /mnt/usb3        vfat                noauto,users,rw                0 0
/dev/sdd1        /mnt/usb4        vfat                noauto,users,rw                0 0

It occurred to me... perhaps logical drives must be mounted noexec? That would explain my predicament. Can anyone confirm this suspicion? Perhaps even suggest clever ways of getting around it (can't ln -s the programs to /usr/bin, I've tried).

Chris

michaelk 01-03-2005 07:12 PM

Have you read the man pages for mount? Look at the options for /home vs /media and /asdf

users
Allow every user to mount and unmount the file system. This option implies the options noexec, nosuid, and nodev (unless overridden by subsequent options, as in the option line users,exec,dev,suid).

http://www.die.net/doc/linux/man/man8/mount.8.html

Chrax 01-03-2005 07:19 PM

Ah. It seems I was not aware of all of the implications. Thanks.


All times are GMT -5. The time now is 08:24 AM.