I think you need to clear your installed old dnf and it's dependent packages.
You can run this command to remove those rpms and then run the dnf script again.
rpm -e libcomps python3-libcomps python3-dnf dnf dnf-automatic dnf-data libdnf python3-hawkey python3-libdnf librepo python3-librepo
Original Message:
Sent: Wed November 08, 2023 09:53 AM
From: Mi Wang
Subject: DNF / Python 3.9.18 Upgrade Issue
Hi Ranjit,
Please see my answers below:
- Are you trying to install python 3.7 from your locally hosted AIX repo? - Actually I has tried to re-install python 3.7 and old dnf by running 'install_dnf.sh -d'. Although the running is successful, I can't run dnf (system says not such file, even through the file is there. So I tried to config it with local repo by running "...//ezinstall/ppc/dnf_aixtoolbox_local.sh".
/opt/freeware/bin: ls -lrt /opt/freeware/bin/dnf-3
-rwxr-xr-x 1 root system 1960 Apr 28 2023 /opt/freeware/bin/dnf-3
/opt/freeware/bin: /opt/freeware/bin/dnf-3
ksh: /opt/freeware/bin/dnf-3: not found
- How this local repo is configured ? is it the same system where you are installing python3.7 or different system acts as repo system ?
It's on the same AIX box where python3.7 is insatlled. I downloaded the iso file and extracted it by running "gzip -dc ESD-Toolbox_for_Linux_Apps_Common_7.1-7.3_122022_LKT010325.tar.gz | tar xf - -C {destination folder}"
- what's the current installed dnf version ? output of 'rpm -qa | grep -I dnf' ?
Based on the following output, I think the dnf is still the upgraded one, which means the effort to re-install the old dnf associated with python 3.7 wasn't successful:
/opt/freeware/bin: rpm -qa | grep -i dnf
dnf-automatic-4.2.17-32_50.ppc
dnf-data-4.2.17-32_51.ppc
python3-libdnf-0.39.1-32_52.ppc
libdnf-0.39.1-32_52.ppc
python3-dnf-4.2.17-32_51.ppc
Please provide method to resolve the issue. Thanks in advance.
Mi
------------------------------
Mi Wang
Original Message:
Sent: Wed November 08, 2023 06:03 AM
From: Ranjit Ranjan
Subject: DNF / Python 3.9.18 Upgrade Issue
Hi
Are you trying to install python 3.7 from your locally hosted AIX repo ?
How this local repo is configured ? is it the same system where you are installing python3.7 or different system acts as repo system ?
what's the current installed dnf version ? output of 'rpm -qa | grep -I dnf' ?
Thanks
Ranjit
------------------------------
Ranjit Ranjan
Original Message:
Sent: Tue November 07, 2023 02:33 PM
From: Mi Wang
Subject: DNF / Python 3.9.18 Upgrade Issue
Hello Ranjit,
I encountered the following difficulty when upgrading to dnf / python 3.9.18 from python 3.7 on our AIX server box:
In the middle of running 'dnf update' to upgrade to python 3.9.18, we had out of space issue with /opt and I see errors like following:
"Error unpacking rpm package python3.9-librepo-1.11.0-103.ppc
Upgrading : python3-librepo-1.11.0-103.ppc 70/145
error: unpacking of archive failed on file /opt/freeware/lib/python3.9/site-packages/librepo/__init__.py;6549e00b: cpio: write
error: python3.9-librepo-1.11.0-103.ppc: install failed
Upgrading : dnf-automatic-4.2.17-32_51.ppc 71/145
error: rpmdb: write: 0x3072a9b8, 4096: No space left on device
error: rpmdb: Packages: write failed for page 1738
error: rpmdb: Packages: unable to flush page: 1738"
We then added space to /opt and reran 'dnf update' and we always get the following error:
"/opt/freeware/etc/dnf: dnf update
Traceback (most recent call last):
File "/opt/freeware/bin/dnf", line 57, in <module>
from dnf.cli import main
File "/opt/freeware/lib/python3.9/site-packages/dnf/__init__.py", line 25, in <module>
import dnf.pycomp
ModuleNotFoundError: No module named 'dnf.pycomp'"
I have tried to re-install the original python 3.7 dnf by running 'install-dnf.sh -d'. After removing all python3.9* packages and a couple of offending packages like python3-gpg-1.13.1-101.ppc, install_dnf ran successfully. But I then found I can't run /opt/freeware/bin/dnf, even the dnf file is there. I got following error (very weird):
"/opt/freeware/etc/dnf: dnf update
ksh: dnf: not found"
I then tried to run 'dnf_aixtoolbox_local.sh' to use local Toolbox repo for python 3.7 and got following error:
"error: Failed dependencies:
/opt/freeware/bin/python3_32 is needed by yum-4.2.17-32_2.noarch
dnf = 4.2.17-32_2 is needed by yum-4.2.17-32_2.noarch
dnf-data = 4.2.17-32_2 is needed by yum-4.2.17-32_2.noarch
yum >= 4.2.17-32_1 is obsoleted by (installed) dnf-4.2.17-32_50.ppc"
Please help.
Thanks
Mi
------------------------------
Mi Wang
------------------------------