Open Source Development

Power Open Source Development

Explore the open source tools and capabilities for building and deploying modern applications on IBM Power platforms including AIX, IBM i, and Linux.


#Power


#Power

 View Only
  • 1.  yum error

    Posted Fri February 02, 2018 12:10 PM

    Originally posted by: BenoitMartin


    Hi,

    I just made a yum update after installing the aix ibm tool box bundle. Everything went well but now I can not use yum anymore.

    Here is the error :

    root@sxtcog0349:/root# yum
    ERROR:root:code for hash md5 was not found.
    Traceback (most recent call last):
      File "/opt/freeware/lib/python2.7/hashlib.py", line 147, in <module>
        globals()[__func_name] = __get_hash(__func_name)
      File "/opt/freeware/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
        raise ValueError('unsupported hash type ' + name)
    ValueError: unsupported hash type md5
    ERROR:root:code for hash sha1 was not found.
    Traceback (most recent call last):
      File "/opt/freeware/lib/python2.7/hashlib.py", line 147, in <module>
        globals()[__func_name] = __get_hash(__func_name)
      File "/opt/freeware/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
        raise ValueError('unsupported hash type ' + name)
    ValueError: unsupported hash type sha1
    ERROR:root:code for hash sha224 was not found.
    Traceback (most recent call last):
      File "/opt/freeware/lib/python2.7/hashlib.py", line 147, in <module>
        globals()[__func_name] = __get_hash(__func_name)
      File "/opt/freeware/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
        raise ValueError('unsupported hash type ' + name)
    ValueError: unsupported hash type sha224
    ERROR:root:code for hash sha256 was not found.
    Traceback (most recent call last):
      File "/opt/freeware/lib/python2.7/hashlib.py", line 147, in <module>
        globals()[__func_name] = __get_hash(__func_name)
      File "/opt/freeware/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
        raise ValueError('unsupported hash type ' + name)
    ValueError: unsupported hash type sha256
    ERROR:root:code for hash sha384 was not found.
    Traceback (most recent call last):
      File "/opt/freeware/lib/python2.7/hashlib.py", line 147, in <module>
        globals()[__func_name] = __get_hash(__func_name)
      File "/opt/freeware/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
        raise ValueError('unsupported hash type ' + name)
    ValueError: unsupported hash type sha384
    ERROR:root:code for hash sha512 was not found.
    Traceback (most recent call last):
      File "/opt/freeware/lib/python2.7/hashlib.py", line 147, in <module>
        globals()[__func_name] = __get_hash(__func_name)
      File "/opt/freeware/lib/python2.7/hashlib.py", line 97, in __get_builtin_constructor
        raise ValueError('unsupported hash type ' + name)
    ValueError: unsupported hash type sha512
    There was a problem importing one of the Python modules
    required to run yum. The error leading to this problem was:

       Could not load module /opt/freeware/lib/python2.7/site-packages/pycurl.so.
            Dependent module /opt/freeware/lib/libcrypto.a(libcrypto.so) could not be loaded.
            Member libcrypto.so is not found in archive 
    Could not load module /opt/freeware/lib/python2.7/site-packages/pycurl.so.
            Dependent module /opt/freeware/lib/python2.7/site-packages/pycurl.so could not be loaded.

    Please install a package which provides this module, or
    verify that the module is installed correctly.

    It's possible that the above module doesn't match the
    current version of Python, which is:
    2.7.13 (default, Oct 17 2017, 05:37:56) [C]

    If you cannot solve this problem yourself, please go to 
    the yum faq at:
      http://yum.baseurl.org/wiki/Faq


    #AIXOpenSource
    #AIX-Open-Source-Software


  • 2.  Re: yum error

    Posted Fri February 02, 2018 12:12 PM

    Originally posted by: BenoitMartin


    root@sxtcog0349:/root# oslevel -s
    7100-04-02-1614

     

     

    root@sxtcog0349:/root# ll /opt/freeware/lib/python2.7/site-packages/pycurl.so 

    -rwxr-xr-x    1 root     system       234995 Jun 13 2016  /opt/freeware/lib/python2.7/site-packages/pycurl.so

     

     

    root@sxtcog0349:/root# ll /opt/freeware/lib/libcrypto.a
    -rw-r--r--    1 root     system     30532253 Jan 27 2017  /opt/freeware/lib/libcrypto.a

     

     

    root@sxtcog0349:/root# ll /opt/freeware/lib/python2.7/hashlib.py
    -rw-r--r--    1 root     system         7842 Oct 17 06:40 /opt/freeware/lib/python2.7/hashlib.py

     

     

    I try to force LIBPATH=/opt/freeware/lib/ or LIBPATH= and I have the same error.

     

    root@sxtcog0349:/root# rpm -qa
    xz-libs-5.2.3-1.ppc
    krb5-libs-1.9.4-1.ppc
    freetype2-2.7.1-1.ppc
    openssl-1.0.2k-1.ppc
    libXrender-0.9.10-1.ppc
    python-pycurl-7.19.3-1.ppc
    AIX-rpm-7.1.4.1-7.ppc
    pkg-config-0.29.1-1.ppc
    libdatrie-0.2.4-1.ppc
    libssh2-1.8.0-1.ppc
    db4-4.8.30-1.ppc
    python-urlgrabber-3.10.1-1.noarch
    libtiff-4.0.3-1.ppc
    libpng-1.6.28-1.ppc
    coreutils-64bit-8.5-2.ppc
    libconfuse-2.6-1.ppc
    sqlite-3.17.0-1.ppc
    bash-4.4-4.ppc
    libgcc-6.3.0-1.ppc
    zlib-1.2.11-1.ppc
    openldap-2.4.45-1.ppc
    ncurses-6.0-1.ppc
    readline-7.0-5.ppc
    nettle-3.2-5.ppc
    glib2-2.52.2-1.ppc
    p11-kit-0.23.2-1.ppc
    libgcrypt-1.5.0-1.ppc
    mpfr-3.1.2-3.ppc
    gnutls-3.5.14-1.ppc
    python-2.7.13-1.ppc
    pysqlite-1.1.7-2.ppc
    cups-libs-2.0.2-2.ppc
    samba-devel-4.6.4-2.ppc
    samba-winbind-clients-4.6.4-2.ppc
    libXdmcp-1.1.2-1.ppc
    libXau-1.0.8-1.ppc
    curl-7.56.1-1.ppc
    jbigkit-2.1-1.ppc
    cups-2.0.2-2.ppc
    python-devel-2.7.13-1.ppc
    gawk-4.1.4-1.ppc
    net-snmp-utils-5.7.3-1.ppc
    tcl-8.6.6-2.ppc
    rsync-3.1.2-2.ppc
    pixman-0.34.0-1.ppc
    fontconfig-2.12.1-1.ppc
    libsigsegv-2.10-1.ppc
    expat-2.2.0-1.ppc
    gmp-6.1.2-1.ppc
    db-4.8.24-3.ppc
    jasper-1.701.0-2.ppc
    libiconv-1.15-1.ppc
    fping-3.10-1.ppc
    libjpeg-9a-1.ppc
    lpar2rrd-agent-5.05-1.ppc
    libcroco-0.6.5-1.ppc
    libidn-1.33-1.ppc
    apr-1.3.3-2.ppc
    libart_lgpl-2.3.21-1.ppc
    libffi-3.2.1-2.ppc
    tk-8.6.6-1.ppc
    libthai-0.1.18-1.ppc
    sqlite-3.7.15.2-2.ppc
    python-iniparse-0.4-1.noarch
    perl-5.24.0-1.ppc
    gettext-0.19.7-1.ppc
    popt-1.16-3.ppc
    libstdc++-6.3.0-1.ppc
    info-6.3-1.ppc
    net-snmp-5.7.3-1.ppc
    libxml2-2.9.5-1.ppc
    yum-metadata-parser-1.1.4-2.ppc
    libgpg-error-1.23-1.ppc
    gdbm-1.12-1.ppc
    libtasn1-4.9-2.ppc
    bzip2-1.0.6-2.ppc
    xcb-proto-1.12-1.ppc
    libpaper-1.1.24-2.ppc
    samba-common-4.6.4-2.ppc
    samba-libs-4.6.4-2.ppc
    samba-winbind-4.6.4-2.ppc
    jbigkit-libs-2.1-1.ppc
    ca-certificates-2016.10.7-2.ppc
    libxcb-1.12-1waixX11.ppc
    samba-winbind-krb5-locator-4.6.4-2.ppc
    yum-3.4.3-6.noarch
    python-tools-2.7.13-1.ppc
    net-snmp-perl-5.7.3-1.ppc
    logrotate-3.8.5-1.ppc
    libXft-2.3.2-2waixX11.ppc
    lzo-2.09-1.ppc
    root@sxtcog0349:/root# 

     

    Thank you!!!

     


    #AIXOpenSource
    #AIX-Open-Source-Software


  • 3.  Re: yum error

    Posted Fri February 02, 2018 12:53 PM

    Originally posted by: AyappanP


    Your openssl is coming from different source. We have compiled our AIX Toolbox packages using openssl fileset which comes with AIX Base.

    You can also download the fileset from AIX web download pack programs -->  https://www-01.ibm.com/marketing/iwm/iwm/web/reg/pick.do?source=aixbp&lang=en_US

    What i suggest here is to remove the openssl rpm and reinstall the openssl fileset (installp/rte format). 


    #AIX-Open-Source-Software
    #AIXOpenSource


  • 4.  Re: yum error

    Posted Fri February 02, 2018 05:25 PM

    Originally posted by: BenoitMartin


    Thank you for openssl. I remove the perlz one and install the right one.

     

    Now I have that error.

     

    root@sxtcog0349:/opt/freeware/etc/yum/repos.d# yum update
    AIX_Toolbox                                                                                                                                                                                                        | 2.9 kB  00:00:00
    Traceback (most recent call last):
      File "/usr/bin/yum", line 29, in <module>
        yummain.user_main(sys.argv[1:], exit_code=True)
      File "/opt/freeware/share/yum-cli/yummain.py", line 288, in user_main
        errcode = main(args)
      File "/opt/freeware/share/yum-cli/yummain.py", line 140, in main
        result, resultmsgs = base.doCommands()
      File "/opt/freeware/share/yum-cli/cli.py", line 436, in doCommands
        self._getTs(needTsRemove)
      File "/opt/freeware/lib/python2.7/site-packages/yum/depsolve.py", line 101, in _getTs
        self._getTsInfo(remove_only)
      File "/opt/freeware/lib/python2.7/site-packages/yum/depsolve.py", line 112, in _getTsInfo
        pkgSack = self.pkgSack
      File "/opt/freeware/lib/python2.7/site-packages/yum/__init__.py", line 900, in <lambda>
        pkgSack = property(fget=lambda self: self._getSacks(),
      File "/opt/freeware/lib/python2.7/site-packages/yum/__init__.py", line 681, in _getSacks
        self.repos.populateSack(which=repos)
      File "/opt/freeware/lib/python2.7/site-packages/yum/repos.py", line 294, in populateSack
        sack.populate(repo, mdtype, callback, cacheonly)
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 164, in populate
        if self._check_db_version(repo, mydbtype):
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 222, in _check_db_version
        return repo._check_db_version(mdtype)
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1264, in _check_db_version
        repoXML = self.repoXML
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1463, in <lambda>
        repoXML = property(fget=lambda self: self._getRepoXML(),
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1455, in _getRepoXML
        self._loadRepoXML(text=self)
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1445, in _loadRepoXML
        return self._groupLoadRepoXML(text, self._mdpolicy2mdtypes())
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1420, in _groupLoadRepoXML
        if self._commonLoadRepoXML(text):
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1238, in _commonLoadRepoXML
        result = self._getFileRepoXML(local, text)
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1016, in _getFileRepoXML
        size=102400) # setting max size as 100K
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 838, in _getFile
        size=size
      File "/opt/freeware/lib/python2.7/site-packages/urlgrabber/mirror.py", line 448, in urlgrab
        return self._mirror_try(func, url, kw)
      File "/opt/freeware/lib/python2.7/site-packages/urlgrabber/mirror.py", line 425, in _mirror_try
        return func_ref( *(fullurl,), opts=opts, **kw )
      File "/opt/freeware/lib/python2.7/site-packages/urlgrabber/grabber.py", line 1172, in urlgrab
        return self._retry(opts, retryfunc, url, filename)
      File "/opt/freeware/lib/python2.7/site-packages/urlgrabber/grabber.py", line 1064, in _retry
        r = apply(func, (opts,) + args, {})
      File "/opt/freeware/lib/python2.7/site-packages/urlgrabber/grabber.py", line 1166, in retryfunc
        _run_callback(opts.checkfunc, obj)
      File "/opt/freeware/lib/python2.7/site-packages/urlgrabber/grabber.py", line 1032, in _run_callback
        return cb(obj, *arg, **karg)
      File "/opt/freeware/lib/python2.7/site-packages/yum/yumRepo.py", line 1502, in _checkRepoXML
        repoXML = repoMDObject.RepoMD(self.id, filepath)
      File "/opt/freeware/lib/python2.7/site-packages/yum/repoMDObject.py", line 124, in __init__
        self.parse(srcfile)
      File "/opt/freeware/lib/python2.7/site-packages/yum/repoMDObject.py", line 140, in parse
        parser = iterparse(infile)
      File "/opt/freeware/lib/python2.7/site-packages/yum/misc.py", line 1188, in cElementTree_iterparse
        _cElementTree_import()
      File "/opt/freeware/lib/python2.7/site-packages/yum/misc.py", line 1183, in _cElementTree_import
        import cElementTree
    ImportError: No module named cElementTree
    root@sxtcog0349:/opt/freeware/etc/yum/repos.d#

     

     

    Thanks a lot for your help. We try to switch from perlz to aix tool box.


    #AIX-Open-Source-Software
    #AIXOpenSource


  • 5.  Re: yum error

    Posted Fri February 02, 2018 09:57 PM

    Originally posted by: sangameshm


    Hi Benoit,

    I think something went wrong with python modules.

    Code which fails is

     

     +1180          try:
     +1181              from xml.etree import cElementTree
     +1182          except ImportError:
     +1183              import cElementTree
     +1184          __cached_cElementTree = cElementTree

     

    Looks like import of xml.etree is failing in your case.

    You can try these commands to verify.

     

    # python -c 'import xml.etree'
    # python -c 'import xml.etree.cElementTree'
    # python -c 'import cElementTree'
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
    ImportError: No module named cElementTree

     

    Thanks,

    Sangamesh

     

     


    #AIXOpenSource
    #AIX-Open-Source-Software


  • 6.  Re: yum error

    Posted Mon February 05, 2018 08:56 AM

    Originally posted by: BenoitMartin


    root@sxtcog0349:/root# python
    Python 2.7.13 (default, Oct 17 2017, 05:37:56) [C] on aix6
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import xml.etree
    >>> import xml.etree.cElementTree
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/opt/freeware/lib/python2.7/xml/etree/cElementTree.py", line 3, in <module>
        from _elementtree import *
    ImportError: PyCapsule_Import could not import module "pyexpat"
    >>> import cElementTree
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
    ImportError: No module named cElementTree

     


    #AIXOpenSource
    #AIX-Open-Source-Software


  • 7.  Re: yum error

    Posted Mon February 05, 2018 09:35 AM

    Originally posted by: BenoitMartin


    I find a way to find all the perzl package I have on my system. I have to find a way to replace it by ibmtoolbox package. Do you have a list of important package please. The one I cannot use from other repo.

     

    The library is available as 32-bit and 64-bit.
    Name : expat
    Version : 2.2.0
    Release : 1
    Architecture: ppc
    Install Date: Thu Jun 8 09:54:55 2017
    Group : System Environment/Libraries
    Size : 1390647
    License : MIT
    Signature : (none)
    Source RPM : expat-2.2.0-1.src.rpm
    Build Date : Wed Nov 16 17:36:33 2016
    Build Host : aix51.perzl.org
    Relocations : (not relocatable)
    URL : http://www.libexpat.org/
    Summary : An XML parser library
    Description :
    This is expat, the C library for parsing XML, written by James Clark. Expa
    is a stream oriented XML parser. This means that you register handlers with
    the parser prior to starting the parse. These handlers are called when the
    parser discovers the associated structures in the document being parsed. A
    start tag is an example of the kind of structures for which you may
    register handlers.


    #AIX-Open-Source-Software
    #AIXOpenSource


  • 8.  Re: yum error

    Posted Mon February 05, 2018 10:07 AM

    Originally posted by: AyappanP


    Libiconv is the other one to watch out that usually creates conflict. So better to avoid it.

    Libiconv comes with AIX Base OS so we won't ship it in AIX Toolbox.


    #AIXOpenSource
    #AIX-Open-Source-Software