Bug 1005675 - Broken postinstall script
Broken postinstall script
Product: Fedora
Classification: Fedora
Component: krb5 (Show other bugs)
Unspecified Unspecified
unspecified Severity low
: ---
: ---
Assigned To: Nalin Dahyabhai
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-09-09 03:05 EDT by Mattias Ellert
Modified: 2013-09-09 10:12 EDT (History)
2 users (show)

See Also:
Fixed In Version: krb5-1.11.3-11.fc21
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-09-09 10:12:42 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Mattias Ellert 2013-09-09 03:05:52 EDT
Description of problem:

  Uppdaterar  : krb5-libs-1.11.3-10.fc21.x86_64                            7/68 
/sbin/ldconfig: relativ sökväg "2" använd för att bygga cache
varning: %post(krb5-libs-1.11.3-10.fc21.x86_64)-skript misslyckades, slutstatus 1
Non-fatal POSTIN scriptlet failure in rpm package krb5-libs-1.11.3-10.fc21.x86_64

Version-Release number of selected component (if applicable)

# rpm -q krb5-libs

How reproducible:


Steps to Reproduce:
1. install/update krb5-libs using yum
2. watch terminal output of yum command

Actual results:

See above

Expected results:

No errors

Additional info:

The scripts look like this;

# rpm -q --scripts krb5-libs
postinstall scriptlet (using /sbin/ldconfig):

# Roughly the version where this logic was introduced.
postuninstall program: /sbin/ldconfig

As can be seen there is a difference between the postuninstall script (that is correct) which asks for running /sbin/ldconfig without arguments and input, and the postinstall script wich ask for running a two line script (containing one empty line and one line starting with #) using the /sbin/ldconfig as an interpreter.

My guess is that this is really a badly placed comment in the specfile that was not intended to be part of the postinstall script, but rather a comment explaining the section following the postinstall section. But since this comment technically is inside the postinstall section it becomes part of the postinstall script.
Comment 1 Mattias Ellert 2013-09-09 03:59:55 EDT

%post libs -p /sbin/ldconfig

%if 0%{?configure_default_ccache_name}
# Roughly the version where this logic was introduced.
%triggerun libs -- krb5-libs < 1.11.3-10
# Try to add a default_ccache_name to /etc/krb5.conf.  


%post libs -p /sbin/ldconfig

%if 0%{?configure_default_ccache_name}
%triggerun libs -- krb5-libs < 1.11.3-10
# Roughly the version where this logic was introduced.
# Try to add a default_ccache_name to /etc/krb5.conf.  

would fix this.
Comment 2 Nalin Dahyabhai 2013-09-09 10:12:42 EDT
Looks good.  Thanks for catching it!

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