1

Can anyone please explain why I get this permission denied error? I try starting the script and it fails with a permission denied message. So I create a copy of it and run that instead and that works.

[root@node2 ~]# /etc/init.d/gfs2 stop
Unmounting GFS2 filesystem (/drbd):                        [  OK  ]
[root@node2 ~]# /etc/init.d/gfs2 start
Mounting GFS2 filesystem (/drbd): gfs_controld join connect error: Permission denied
error mounting lockproto lock_dlm
                                                       [FAILED]
[root@node2 ~]# cp /etc/init.d/gfs2 /etc/init.d/gfs2_test
[root@node2 ~]# /etc/init.d/gfs2_test start
Mounting GFS2 filesystem (/drbd):                          [  OK  ]
[root@node2 ~]#

[root@node2 ~]# ls -l /etc/init.d/gfs2*
-rwxr-xr-x. 1 root root 3365 Jan 15 12:11 /etc/init.d/gfs2
-rwxr-xr-x. 1 root root 3365 Jan 15 12:19 /etc/init.d/gfs2_test
[root@node2 ~]#
sashang
  • 167
  • 1
  • 9

1 Answers1

1

Suspecting SELinux problem here. Please tail the output of /var/log/audit/audit.log and post any 'denied' messages that pop up when starting gfs2 in your topic start.

wzzrd
  • 10,409
  • 2
  • 35
  • 47
  • Yeah you're right - it's an selinux thing. setenforce 0 and then running the script worked. – sashang Jan 14 '11 at 03:29
  • Which, of source, is not a solution. Please do not turn off SELinux if you care for a secure system. Try running restorecon on the init script that failed. – wzzrd Jan 16 '11 at 04:57