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 1419929 - [Errno 2] No such file or directory: '//etc/selinux/targeted/contexts/files/file_contexts.local' while creating man pages
Summary: [Errno 2] No such file or directory: '//etc/selinux/targeted/contexts/files/f...
Keywords:
Status: CLOSED DUPLICATE of bug 1395778
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: selinux-policy
Version: 7.3
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: rc
: 7.4
Assignee: Lukas Vrabec
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-02-07 12:25 UTC by Supreet
Modified: 2020-09-10 10:11 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-02-08 14:42:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Supreet 2017-02-07 12:25:56 UTC
Description of problem:

1. After a minimal RHEL7 installation:
# man -k _selinux
# _selinux: nothing appropriate.

2. After installing the package "policycoreutils-devel" and running "mandb":
# man -k _selinux
# pam_selinux (8)      - PAM module to set the default security context

3. After installing the package "policycoreutils-devel", running "mandb" - executing "touch /etc/selinux/targeted/contexts/files/file_contexts.local (i found out that you don't need a symlink - creating an empty file is enough) 

4. Excuting "sepolicy manpage -a -p /usr/share/man/man8" and  running"mandb" again - you see that the sepolicy command is generating all the *_selnux.8 manpages and that the second mandb is adding 835 manpages.
# man -k _selinux
# _selinux (8)         - Security Enhanced Linux Policy for the processes
# abrt_dump_oops_selinux (8) - Security Enhanced Linux Policy for the abrt_dump_oops processes
# abrt_handle_event_selinux (8) - Security Enhanced Linux Policy for the abrt_handle_event processes
[...]
# zoneminder_script_selinux (8) - Security Enhanced Linux Policy for the zoneminder_script processes
# zoneminder_selinux (8) - Security Enhanced Linux Policy for the zoneminder processes
# zos_remote_selinux (8) - Security Enhanced Linux Policy for the zos_remote processes

why the file /etc/selinux/targeted/contexts/files/file_contexts.local is not provided by default ?

Version-Release number of selected component (if applicable):
Red Hat Enterprise Linux Server release 7.3 (Maipo)
selinux-policy-targeted-3.13.1-102.el7_3.13.noarch

How reproducible:
Follow the instruction's as mentioned in case description

Actual results:
It is not present

Expected results:
It should be present evenif the system is minimal install

Additional info:
From the newly minimal RHEL 7.3 system :

[root@localhost ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 7.3 (Maipo)

[root@localhost ~]# less /etc/selinux/targeted/contexts/files/file_contexts
file_contexts               file_contexts.homedirs      file_contexts.subs          
file_contexts.bin           file_contexts.homedirs.bin  file_contexts.subs_dist  

But if does full installation, the file is present by default :


[root@localhost ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 7.3 (Maipo)

[root@localhost ~]# less /etc/selinux/targeted/contexts/files/file_contexts
file_contexts               file_contexts.homedirs      file_contexts.subs          
file_contexts.bin           file_contexts.homedirs.bin  file_contexts.subs_dist  
file_contexts.local         file_contexts.local.bin

Comment 3 Lukas Vrabec 2017-02-08 14:42:49 UTC

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


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