DNF error: Error in POSTIN scriptlet in rpm package srvadmin-cm
Environment
- Red Hat Enterprise Linux (RHEL) 8
Issue
-
Anaconda install fails with the following when doing minimal install, but including 3rd party
srvadmin-baseRPM.<snip> Installing srvadmin-cm.x86_64 (130/367) ===================================================================== Error The following error occurred while installing. This is a fatal error and installation will be aborted. DNF error: Error in POSTIN scriptlet in rpm package srvadmin-cm
Resolution
- The 3rd party RPM needs to add RPM dependency on
coreutilsRPM and/orlnbinary.
Work Around
- Install RHEL without the 3rd party
srvadminRPMS. Then after the OS is installed, which will includecoreutilsRPM, install the 3rd partysrvadminRPMs.
Root Cause
-
None of the Dell (3rd party) RPMs have a require on
lnorcoreutils# rpm -qa | grep srvadm srvadmin-deng-9.5.0-4063.16816.el8 srvadmin-isvc-9.5.0-4063.16816.el8 srvadmin-base-9.5.0-4063.16816.el8. srvadmin-cm-9.5.0-20.09.00 srvadmin-omilcore-9.5.0-4063.16816.el8 srvadmin-smcommon-9.5.0-4063.16816.el8 srvadmin-hapi-9.5.0-4063.16816.el8 srvadmin-ominst-9.5.0-4063.16816.el8 srvadmin-xmlsup-9.5.0-4063.16816.el8 srvadmin-omacs-9.5.0-4063.16816.el8 # rpm -q --requires $(rpm -qa | grep srvadm) | egrep -c 'coreutils|ln' 0
Diagnostic Steps
-
From one of the anaconda shell windows, like the tmux shell window (control-b,2), view the dnf history via chroot of the installing image.
[anaconda root@localhost ~]# chroot /mnt/sysimage/ [anaconda root@localhost ~]# dnf history info 1 | egrep -B1 'Scriptlet|exit status' Install @platform-kvm Scriptlet output: -- 7 /var/tmp/rpm-tmp.GSYac7: line 2: ln: command not found 8 warning: %post(srvadmin-cm-9.5.0-20.09.00.x86_64) scriptlet failed, exit status 127 -
Looking at the rpm scripts, can see it is doing
lncommand[anaconda root@localhost ~]# rpm -q --scripts srvadmin-cm | grep -A2 ^postinstall postinstall scriptlet (using /bin/sh): # create sym link to use 64 bit invcol ln -sf /opt/dell/srvadmin/sbin/lx64/invcol /opt/dell/srvadmin/sbin/invcol -
lnis provided by coretuils# rpm -q --whatprovides /bin/ln coreutils-8.30-8.el8.x86_64 # rpm -q --whatprovides /usr/bin/ln coreutils-8.30-8.el8.x86_64
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.
Comments