Bug 593649 - wrong labels on /var/cache/yum/anaconda-
wrong labels on /var/cache/yum/anaconda-
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: anaconda (Show other bugs)
6.0
All Linux
high Severity medium
: rc
: ---
Assigned To: Chris Lumens
Release Test Team
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-05-19 07:58 EDT by Peter Vrabec
Modified: 2010-07-02 16:49 EDT (History)
4 users (show)

See Also:
Fixed In Version: anaconda-13.21.46-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-07-02 16:49:45 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Peter Vrabec 2010-05-19 07:58:40 EDT
Description of problem:
I see these wrong SELinux labels on files on clean RHEL6 installation:

    Warning: Mislabeled directory '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.
    Warning: Mislabeled regular file '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386/3ac865dd799fd5fd1beb2621b56b05314e092d910b969a9529832b1baab0dd2c-comps-rhel6-Server.xml.gz' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.
    Warning: Mislabeled regular file '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386/887dc56b401a1527102ab3d2fb09c7c305283d1388106aea434b6af69e4207fe-comps-rhel6-Server.xml' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.
    Warning: Mislabeled regular file '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386/f39fe2cc357d4c87b6a5630ea29315bb5502c045d8891b844947afb13dba9c77-primary.sqlite' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.
    Warning: Mislabeled regular file '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386/repomd.xml' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.
    Warning: Mislabeled regular file '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386/cachecookie' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.
    Warning: Mislabeled regular file '/var/cache/yum/anaconda-RedHatEnterpriseLinux-201005121618.i386/e647f7293ceb25a4adf28885e87fec20ee12f758f902575f06ec5d09816797fa-filelists.sqlite' found. Labeled as 'system_u:object_r:root_t:s0', should be 'system_u:object_r:rpm_var_cache_t:s0'.

When I asked Dan W. what was the problem I get reply:
"Please open a bug in Anaconda on this.  They do not set the autorelabel
flag nor should they.  We need to add this directory to the list of
directories anaconda runs restorecon on when it completes."
Comment 2 Daniel Walsh 2010-05-19 08:41:32 EDT
This file must be being created early in the install process.  Including /var/cache/yum.  Not sure why they get the correct label, or this file is created in / and then mv'd to this directory.

Anaconda should run restorecon on this file after it is mv'd/created in this directory.
Comment 3 Chris Lumens 2010-05-20 11:38:13 EDT
The real question here is why /var/cache/yum even exists post-install.  We should be cleaning that up before rebooting.
Comment 4 RHEL Product and Program Management 2010-05-24 15:26:25 EDT
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.
Comment 6 Alexander Todorov 2010-05-31 07:18:11 EDT
With snap #6 (0527.2)/anaconda 13.21.48 after install /var/cache/yum is empty.
/var/cache/yum has the context system_u:object_r:rpm_var_cache_t:s0

Moving to VERIFIED.
Comment 7 releng-rhel@redhat.com 2010-07-02 16:49:45 EDT
Red Hat Enterprise Linux Beta 2 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

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