View previous topic :: View next topic |
Author |
Message |
dany74q n00b
Joined: 17 Apr 2011 Posts: 8
|
Posted: Sun Aug 21, 2011 10:55 am Post subject: /usr wont mount correctly at startup (Permission denied) |
|
|
Hello everyone ,
I`ve just configured gentoo on my laptop , but I`m facing a problem with the mounting of the /usr partition at startup .
The system boots , but prompts "permission denied" when it tries to fire off software which is located in /usr/bin/ or /usr/sbin/ ...
Stuff as the logger and wpa_supplicant which I use for to manage the WPA2 key exchange wont fire up at startup .
If one were to manually remount the /usr partition - all works well (umount /dev/sda5 ; mount -t ext4 /dev/sda5 /usr) ,
so I`m guessing `tis a problem in the fstab file .
/etc/fstab :
/dev/sda1 /boot ext4 defaults,noauto,noatime 1 2
/dev/sda7 / ext4 noatime 0 1
/dev/sda6 /home ext4 noatime,user 0 0
/dev/sda5 /usr ext4 noatime,user 0 0
/dev/sda2 none swap sw 0 0
/dev/cdrom /mnt/cdrom auto defaults,noauto,user
proc /proc proc defaults 0 0
shm /dev/shm tmpfs nodev,nosuid,noexec 0 0
For example , if one would try to execute "clear" command which is located at /usr/bin/clear
he`d get : "-bash: /usr/bin/clear: Permission denied"
That is if the partitions was not remounted manually after startup .
How should I handle this ?
Thanks ,
Danny . |
|
Back to top |
|
|
g0del n00b
Joined: 27 Jul 2011 Posts: 36
|
Posted: Sun Aug 21, 2011 11:19 am Post subject: |
|
|
Permission denied usually happens when exec in not used in mounting the partition try
Code: | /dev/sda5 /usr ext4 noatime,user,exec 0 0 |
|
|
Back to top |
|
|
dany74q n00b
Joined: 17 Apr 2011 Posts: 8
|
Posted: Sun Aug 21, 2011 11:32 am Post subject: |
|
|
g0del wrote: | Permission denied usually happens when exec in not used in mounting the partition try
Code: | /dev/sda5 /usr ext4 noatime,user,exec 0 0 |
|
Thank you my friend , that seem to have solved the case . |
|
Back to top |
|
|
rh1 Guru
Joined: 10 Apr 2010 Posts: 501
|
Posted: Sun Aug 21, 2011 11:33 am Post subject: |
|
|
As g0del pointed out, you need to add exec. The user option is causing it to be mounted noexec
From man page
Quote: | user
Allow an ordinary user to mount the file system. The name of the mounting user is written to mtab so that he can unmount the file system again. This option implies the options noexec, nosuid, and nodev (unless overridden by subsequent options, as in the option line user,exec,dev,suid).
|
|
|
Back to top |
|
|
Hu Moderator
Joined: 06 Mar 2007 Posts: 21633
|
Posted: Sun Aug 21, 2011 5:23 pm Post subject: |
|
|
In general, you should only put the user mount option on filesystems that are noauto and describe removable media such as USB storage devices or optical media. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|