| Summary: | [Upgrade] permission denied deleting repo's | |||
|---|---|---|---|---|
| Product: | Red Hat Update Infrastructure for Cloud Providers | Reporter: | wes hayutin <whayutin> | |
| Component: | RHUA | Assignee: | James Slagle <jslagle> | |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | wes hayutin <whayutin> | |
| Severity: | medium | Docs Contact: | ||
| Priority: | unspecified | |||
| Version: | 2.0.2 | CC: | jslagle, kbidarka, sghai, tsanders | |
| Target Milestone: | --- | |||
| Target Release: | --- | |||
| Hardware: | Unspecified | |||
| OS: | Unspecified | |||
| Whiteboard: | ||||
| Fixed In Version: | Doc Type: | Bug Fix | ||
| Doc Text: | Story Points: | --- | ||
| Clone Of: | ||||
| : | 801928 (view as bug list) | Environment: | ||
| Last Closed: | 2012-03-12 19:38:44 UTC | Type: | --- | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Bug Depends On: | ||||
| Bug Blocks: | 801928 | |||
|
Description
wes hayutin
2012-03-07 20:45:09 UTC
committed to pulp rhui: 3da4e8715b5d4448bfc5a5080baef10e3d48a201 built into pulp-0.263-17 Newer ISO build: http://download.lab.bos.redhat.com/devel/candidates/RHEL-6.2-RHUI-2.0.2-20120307. +2/2.0.2/Server/x86_64/iso/RHEL-6.2-RHUI-2.0.2-20120307.2-Server-x86_64-DVD1.iso yum repo on cdn.rcm-qa also updated. 2012-03-08 15:02:19,501 25938:139849854068480: pulp.server.tasking.task:ERROR: task:474 Task failed: Task 99c300b3-6901-11e1-9e0c-525400856f10: RepoApi.delete(rhel-x86_64-6-rhui-2-rpms-6Server-x86_64, )
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/pulp/server/tasking/task.py", line 420, in run
result = self.callable(*self.args, **self.kwargs)
File "/usr/lib/python2.6/site-packages/pulp/server/api/repo.py", line 652, in delete
repo_cert_utils.delete_for_repo(id)
File "/usr/lib/python2.6/site-packages/pulp/repo_auth/repo_cert_utils.py", line 112, in delete_for_repo
shutil.rmtree(repo_dir)
File "/usr/lib64/python2.6/shutil.py", line 217, in rmtree
onerror(os.remove, fullname, sys.exc_info())
File "/usr/lib64/python2.6/shutil.py", line 215, in rmtree
os.remove(fullname)
OSError: [Errno 13] Permission denied: '/etc/pki/pulp/content/rhel-x86_64-6-rhui-2-rpms-6Server-x86_64/consumer-rhel-x86_64-6-rhui-2-rpms-6Server-x86_64.cert'
[root@scalpel pulp]# rpm -qav | grep -i pulp
pulp-0.0.263-17.el6.noarch
python-isodate-0.4.4-4.pulp.el6.noarch
m2crypto-0.21.1.pulp-7.el6.x86_64
pulp-client-lib-0.0.263-17.el6.noarch
python-oauth2-1.5.170-2.pulp.el6.noarch
pulp-selinux-server-0.0.263-17.el6.noarch
mod_wsgi-3.3-2.pulp.el6.x86_64
pulp-consumer-0.0.263-17.el6.noarch
pulp-common-0.0.263-17.el6.noarch
pulp-admin-0.0.263-17.el6.noarch
-= Repository Management =-
l list repositories currently managed by the RHUI
i display detailed information on a repository
a add a new Red Hat content repository
c create a new custom repository
d delete a repository from the RHUI
u upload content to a custom repository
p list packages in a repository
Connected: scalpel.lab.eng.pnq.redhat.com
------------------------------------------------------------------------------
rhui (repo) => d
Select one or more repositories:
Custom Repositories
- 1 : apache
- 2 : httpd_custom
- 3 : zsh_custom
Red Hat Repositories
- 4 : Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
- 5 : Red Hat Update Infrastructure 2.0 (Source RPMs) (6Server-x86_64)
Enter value (1-5) to toggle selection, 'c' to confirm selections, or '?' for more commands: 4
Select one or more repositories:
Custom Repositories
- 1 : apache
- 2 : httpd_custom
- 3 : zsh_custom
Red Hat Repositories
x 4 : Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
- 5 : Red Hat Update Infrastructure 2.0 (Source RPMs) (6Server-x86_64)
Enter value (1-5) to toggle selection, 'c' to confirm selections, or '?' for more commands: c
The following repositories will be deleted:
Red Hat Repositories
Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
Proceed? (y/n) y
Deleting Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)...
------------------------------------------------------------------------------
rhui (repo) => exit
[root@dhcp201-152 log]# rhui-manager
------------------------------------------------------------------------------
-= Red Hat Update Infrastructure Management Tool =-
-= Home =-
r manage repositories
c manage content delivery servers (CDS)
s synchronization status and scheduling
e create entitlement certificates and client configuration RPMs
n manage Red Hat entitlement certificates
u manage users
i manage identity certificate
logout
removes stored authentication credentials and exits
< move to the previous screen
^, home
move to the home screen
/, clear
clears the screen
?, help
display help
q, quit, exit
exit
Connected: scalpel.lab.eng.pnq.redhat.com
------------------------------------------------------------------------------
rhui (home) => r
------------------------------------------------------------------------------
-= Red Hat Update Infrastructure Management Tool =-
-= Repository Management =-
l list repositories currently managed by the RHUI
i display detailed information on a repository
a add a new Red Hat content repository
c create a new custom repository
d delete a repository from the RHUI
u upload content to a custom repository
p list packages in a repository
Connected: scalpel.lab.eng.pnq.redhat.com
------------------------------------------------------------------------------
rhui (repo) => l
Custom Repositories
zsh_custom
httpd_custom
apache
Red Hat Repositories
Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
Red Hat Update Infrastructure 2.0 (Source RPMs) (6Server-x86_64)
------------------------------------------------------------------------------
rhui (repo) => exit
[root@dhcp201-152 log]# rpm -qav | grep -i pulp
pulp-client-lib-0.0.263-17.el6.noarch
pulp-common-0.0.263-17.el6.noarch
pulp-consumer-0.0.263-17.el6.noarch
pulp-admin-0.0.263-17.el6.noarch
m2crypto-0.21.1.pulp-7.el6.x86_64
python-isodate-0.4.4-4.pulp.el6.noarch
[root@xxxxxxx pulp]# ll /etc/pki/pulp/content/rhel-x86_64-6-rhui-2-rpms-6Server-x86_64/consumer-rhel-x86_64-6-rhui-2-rpms-6Server-x86_64.cert -rw-r--r--. 1 apache apache 2923 Mar 8 08:51 /etc/pki/pulp/content/rhel-x86_64-6-rhui-2-rpms-6Server-x86_64/consumer-rhel-x86_64-6-rhui-2-rpms-6Server-x86_64.cert Even though the file permissions were fixed on the certs themseleves, the directory still had wrong permissions. After I fixed that, I noticed that the SELinux contexts also weren't applied correctly b/c we were moving the files instead of copying them. I switched from using shutil.move to shutil.copy in the code. committed to pulp rhui: ea39604539dea26ccff11267de4aade55db3b144 built into pulp-0.263-18 Even newer ISO build: http://download.lab.bos.redhat.com/devel/candidates/RHEL-6.2-RHUI-2.0.2-20120309. +0/2.0.2/Server/x86_64/iso/RHEL-6.2-RHUI-2.0.2-20120309.0-Server-x86_64-DVD1.iso yum repo on cdn.rcm-qa also updated. nning Transaction
Warning: RPMDB altered outside of yum.
Updating : m2crypto-0.21.1.pulp-7.el6.x86_64 1/42
Updating : python-isodate-0.4.4-4.pulp.el6.noarch 2/42
Updating : pulp-common-0.0.263-18.el6.noarch 3/42
Installing : libcgroup-0.37-3.el6.x86_64 4/42
Updating : grinder-0.0.136-1.el6.noarch 5/42
Updating : python-oauth2-1.5.170-2.pulp.el6.noarch 6/42
Installing : audit-libs-python-2.1.3-3.el6.x86_64 7/42
Installing : PyPAM-0.5.0-12.el6.x86_64 8/42
Installing : pulp-selinux-server-0.0.263-18.el6.noarch 9/42
Installing : libsemanage-python-2.0.43-4.1.el6.x86_64 10/42
Installing : libselinux-python-2.0.94-5.2.el6.x86_64 11/42
Installing : setools-libs-3.3.7-4.el6.x86_64 12/42
Installing : setools-libs-python-3.3.7-4.el6.x86_64 13/42
Installing : policycoreutils-python-2.0.83-19.18.el6.x86_64 14/42
Installing : rh-rhua-selinux-policy-0.0.6-1.el6.noarch 15/42
Enabling port 5674 for qpidd
Installing : libmongodb-1.8.2-2.el6.x86_64 16/42
Updating : mongodb-1.8.2-2.el6.x86_64 17/42
Updating : mongodb-server-1.8.2-2.el6.x86_64 18/42
Updating : python-qpid-0.12-1.el6.noarch 19/42
Updating : python-gofer-0.64-1.el6.noarch 20/42
Updating : gofer-0.64-1.el6.noarch 21/42
Installing : gofer-package-0.64-1.el6.noarch 22/42
Installing : pulp-client-lib-0.0.263-18.el6.noarch 23/42
Installing : pulp-consumer-0.0.263-18.el6.noarch 24/42
ln: creating symbolic link `/etc/rc.d/init.d/pulp-agent': File exists
Updating : mod_wsgi-3.3-2.pulp.el6.x86_64 25/42
Updating : pulp-0.0.263-18.el6.noarch 26/42
warning: /etc/httpd/conf.d/pulp.conf created as /etc/httpd/conf.d/pulp.conf.rpmnew
warning: /etc/pulp/pulp.conf created as /etc/pulp/pulp.conf.rpmnew
warning: /etc/pulp/repo_auth.conf created as /etc/pulp/repo_auth.conf.rpmnew
Updating : rh-rhui-tools-2.0.60-1.el6.noarch 27/42
warning: /etc/rhui/rhui-tools.conf created as /etc/rhui/rhui-tools.conf.rpmnew
Installing : pulp-admin-0.0.263-18.el6.noarch 28/42
Cleanup : pulp-0.0.214-8.el6.noarch 29/42
Cleanup : rh-rhui-tools-2.0.44-1.el6.noarch 30/42
Erasing : pulp-client-0.0.214-8.el6.noarch 31/42
warning: /etc/pulp/client.conf saved as /etc/pulp/client.conf.rpmsave
Cleanup : gofer-0.43-1.el6.noarch 32/42
Cleanup : python-gofer-0.43-1.el6.noarch 33/42
Cleanup : python-qpid-0.10-1.el6.noarch 34/42
Cleanup : pulp-common-0.0.214-8.el6.noarch 35/42
Cleanup : python-isodate-0.4.4-2.el6_1.noarch 36/42
Cleanup : grinder-0.0.122-1.el6.noarch 37/42
Cleanup : python-oauth2-1.2.1-3.el6_0.noarch 38/42
Cleanup : mongodb-server-1.6.4-3.el6_0.x86_64 39/42
Cleanup : mongodb-1.6.4-3.el6_0.x86_64 40/42
Cleanup : m2crypto-0.20.2-7.el6.x86_64 41/42
Cleanup : mod_wsgi-3.2-3.sslpatch.el6.x86_64 42/42
Installed products updated.
Consumer Id could not be found. Cannot update consumer profile.
Installed:
pulp-admin.noarch 0:0.0.263-18.el6 pulp-client-lib.noarch 0:0.0.263-18.el6 pulp-consumer.noarch 0:0.0.263-18.el6
Dependency Installed:
PyPAM.x86_64 0:0.5.0-12.el6 audit-libs-python.x86_64 0:2.1.3-3.el6 gofer-package.noarch 0:0.64-1.el6 libcgroup.x86_64 0:0.37-3.el6
libmongodb.x86_64 0:1.8.2-2.el6 libselinux-python.x86_64 0:2.0.94-5.2.el6 libsemanage-python.x86_64 0:2.0.43-4.1.el6 policycoreutils-python.x86_64 0:2.0.83-19.18.el6
pulp-selinux-server.noarch 0:0.0.263-18.el6 rh-rhua-selinux-policy.noarch 0:0.0.6-1.el6 setools-libs.x86_64 0:3.3.7-4.el6 setools-libs-python.x86_64 0:3.3.7-4.el6
Updated:
gofer.noarch 0:0.64-1.el6 grinder.noarch 0:0.0.136-1.el6 m2crypto.x86_64 0:0.21.1.pulp-7.el6 mod_wsgi.x86_64 0:3.3-2.pulp.el6 mongodb.x86_64 0:1.8.2-2.el6
mongodb-server.x86_64 0:1.8.2-2.el6 pulp.noarch 0:0.0.263-18.el6 pulp-common.noarch 0:0.0.263-18.el6 python-gofer.noarch 0:0.64-1.el6 python-isodate.noarch 0:0.4.4-4.pulp.el6
python-oauth2.noarch 0:1.5.170-2.pulp.el6 python-qpid.noarch 0:0.12-1.el6 rh-rhui-tools.noarch 0:2.0.60-1.el6
Replaced:
pulp-client.noarch 0:0.0.214-8.el6
Complete!
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]# yum install PyPAM python-rhsm policycoreutils-python
Loaded plugins: product-id, pulp-profile-update, rhui-lb, security, subscription-manager
Updating certificate-based repositories.
Setting up Install Process
Package PyPAM-0.5.0-12.el6.x86_64 already installed and latest version
Package python-rhsm-0.96.15-1.el6.noarch already installed and latest version
Package policycoreutils-python-2.0.83-19.18.el6.x86_64 already installed and latest version
Nothing to do
[root@qeblade30 RHUI201CLIENT]# vi /etc/httpd/conf.d/pulp.conf
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]# vi /etc/pulp/pulp.conf
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]# vi /etc/pulp/repo_auth.conf
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]# vi /etc/rhui/rhui-tools.conf
[root@qeblade30 RHUI201CLIENT]# hostname
qeblade30.rhq.lab.eng.bos.redhat.com
[root@qeblade30 RHUI201CLIENT]# vi /etc/pulp/admin/admin.conf
[root@qeblade30 RHUI201CLIENT]# vi /etc/pulp/repo_auth.conf
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]# pulp-migrate
database migration to version 38 complete
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]#
[root@qeblade30 RHUI201CLIENT]# service pulp-server restart
Stopping httpd: [ OK ]
Stopping Qpid AMQP daemon: [ OK ]
Stopping mongod: [ OK ]
Starting mongod: [ OK ]
Starting Qpid AMQP daemon: [ OK ]
Starting httpd: [ OK ]
[root@qeblade30 RHUI201CLIENT]# setenforce 1
[root@qeblade30 RHUI201CLIENT]# getenforce
Enforcing
rhui (repo) => l
Custom Repositories
unprotected
protected
Red Hat Repositories
Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
------------------------------------------------------------------------------
rhui (repo) => d
Select one or more repositories:
Custom Repositories
- 1 : protected
- 2 : unprotected
Red Hat Repositories
- 3 : Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
Enter value (1-3) to toggle selection, 'c' to confirm selections, or '?' for more commands: 3
Select one or more repositories:
Custom Repositories
- 1 : protected
- 2 : unprotected
Red Hat Repositories
x 3 : Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
Enter value (1-3) to toggle selection, 'c' to confirm selections, or '?' for more commands: c
The following repositories will be deleted:
Red Hat Repositories
Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)
Proceed? (y/n) y
Deleting Red Hat Update Infrastructure 2.0 (RPMs) (6Server-x86_64)...
------------------------------------------------------------------------------
rhui (repo) => d
Select one or more repositories:
Custom Repositories
- 1 : protected
- 2 : unprotected
Red Hat Repositories
Enter value (1-2) to toggle selection, 'c' to confirm selections, or '?' for more commands: 1
Select one or more repositories:
Custom Repositories
x 1 : protected
- 2 : unprotected
Red Hat Repositories
Enter value (1-2) to toggle selection, 'c' to confirm selections, or '?' for more commands: c
The following repositories will be deleted:
Custom Repositories
protected
Proceed? (y/n) y
Deleting protected...
------------------------------------------------------------------------------
rhui (repo) => d
Select one or more repositories:
Custom Repositories
- 1 : unprotected
Red Hat Repositories
Enter value (1-1) to toggle selection, 'c' to confirm selections, or '?' for more commands: 1
Select one or more repositories:
Custom Repositories
x 1 : unprotected
Red Hat Repositories
Enter value (1-1) to toggle selection, 'c' to confirm selections, or '?' for more commands: c
The following repositories will be deleted:
Custom Repositories
unprotected
Proceed? (y/n) y
Deleting unprotected...
------------------------
Released in RHUI 2.0.2 |