Power

 View Only
  • 1.  Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Fri December 22, 2023 11:55 AM

    root@lp102:/# 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 32, in <module>
        import dnf.base
      File "/opt/freeware/lib/python3.9/site-packages/dnf/base.py", line 29, in <module>
        import libdnf.transaction
      File "/opt/freeware/lib/python3.9/site-packages/libdnf/__init__.py", line 3, in <module>
        from . import common_types
      File "/opt/freeware/lib/python3.9/site-packages/libdnf/common_types.py", line 13, in <module>
        from . import _common_types
    ImportError:    0509-022 Cannot load module /opt/freeware/lib/libdnf.a(libdnf.so.2).
            0509-150   Dependent module /opt/freeware/lib/libcrypto.a(libcrypto.so.1.1) could not be loaded.
            0509-152   Member libcrypto.so.1.1 is not found in archive
            0509-022 Cannot load module /opt/freeware/lib/python3.9/site-packages/libdnf/_common_types.so.
            0509-150   Dependent module /opt/freeware/lib/libdnf.a(libdnf.so.2) could not be loaded.



    ------------------------------
    Michael Sly
    ------------------------------


  • 2.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Tue December 26, 2023 10:41 AM

    This is a pretty common problem after installing dnf.  A couple of quick things to check is a broken link on /opt/freeware/lib/libdnf.a, (or any other archive file that pops up missing "so" files) if its pointing to a non-existent file or if running the command ar -tv  /opt/freeware/lib/libdnf.a does not contain "libdnf.so.2", look under /usr/bin for "libdnf.a" and /opt, and check if they contain the "so" file you're missing.  Removing the non-esistent link, or link not containing the "so" file your looking for, and pointing to a libdnf.a that has what your missing "so" can sometimes fix that.  If you still running into problems get a list of just the rpms installed by dnf, remove them, run the "updtvpkg" command and reinstall dnf again.  I've had good luck doing that.  



    ------------------------------
    Kolin Vance
    ------------------------------



  • 3.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Tue December 26, 2023 11:45 AM
    Edited by Mark Steele Tue December 26, 2023 11:45 AM

    If that doesn't work, there's always the sledgehammer approach documented at:

    https://community.ibm.com/community/user/power/blogs/jan-harris1/2022/05/25/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.



    ------------------------------
    Mark Steele
    ------------------------------



  • 4.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Wed December 27, 2023 10:20 AM
    So here are the errors I'm getting:

    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 32, in <module>
        import dnf.base
      File "/opt/freeware/lib/python3.9/site-packages/dnf/base.py", line 29, in <module>
        import libdnf.transaction
      File "/opt/freeware/lib/python3.9/site-packages/libdnf/__init__.py", line 3, in <module>
        from . import common_types
      File "/opt/freeware/lib/python3.9/site-packages/libdnf/common_types.py", line 13, in <module>
        from . import _common_types
    ImportError:    0509-022 Cannot load module /usr/opt/rpm/lib/libpopt.a(libpopt.so.0).
            0509-150   Dependent module /opt/freeware/lib/libintl.a(libintl.so.8) could not be loaded.
            0509-152   Member libintl.so.8 is not found in archive
            0509-022 Cannot load module /opt/freeware/lib/python3.9/site-packages/libdnf/_common_types.so.
            0509-150   Dependent module /usr/opt/rpm/lib/libpopt.a(libpopt.so.0) could not be loaded.

    Here is what I see:

    ls -l /opt/freeware/bin/dnf
    lrwxrwxrwx    1 root     system            5 Dec 22 10:45 /opt/freeware/bin/dnf -> dnf-3

    ls -l /opt/freeware/lib/python3.9/site-packages/dnf/__init__.py
    -rw-r--r--    1 root     system         1474 Jun 29 2023  /opt/freeware/lib/python3.9/site-packages/dnf/__init__.py

    ls -l /opt/freeware/lib/python3.9/site-packages/dnf/base.py
    -rw-r--r--    1 root     system       104258 Nov 25 2019  /opt/freeware/lib/python3.9/site-packages/dnf/base.py

    ls -l /opt/freeware/lib/python3.9/site-packages/libdnf/__init__.py
    -rw-r--r--    1 root     system          172 Nov 25 2019  /opt/freeware/lib/python3.9/site-packages/libdnf/__init__.py

    ls -l /opt/freeware/lib/python3.9/site-packages/libdnf/common_types.py
    -rw-r--r--    1 root     system        29016 Apr 07 2023  /opt/freeware/lib/python3.9/site-packages/libdnf/common_types.py

    For the import errors:

    ar -tv /opt/freeware/lib/libintl.a
    rwxr-xr-x   203/1     114582 Jan 04 14:38 2008 libintl.so.1
    rw-r--r--   203/1       6816 Jan 04 14:38 2008 intl-compat.o
    rw-r--r--   203/1       7632 Jan 04 14:38 2008 bindtextdom.o
    rw-r--r--   203/1       1840 Jan 04 14:38 2008 dcgettext.o
    rw-r--r--   203/1       1768 Jan 04 14:38 2008 dgettext.o
    rw-r--r--   203/1       1877 Jan 04 14:38 2008 gettext.o
    rw-r--r--   203/1       5045 Jan 04 14:38 2008 finddomain.o
    rw-r--r--   203/1      13339 Jan 04 14:38 2008 loadmsgcat.o
    rw-r--r--   203/1       9525 Jan 04 14:38 2008 localealias.o
    rw-r--r--   203/1       3005 Jan 04 14:38 2008 textdomain.o
    rw-r--r--   203/1      10685 Jan 04 14:38 2008 l10nflist.o
    rw-r--r--   203/1       5351 Jan 04 14:38 2008 explodename.o
    rw-r--r--   203/1      23822 Jan 04 14:38 2008 dcigettext.o
    rw-r--r--   203/1       1911 Jan 04 14:38 2008 dcngettext.o
    rw-r--r--   203/1       1866 Jan 04 14:38 2008 dngettext.o
    rw-r--r--   203/1       1979 Jan 04 14:38 2008 ngettext.o
    rw-r--r--   203/1      15990 Jan 04 14:38 2008 plural.o
    rw-r--r--   203/1       6503 Jan 04 14:38 2008 localcharset.o

    ar -tv /usr/opt/rpm/lib/libintl.a
    rwxr-xr-x     0/0      93072 May 28 04:38 2022 libintl.so.8
    rw-r-----     0/0     114582 May 28 04:52 2022 libintl.so.1

    So it seems to be confised between /usr/opt/rpm and /opt/freeware.

    But IDK how to fix it...



    Thanks,

        Mike





  • 5.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Wed December 27, 2023 08:53 AM
    Here is the output from the command that were suggested:

    ls -l /opt/freeware/lib/libdnf.a
    -rwxr-xr-x    1 root     system     39557381 Apr 07 2023  /opt/freeware/lib/libdnf.a

    ar -tv  /opt/freeware/lib/libdnf.a
    rwxr-xr-x   203/1     36838344 Apr 07 06:07 2023 libdnf.so.2

    Unless I'm misunderstanding, the output of those commands look OK to me.

    How do I get a list of the files that dnf installed?



    Thanks,

        Mike





  • 6.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Wed December 27, 2023 10:31 AM

    There's a couple ways to pick up the list, the download website and just capturing the list of already installed rpms when you run the dnf_aixtoolbox.sh install.

    Here's the list I used a couple days ago:

    ca-certificates-2023.2.60-0
    dnf-4.2.17-64_6
    dnf-automatic-4.2.17-64_6
    dnf-data-4.2.17-64_6
    libcomps-0.1.15-64_1
    libdnf-0.39.1-64_5
    libmodulemd-1.5.2-64_2
    libsmartcols-2.34-64_1
    libsolv-0.7.9-64_4
    libzstd-1.4.4-64_2
    p11-kit-0.23.22-0
    p11-kit-tools-0.23.22-0
    python3-3.9.16-0
    python3-dnf-4.2.17-64_6
    python3-gpg-1.13.1-64_3
    python3-hawkey-0.39.1-64_5
    python3-libcomps-0.1.15-64_1
    python3-libdnf-0.39.1-64_5
    python3-librepo-1.11.0-64_2
    python3.9-3.9.16-0
    python3.9-dnf-4.2.17-64_6
    python3.9-gpg-1.13.1-64_3
    python3.9-hawkey-0.39.1-64_5
    python3.9-libcomps-0.1.15-64_1
    python3.9-libdnf-0.39.1-64_5
    python3.9-librepo-1.11.0-64_2
    rpm-python3-4.15.1-64_4
    rpm-python3.9-4.15.1-64_4
    yum-4.2.17-64_6
    zchunk-libs-1.1.4-64_3

    This is the website for the dnf bundle:

    https://public.dhe.ibm.com/aix/freeSoftware/aixtoolbox/ezinstall/ppc/

    The remove command I used was rpm -e `cat <rprm list>`  --nodeps

    This should remove just the dnf rpm's used for dnf, the reinstall will refresh the needed rpms and usually solves the python issue.



    ------------------------------
    Kolin Vance
    ------------------------------



  • 7.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Wed December 27, 2023 11:42 AM
    Based on the rpm list you sent, Here is what I get when I test a removal on those rpms:

    for X in `cat /tmp/dnf_files`; do rpm --test -e $X; done
    error: package dnf-4.2.17-64_6 is not installed
    error: package dnf-automatic-4.2.17-64_6 is not installed
    error: package dnf-data-4.2.17-64_6 is not installed
    error: package libcomps-0.1.15-64_1 is not installed
    error: package libdnf-0.39.1-64_5 is not installed
    error: package libmodulemd-1.5.2-64_2 is not installed
    error: package libsmartcols-2.34-64_1 is not installed
    error: package libsolv-0.7.9-64_4 is not installed
    error: package libzstd-1.4.4-64_2 is not installed
    error: Failed dependencies:
            libp11-kit.a(libp11-kit.so.0) is needed by (installed) p11-kit-tools-0.23.22-0.ppc
            p11-kit = 0.23.22 is needed by (installed) p11-kit-tools-0.23.22-0.ppc
    error: Failed dependencies:
            p11-kit-tools >= 0.23.22 is needed by (installed) ca-certificates-2023.2.60-0.ppc
    error: Failed dependencies:
            python3 >= 3.9.16 is needed by (installed) python3-dnf-4.2.17-32_4.noarch
            python3 >= 3.9.16 is needed by (installed) python3-libcomps-0.1.15-32_1.ppc
            python3 >= 3.9.16 is needed by (installed) python3-librepo-1.11.0-32_2.ppc
            python3 >= 3.9.16 is needed by (installed) python3-gpg-1.13.1-32_3.ppc
            python3 >= 3.9.16 is needed by (installed) python3-hawkey-0.39.1-32_3.ppc
            python3 >= 3.9.16 is needed by (installed) python3-libdnf-0.39.1-32_3.ppc
            python3 >= 3.9.15 is needed by (installed) rpm-python3-4.15.1-32_2.ppc
    error: package python3-dnf-4.2.17-64_6 is not installed
    error: package python3-gpg-1.13.1-64_3 is not installed
    error: package python3-hawkey-0.39.1-64_5 is not installed
    error: package python3-libcomps-0.1.15-64_1 is not installed
    error: package python3-libdnf-0.39.1-64_5 is not installed
    error: package python3-librepo-1.11.0-64_2 is not installed
    error: Failed dependencies:
            libpython3.9.a(libpython3.9.so) is needed by (installed) rpm-python3.9-4.15.1-32_2.ppc
            libpython3.9.a(libpython3.9.so) is needed by (installed) python3.9-libdnf-0.39.1-32_3.ppc
            libpython3.9.a(libpython3.9.so) is needed by (installed) python3.9-hawkey-0.39.1-32_3.ppc
            libpython3.9.a(libpython3.9.so) is needed by (installed) python3.9-gpg-1.13.1-32_3.ppc
            libpython3.9.a(libpython3.9.so) is needed by (installed) python3.9-librepo-1.11.0-32_2.ppc
            libpython3.9.a(libpython3.9.so) is needed by (installed) python3.9-libcomps-0.1.15-32_1.ppc
            python3.9 >= 3.9.16 is needed by (installed) python3-3.9.16-0.ppc
            python3.9 >= 3.9.15 is needed by (installed) rpm-python3.9-4.15.1-32_2.ppc
            python3.9 >= 3.9.16 is needed by (installed) libdnf-0.39.1-32_3.ppc
            python3.9 >= 3.9.16 is needed by (installed) python3.9-libdnf-0.39.1-32_3.ppc
            python3.9 >= 3.9.16 is needed by (installed) python3.9-gpg-1.13.1-32_3.ppc
            python3.9 >= 3.9.16 is needed by (installed) python3.9-libcomps-0.1.15-32_1.ppc
            python3.9 >= 3.9.16 is needed by (installed) python3.9-dnf-4.2.17-32_4.noarch
            python3.9 >= 3.9.15 is needed by (installed) rpm-python3-4.15.1-32_2.ppc
            /opt/freeware/libexec/python3.9_32 is needed by (installed) python3-dnf-4.2.17-32_4.noarch
            /opt/freeware/libexec/python3.9_32 is needed by (installed) dnf-4.2.17-32_4.noarch
            /opt/freeware/libexec/python3.9_32 is needed by (installed) dnf-automatic-4.2.17-32_4.noarch
    error: package python3.9-dnf-4.2.17-64_6 is not installed
    error: package python3.9-gpg-1.13.1-64_3 is not installed
    error: package python3.9-hawkey-0.39.1-64_5 is not installed
    error: package python3.9-libcomps-0.1.15-64_1 is not installed
    error: package python3.9-libdnf-0.39.1-64_5 is not installed
    error: package python3.9-librepo-1.11.0-64_2 is not installed
    error: package rpm-python3-4.15.1-64_4 is not installed
    error: package rpm-python3.9-4.15.1-64_4 is not installed
    error: package yum-4.2.17-64_6 is not installed
    error: package zchunk-libs-1.1.4-64_3 is not installed

    Here are the installed rpms:

     rpm -qa | sort
    AIX-rpm-7.2.5.101-13.ppc
    bash-4.3-17.ppc
    bzip2-1.0.5-3.ppc
    ca-certificates-2023.2.60-0.ppc
    dnf-4.2.17-32_4.noarch
    dnf-automatic-4.2.17-32_4.noarch
    dnf-data-4.2.17-32_4.noarch
    gdbm-1.11-1.ppc
    gettext-0.10.40-8.ppc
    gpe-agent-aix-3.5-2.ppc
    gpe-agent-comm-2.6-8.ppc
    gzip-1.5-1.ppc
    info-5.1-2.ppc
    libcomps-0.1.15-32_1.ppc
    libdnf-0.39.1-32_3.ppc
    libgcc-4.8.3-1.ppc
    libiconv-1.14-2.ppc
    libidn-1.32-1.ppc
    libmodulemd-1.5.2-32_2.ppc
    librepo-1.11.0-32_2.ppc
    libsmartcols-2.34-32_1.ppc
    libsolv-0.7.9-32_3.ppc
    libzstd-1.4.4-32_1.ppc
    mtools-3.9.8-1.ppc
    p11-kit-0.23.22-0.ppc
    p11-kit-tools-0.23.22-0.ppc
    pcre-8.37-1.ppc
    perl-5.8.8-2.ppc
    python3-3.9.16-0.ppc
    python3-dnf-4.2.17-32_4.noarch
    python3-gpg-1.13.1-32_3.ppc
    python3-hawkey-0.39.1-32_3.ppc
    python3-libcomps-0.1.15-32_1.ppc
    python3-libdnf-0.39.1-32_3.ppc
    python3-librepo-1.11.0-32_2.ppc
    python3.9-3.9.16-0.ppc
    python3.9-dnf-4.2.17-32_4.noarch
    python3.9-gpg-1.13.1-32_3.ppc
    python3.9-hawkey-0.39.1-32_3.ppc
    python3.9-libcomps-0.1.15-32_1.ppc
    python3.9-libdnf-0.39.1-32_3.ppc
    python3.9-librepo-1.11.0-32_2.ppc
    readline-6.3-5.ppc
    rpm-python3-4.15.1-32_2.ppc
    rpm-python3.9-4.15.1-32_2.ppc
    unzip-6.0-2.ppc
    zchunk-libs-1.1.4-32_2.ppc
    zlib-1.2.4-2.ppc

    Thanks,

        Mike





  • 8.  RE: Just installed dnf on one of our AIX 7.2.5.3 servers, but I'm getting these errors when trying to update

    Posted Wed December 27, 2023 04:01 PM
    Edited by Kolin Vance Wed December 27, 2023 04:03 PM

    Mike,

        Thats why you need to run the remove with the "--nodeps" option, the rpms you're removing will get reinstalled, when you run the dnf install script.  Python is required for dnf to work, but if there is a version already present it will skip over it even if the version dnf is installing is required, you may need to use the "--force" option as well to make sure they are removed...



    ------------------------------
    Kolin Vance
    ------------------------------