20091012 reapplying packages to fix fatal errors - plembo/onemoretech GitHub Wiki

title: Reapplying packages to fix fatal errors link: https://onemoretech.wordpress.com/2009/10/12/reapplying-packages-to-fix-fatal-errors/ author: lembobro description: post_id: 231 created: 2009/10/12 20:33:17 created_gmt: 2009/10/12 20:33:17 comment_status: open post_name: reapplying-packages-to-fix-fatal-errors status: publish post_type: post

Reapplying packages to fix fatal errors

Something I learned a long time ago while working with Red Hat Enterprise Linux (RHEL) was the trick of reinstalling packages with the “\--force” switch when things would go South without warning. The theory was that something bad had happened to a critical binary or binaries and the quickest way to get them back to normal was reapplying any related package (or packages). Sort of similar to the old trick of reapplying a Windows service pack.

As everyone knows, reapplying packages on RHEL can be tricky because of the rpm utility’s built-in dependency checker. Sometimes you need to add the useful but dangerous “\--nodeps” option: recommended only where you know for sure that all the dependencies are in fact already in place.

Things are slightly different on Solaris, particularly where working with Sunfreeware. While Sunfreeware is a wonderful resource, Sun’s package handling utilities are… well, not rpm. Or yum. Dependency checking is pretty much non-existent, and you can get yourself in all kinds of trouble really fast if you’re not careful (maybe Sun should consider integrating yum into Solaris).

Start installing, or in my case, upgrading, packages and you’re likely to break something really badly. Like when I applied some new versions of various packages and got this friendly error the next time I tries to run df:

ld.so.1: df: fatal: relocation error: file /usr/local/lib/libintl.so.8

… or words to that effect.

The solution in my place was to remove and then reinstall the following Sunfreeware packages, in the following order:

libiconv libintl gcc

Be prepared to drop back to native Solaris tools in the process, because conveniences like the GNU versions of gunzip, sftp and even /usr/local/bin/ls are not going to work until you’re done. I just su’d to root for the duration to avoid being more frustrated than necessary.

Copyright 2004-2019 Phil Lembo