Bug 178978 - rhgb fails to load due to selinux
rhgb fails to load due to selinux
Product: Fedora
Classification: Fedora
Component: selinux-policy (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Walsh
Depends On:
  Show dependency treegraph
Reported: 2006-01-25 16:48 EST by Brian C. Huffman
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version: current
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-03-15 23:37:21 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Brian C. Huffman 2006-01-25 16:48:50 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8) Gecko/20060103 Fedora/1.5-4 Firefox/1.5

Description of problem:
rhgb does not load and hasn't since I upgraded about 2 weeks ago.  I see this message at the top of /etc/rhgb/temp/xorg.log:

_XSERVTransmkdir: ERROR: Cannot create /tmp/.X11-unix
_XSERVTransSocketUNIXCreateListener: mkdir(/tmp/.X11-unix) failed, errno = 30
_XSERVTransMakeAllCOTSServerListeners: failed to create listener for local

and this shows up in /var/log/audit/audit.log:

[root@xyz temp]# grep rhgb /var/log/audit/audit.log
type=PATH msg=audit(1137862138.847:656): item=0 name="/etc/rhgb/temp" flags=0  inode=3810 dev=00:11 mode=040700 ouid=0 ogid=0 rdev=00:00
type=PATH msg=audit(1138031720.164:168): item=0 name="/etc/rhgb/temp" flags=0  inode=4053 dev=00:11 mode=040700 ouid=0 ogid=0 rdev=00:00

If I boot with selinux=0, rhgb works.

Version-Release number of selected component (if applicable):
rhgb-0.16.2-20, selinux-policy-targeted-2.2.4-1

How reproducible:

Steps to Reproduce:
1. Have selinux enabled
2. Boot
3. RHGB fails to load

Actual Results:  RHGB fails to load

Expected Results:  RHGB should work

Additional info:
Comment 1 Daniel Walsh 2006-01-26 10:28:27 EST
Have you tried relabeling your system

touch /.autorelabel

This looks like a labeling problem.
Comment 2 Brian C. Huffman 2006-01-26 10:33:21 EST
Doesn't it do a relabel after you re-enable selinux after doing an selinux=0? 
It said that it did and that didn't fix the problem.

However, I'll try this method and post back here once it's completed.
Comment 3 Brian C. Huffman 2006-01-26 11:01:18 EST
That did not fix the problem.  The error messages at the top of
/etc/rhgb/temp/xorg.log are slightly different (although I've seen them before):

_XSERVTransSocketCreateListener: failed to bind listener
_XSERVTransSocketUNIXCreateListener: ...SocketCreateListener() failed
_XSERVTransMakeAllCOTSServerListeners: failed to create listener for local
Comment 4 Brian C. Huffman 2006-01-27 10:26:17 EST
This is the directory listing (with -Z) on /etc/rhgb/temp.  I see that once I've
booted on my system *that works correctly*, there's nothing in this directory. 
Perhaps this will help?

[root@xyz ~]# ls -laZ /etc/rhgb/temp/
drwx------  root     root     system_u:object_r:ramfs_t        .
drwxr-xr-x  root     root     system_u:object_r:mnt_t          ..
-rw-r--r--  root     root     system_u:object_r:ramfs_t        display
srwx------  root     root     system_u:object_r:ramfs_t        rhgb-socket
-rw-r--r--  root     root     system_u:object_r:ramfs_t        xorg.log
Comment 5 Jason Vas Dias 2006-01-27 11:47:33 EST
There's another problem with SELinux and loading the synaptics touchpad driver:
bug 179058 - this also causes rhgb to fail in running X.
Comment 6 Daniel Walsh 2006-01-30 13:28:14 EST
Yes I am working on  a bug fix for Xorg issues when being run outside of gdm.

Basically you can execute

setsebool -P allow_execmem=1 allow_execheap=1 allow_execstack=1 

and It should work.  But this lowers you level of security.  We should be
labeling  Xorg in tonights policy and this should fix the problem

Fixed in selinux-policy-2.2.8-2
Comment 7 Brian C. Huffman 2006-01-30 13:51:06 EST
Actually, it started working for me after an update about 4 days ago.  I recall
something in the rawhide build log about "fixing rhgb."  I'm not sure exactly
what was done or what package it was (xorg-server?).  But I do have the
synaptics touchpad.
Comment 8 Daniel Walsh 2007-03-15 23:37:21 EDT
Closing several old modified bugs

Note You need to log in before you can comment on or make changes to this bug.