Bug 810448 - A postinstall scriptlet's bug in pulp-0.0.263-18.el6
Summary: A postinstall scriptlet's bug in pulp-0.0.263-18.el6
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Update Infrastructure for Cloud Providers
Classification: Red Hat
Component: RHUA
Version: 2.1
Hardware: Unspecified
OS: Linux
high
medium
Target Milestone: ---
: ---
Assignee: wes hayutin
QA Contact: Martin Kočí
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-04-06 07:55 UTC by Satoru SATOH
Modified: 2012-08-24 13:26 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
The spec file for pulp-0.0.263-18 contained a faulty line in the post-installation scriptlet. This caused pulp installation to report an access error for a missing file. This issue is fixed in pulp-0.0.263-25. The faulty line has been removed and no errors appear during installation.
Clone Of:
Environment:
Last Closed: 2012-08-24 11:54:00 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
An experimental and not tested patch to resolve a postinstall scriptlet error (1.14 KB, patch)
2012-04-06 07:55 UTC, Satoru SATOH
no flags Details | Diff
2nd try (810 bytes, patch)
2012-04-09 17:52 UTC, Satoru SATOH
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2012:1205 0 normal SHIPPED_LIVE RHUI 2.1 Enhancement Update 2012-08-24 15:52:31 UTC

Description Satoru SATOH 2012-04-06 07:55:33 UTC
Created attachment 575644 [details]
An experimental and not tested patch to resolve a postinstall scriptlet error

Description of problem:
pulp-0.0.263-18.el6 has a problem in its postinstall scriptlet and that 
cause error messages shown during RHUA installation process.


Version-Release number of selected component (if applicable):
pulp-0.0.263-18.el6


How reproducible: Always

Steps to Reproduce: Install pulp w/ install_RHUA.sh in RHUI ISO image

  
Actual results: Here is a part of installation log (sorry in Japanese):

  Installing : pulp-0.0.263-18.el6.noarch   
                                            16/18
Non-fatal POSTIN scriptlet failure in rpm package pulp-0.0.263-18.el6.noarch
chown: cannot access `/etc/pki/pulp/content/pulp-protected-repos': そのようなファイルやディレクトリはありません
警告: %post(pulp-0.0.263-18.el6.noarch) scriptlet failed, exit status 1


Expected results: No scriptlet errors happen.


Additional info:
I attached an experimental (not tested) patch to resolve this issue.


Also, I looked through the rpm spec of pulp and found some other danger
code embedded in pulp's scriptlets.

In common, to use rm/mv/ln -s in scriptlets should be avoided.

Comment 1 Satoru SATOH 2012-04-09 17:52:17 UTC
Created attachment 576268 [details]
2nd try

Sorry, the previous patch does not work at all and this version looks OK.

Comment 2 wes hayutin 2012-05-21 21:13:14 UTC
[root@ip-10-46-135-129 Packages]# rpm -Uvh pulp-0.0.263-19.el6.noarch.rpm --nodeps
Preparing...                ########################################### [100%]
   1:pulp                   ########################################### [100%]
chown: cannot access `/etc/pki/pulp/content/pulp-protected-repos': No such file or directory
warning: %post(pulp-0.0.263-19.el6.noarch) scriptlet failed, exit status 1


Not sure what the next version of pulp RHUI will rebase w/, but this seems to be fixed in 290

[root@ip-10-46-135-129 tmp]# rpm -Uvh pulp-0.0.290-1.el6.noarch.rpm --nodeps
Preparing...                ########################################### [100%]
   1:pulp                   ########################################### [100%]
[root@ip-10-46-135-129 tmp]#

Comment 3 wes hayutin 2012-07-13 14:46:32 UTC
recreated the error on clean install:

 Installing : python-bson-1.9-8.el6_1.x86_64                                                                                                                                                                31/38 
  Installing : pymongo-1.9-8.el6_1.x86_64                                                                                                                                                                    32/38 
  Installing : 1:python-BeautifulSoup-3.0.8.1-3.el6_1.noarch                                                                                                                                                 33/38 
  Installing : mod_wsgi-3.3-2.pulp.el6.x86_64                                                                                                                                                                34/38 
  Installing : pulp-0.0.263-21.el6_3.noarch                                                                                                                                                                  35/38 
Non-fatal POSTIN scriptlet failure in rpm package pulp-0.0.263-21.el6_3.noarch
chown: cannot access `/etc/pki/pulp/content/pulp-protected-repos': No such file or directory
warning: %post(pulp-0.0.263-21.el6_3.noarch) scriptlet failed, exit status 1
  Installing : pulp-admin-0.0.263-21.el6_3.noarch                                                                                                                                                            36/38 
  Installing : pulp-consumer-0.0.263-21.el6_3.noarch

Comment 4 wes hayutin 2012-07-13 15:15:47 UTC
pulp rhui branch
98e984e7974dab0558d9fc3a157416dce5d0fc88


diff --git a/pulp.spec b/pulp.spec
index 5cde359..0db2809 100644
--- a/pulp.spec
+++ b/pulp.spec
@@ -318,7 +318,6 @@ then
   fi
 fi
 
-chown apache:apache /etc/pki/pulp/content/pulp-protected-repos

Comment 5 wes hayutin 2012-07-13 15:31:02 UTC
##### Commit message: #####

Update pulp to 0.0.263-22

Comment 6 Martin Kočí 2012-08-03 11:05:24 UTC
in the latest build there is pulp-0.0.263-25.el6_3.noarch.rpm which successfuly installed to the system: 
[root@ip-10-46-39-253 ~]# rpm -Uvh pulp-0.0.263-25.el6_3.noarch.rpm --nodeps
Preparing...                ########################################### [100%]
   1:pulp                   ########################################### [100%]
[root@ip-10-46-39-253 ~]# 


Moving bug to VERIFIED.

Comment 7 Dan Macpherson 2012-08-14 04:34:56 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
The spec file for pulp-0.0.263-18 contained a faulty line in the post-installation scriptlet. This caused pulp installation to report an access error for a missing file. This issue is fixed in pulp-0.0.263-25. The faulty line has been removed and no errors appear during installation.

Comment 9 errata-xmlrpc 2012-08-24 11:54:00 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2012-1205.html


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