RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 743440 - cannot start dhcpd server
Summary: cannot start dhcpd server
Keywords:
Status: CLOSED DUPLICATE of bug 737571
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: selinux-policy
Version: 6.1
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Miroslav Grepl
QA Contact: Milos Malik
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-10-04 23:09 UTC by Jeff Bastian
Modified: 2012-10-16 11:44 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-10-25 07:51:44 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
dhcpd.conf example (561 bytes, text/plain)
2011-10-04 23:09 UTC, Jeff Bastian
no flags Details

Description Jeff Bastian 2011-10-04 23:09:29 UTC
Created attachment 526344 [details]
dhcpd.conf example

Description of problem:
After creating an /etc/dhcp/dhcpd.conf file, the service appeared to start, but it silently failed:

[root@termite ~]# service dhcpd start
Starting dhcpd:                                            [  OK  ]
[root@termite ~]# service dhcpd status
dhcpd dead but pid file exists

/var/log/messages contained:
Oct  4 18:00:18 termite setroubleshoot: SELinux is preventing /usr/sbin/dhcpd "setgid" access . For complete SELinux messages. run sealert -l a7a5bbce-91e6-4f74-bfc5-6684adb8ecef

The full sealert text is below.

I created a permissive domain for dhcpd_t and I was able to start the service.

[root@termite ~]# semanage permissive -a dhcpd_t
[root@termite ~]# service dhcpd start
Starting dhcpd:                                            [  OK  ]
[root@termite ~]# service dhcpd status
dhcpd (pid  7658) is running...


Version-Release number of selected component (if applicable):
dhcp-4.1.1-24.P1.el6.x86_64
selinux-policy-3.7.19-93.el6_1.7.noarch

How reproducible:
every time (?)

Steps to Reproduce:
1. create /etc/dhcp/dhcpd.conf (see attached example)
2. service dhcpd start
3. service dhcpd status
4. tail /var/log/messages
  
Actual results:
selinux blocked dhcpd from starting

Expected results:
dhcpd starts and runs

Additional info:
Summary:

SELinux is preventing /usr/sbin/dhcpd "setgid" access .

Detailed Description:

SELinux denied access requested by dhcpd. It is not expected that this access is
required by dhcpd and this access may signal an intrusion attempt. It is also
possible that the specific version or configuration of the application is
causing it to require additional access.

Allowing Access:

You can generate a local policy module to allow this access - see FAQ
(http://docs.fedoraproject.org/selinux-faq-fc5/#id2961385) Please file a bug
report.

Additional Information:

Source Context                unconfined_u:system_r:dhcpd_t:s0
Target Context                unconfined_u:system_r:dhcpd_t:s0
Target Objects                None [ capability ]
Source                        dhcpd
Source Path                   /usr/sbin/dhcpd
Port                          <Unknown>
Host                          termite.dfw.redhat.com
Source RPM Packages           dhcp-4.1.1-24.P1.el6
Target RPM Packages           
Policy RPM                    selinux-policy-3.7.19-93.el6_1.7
Selinux Enabled               True
Policy Type                   targeted
Enforcing Mode                Enforcing
Plugin Name                   catchall
Host Name                     termite.dfw.redhat.com
Platform                      Linux termite.dfw.redhat.com
                              2.6.32-131.6.1.el6.x86_64 #1 SMP Mon Jun 20
                              14:15:38 EDT 2011 x86_64 x86_64
Alert Count                   5
First Seen                    Tue Oct  4 17:36:04 2011
Last Seen                     Tue Oct  4 18:00:13 2011
Local ID                      a7a5bbce-91e6-4f74-bfc5-6684adb8ecef
Line Numbers                  

Raw Audit Messages            

node=termite.dfw.redhat.com type=AVC msg=audit(1317769213.353:220298): avc:  denied  { setgid } for  pid=7446 comm="dhcpd" capability=6  scontext=unconfined_u:system_r:dhcpd_t:s0 tcontext=unconfined_u:system_r:dhcpd_t:s0 tclass=capability

node=termite.dfw.redhat.com type=SYSCALL msg=audit(1317769213.353:220298): arch=c000003e syscall=116 success=no exit=-1 a0=0 a1=0 a2=5 a3=7f7b86c9c240 items=0 ppid=1 pid=7446 auid=12257 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=pts5 ses=28411 comm="dhcpd" exe="/usr/sbin/dhcpd" subj=unconfined_u:system_r:dhcpd_t:s0 key=(null)

Comment 1 Jeff Bastian 2011-10-04 23:27:25 UTC
Hmmm, I rebooted the system and now I cannot reproduce the problem.  It's very strange.  I'll close this for now and re-open it if I ever hit the problem again.

Comment 2 Miroslav Grepl 2011-10-05 05:31:48 UTC
This is fixed in the latest RHEL6.2 policies.

Comment 5 RHEL Program Management 2011-10-07 16:05:59 UTC
Since RHEL 6.2 External Beta has begun, and this bug remains
unresolved, it has been rejected as it is not proposed as
exception or blocker.

Red Hat invites you to ask your support representative to
propose this request, if appropriate and relevant, in the
next release of Red Hat Enterprise Linux.

Comment 6 Miroslav Grepl 2011-10-25 07:51:44 UTC

*** This bug has been marked as a duplicate of bug 737571 ***


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