Bug 1005675 - Broken postinstall script
Summary: Broken postinstall script
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: krb5
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
Assignee: Nalin Dahyabhai
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-09 07:05 UTC by Mattias Ellert
Modified: 2013-09-09 14:12 UTC (History)
2 users (show)

Fixed In Version: krb5-1.11.3-11.fc21
Clone Of:
Environment:
Last Closed: 2013-09-09 14:12:42 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Mattias Ellert 2013-09-09 07:05:52 UTC
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
krb5-libs-1.11.3-10.fc21.x86_64

How reproducible:

Always

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 07:59:55 UTC
Changing


%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.  


to


%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 14:12:42 UTC
Looks good.  Thanks for catching it!


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