The AIX Toolbox team recommends using DNF (the next-generation replacement for YUM) to install and manage Open Source software packages and dependencies from the AIX Toolbox. Some users are not able to install AIX Toolbox packages due to conflicting files from non-Toolbox sources. There is a way to clean the database, then install DNF.
Important!!!!! This is an unsupported method, provided as a 'last resort option' to possibly avoid the need to reinstall the operating system.
- All /opt/freeware packages and related files will be removed.
- It is recommended to make a system backup, or JFS2 snapshot of /opt before proceeding.
Before trying this method, you could try the following:
1) Remove the packages which aren't in sync: # rpm -e pkg1 pkg2 pkg3 --nodeps
2) Run the install script (it is assumed that you have already run the dnf_aixtoolbox.sh and had install failures) cd <DNF package download path> (typically /var/cache/dnf)
./install_dnf.sh -y
/opt/freeware/bin/dnf update
|
|
1) Recommended: Make a system backup, or JFS2 snapshot of /opt before proceeding.
2) Download the destroyRPMS to remove all all RPMS installed on the system.
- https://public.dhe.ibm.com/aix/freeSoftware/aixtoolbox/contrib/destroyRPMS
3) Download the dnf install script.
- https://public.dhe.ibm.com/aix/freeSoftware/aixtoolbox/ezinstall/ppc/dnf_aixtoolbox.sh
- Visit Get Started to learn more about DNF and the dnf_aixtoolbox.sh install script.
4) Run the destroyRPMS script.
# chmod +x destroyRPMS # ./destroyRPMS
WARNING: This script removes all RPMS installed on the system, removes the RPM database, and removes the rpm.rte install image. It also removes root configuration for GNOME and KDE. You should exit KDE and GNOME and run this from a root console.
You will most likely see several error messages because all RPMS are being clobbered in no particular order, so removal of dependencies may cause some deinstall scripts to fail and many 'directory not empty' messages to appear. Since your goal is removal of all RPMS, these errors should not be of concern.
Proceed to destroy all RPMs on the system? y/(n) y
<... installation output....>
PLEASE NOTE: Your rpms have been removed, but rpm.rte did not deinstall. Most likely this means that you have another installp fileset that lists rpm.rte as a dependency. If you really want to remove rpm.rte, you will need to deinstall those dependencies as well. If you do not, then you still have rpm.rte installed, but it is now non-functional. To make it functional again, simply reinstall rpm.rte with the force option. For example, change to the directory where you have the rpm.rte image and run: installp -qacXFd rpm.rte all
Your rpms have been removed, but the /opt/freeware and /usr/opt/freeware directories (one is just a symbolic link) have been left present. You may want to look through these directories for any files you may have created yourself. If there is nothing that you want to save, you can now remove these directories and any remaining contents within. |
Now, in steps 5-8, prepare to run the dnf_aixtoolbox.sh script.
The current rpm.rte file set is not complete, since many files and directories were removed. For example, the lppchk -c returns errors:
# lppchk -c rpm.rte lppchk: File /usr/opt/freeware/src/packages/SRPMS could not be located. lppchk: File /usr/opt/freeware/src/packages/RPMS/noarch could not be located. lppchk: File /usr/opt/freeware/src/packages could not be located. lppchk: File /usr/opt/freeware/info could not be located. lppchk: File /usr/opt/freeware/src/packages/RPMS could not be located. lppchk: File /usr/opt/freeware/src could not be located. lppchk: File /usr/opt/freeware/src/packages/RPMS/ppc could not be located. lppchk: File /usr/opt/freeware/src/packages/SPECS could not be located. lppchk: File /usr/opt/freeware/src/packages/RPMS/powerpc could not be located. lppchk: File /usr/opt/freeware/src/packages/SOURCES could not be located. lppchk: File /usr/opt/freeware/src/packages/BUILD could not be located. |
5) Remove any remaining Toolbox files and directories.
6) Download and install the latest rpm.rte
Download the latest rpm.rte
- AIX Open Source: Downloading the RPM Package Manager rpm.rte File Set
- https://www.ibm.com/support/pages/node/7007063
Change directories to the download directory and install.
# installp -qaXFY -d . rpm.rte |
The rpm.rte installation script will call /usr/sbin/updtvpkg.
7) Check free space, increase if required.
Expected:
/tmp >= 340MB
/opt >= 500MB
/var >= 500MB
8) Run the dnf_aixtoolbox.sh script.
# chmod +x dnf_aixtoolbox.sh # ./dnf_aixtoolbox.sh -d
<... installation output....>
dnf installed successfully. Please run 'dnf update' to update packages to the latest level.
Please note, RPM packages are downloaded in dnf cache /var/cache/dnf. RPM packages install files go under the path /opt. Hence it is recommended to always keep at least 512MB of free space in /var & /opt to avoid any download and installation/update failures. |
9) Update dnf.
# /opt/freeware/bin/dnf update |