The sas_snmp-3.17-1118.i386 package as provided by LSI in the Megaraid storage manager package is buggy and fails to uninstall. This even blocks upgrades to newer versions of this package. Unfortunately, I have this package installed on a lot of systems and I ended up having to manually resolve a bunch of puppet run failures when I placed updated rpms in my local “lsi” repo.
This is the procedure to resolve the failure:
# rpm -e sas_snmp.i386 /var/tmp/rpm-tmp.Htmwit: line 1: /etc/lsi_mrdsnmp/sas/uninstall: No such file or directory error: %preun(sas_snmp-3.17-1118.i386) scriptlet failed, exit status 127 # rpm -qa | grep sas_snmp sas_snmp-3.17-1118.i386 # rpm -e sas_snmp.i386 /var/tmp/rpm-tmp.es7YWz: line 1: /etc/lsi_mrdsnmp/sas/uninstall: No such file or directory error: %preun(sas_snmp-3.17-1118.i386) scriptlet failed, exit status 127 # mkdir -p /etc/lsi_mrdsnmp/sas/ # touch /etc/lsi_mrdsnmp/sas/uninstall # chmod 777 /etc/lsi_mrdsnmp/sas/uninstall # rpm -e sas_snmp.i386 # rm -rf /etc/lsi_mrdsnmp/ # rpm -qa | grep sas_snmp #
2015-08-22 at 21:45
Today I upgraded LSI (now Avago) MegaRAID storage manager on CentOS 6 and I ran into a number of “file /etc/lsi_mrdsnmp/* from install of sas_snmp-15.05-0004.x86_64 conflicts with file from package sas_snmp-13.01-0300.x86_64” errors. When I tried to uninstall the sas_snmp.x86_64 0:13.01-0300 package I ran into the “PREUN scriptlet” error. Google brought me here. I followed your basic instructions and BAM its fixed. Three years later and your post is still solving problems. Thanx Josh.
2015-08-23 at 05:17
Glad to be of service!