AIX: upgrade to using Linux Tool Box packages via yum

Follow it if you have already installed oldc rpm package of RRDTool and Apache to the one using yum (Linux Tool Box)
It is typically when you have rrdtool 1.4.8 and Apache like 2.4.18.
To upgrade to the latest version,
  1. Remove nearly all existing packages, in our test example it was:
    rpm --nodeps -e libjpeg expat libiconv openssl zlib freetype2 gettext libdatrie libthai libXrender fontconfig libffi glib2 libpng libxcb xz libxml2 libcroco libart_lgpl lzo pixman atk jasper jbigkit jbigkit-libs libtiff gtk2 librsvg2 cairo pango gtk2 libdbi dejavu-sans-mono-fonts dejavu--lgc-sans-mono-fonts gdbm perl perl-TimeDate perl-XML-Simple perl-XML-Parser perl-URI perl-XML-SAX perl-XML-LibXML perl-XML-SAX-Base perl-XML-NamespaceSupport net-snmp-util net-snmp-perl perl-DBI dejavu-lgc-sans-mono-fonts perl-Net_SSLeay.pm xz-libs perl-Compress-Raw-Zlib net-snmp-utils unzip info gtk2-immodules db tcl net-snmp-utils ncurses libXpm pcre expect perl-DBD-Pg sudo libgcc perl-Want postgresql-libs lemon gts graphviz xorg-compat-aix python python-iniparse ca-certificates python-pycurl python-tools gettext gdbm tk gd wget perl-IO-Tty httpd sqlite net-snmp bzip2 perl-DBD-SQLite swig perl-Crypt-SSLeay vnc pkg-config readline lua pysqlite curl python-urlgrabber python-devel glib2
    
    But it might vary in different environments, basically here is what could stay there:
    rpm -qa
      lpar2rrd-agent-7.20-5.ppc
      yum-3.4.3-8.noarch
      AIX-rpm-7.1.4.30-4.ppc
      bash-3.0-1.ppc
      yum-metadata-parser-1.1.4-2.ppc
    
  2. Activate yum as per IBM procedure, download "yum.sh" and run it, then run this:
    updtvpkg
    
  3. Install as per AIX yum install
    yum install httpd rrdtool rrdtool-perl
    yum install net-snmp net-snmp-utils net-snmp-perl
    
  4. Make sure installated package is working, it should not proint any error (rrdtool 1.7.2 might print an error, check Troubleshooting section)
    /opt/freeware/bin/rrdtool_32 -v
    /opt/freeware/bin/rrdtool -v
    
  5. Apache configuration, append into /opt/freeware/etc/httpd/conf/httpd.conf this:
    vi /opt/freeware/etc/httpd/conf/httpd.conf
    
    # LPAR2RRD
    LoadModule cgi_module /opt/freeware/lib/httpd/modules/mod_cgi.so
    Alias /lpar2rrd  "/home/lpar2rrd/lpar2rrd/www/"
    <Directory "/home/lpar2rrd/lpar2rrd/www/">
        Options Indexes FollowSymLinks Includes MultiViews
        Require all granted
    </Directory>
    
    # CGI-BIN
    ScriptAlias /lpar2rrd-cgi/ "/home/lpar2rrd/lpar2rrd/lpar2rrd-cgi/"
    <Directory "/home/lpar2rrd/lpar2rrd/lpar2rrd-cgi">
        AllowOverride None
        SetHandler cgi-script
        Options ExecCGI Includes FollowSymLinks
        Require all granted
    </Directory>
    
    
    # STOR2RRD
    Alias /stor2rrd  "/home/stor2rrd/stor2rrd/www/"
    <Directory "/home/stor2rrd/stor2rrd/www/">
        Options Indexes FollowSymLinks Includes MultiViews
        Require all granted
    </Directory>
    
    # CGI-BIN
    ScriptAlias /stor2rrd-cgi/ "/home/stor2rrd/stor2rrd/stor2rrd-cgi/"
    <Directory "/home/stor2rrd/stor2rrd/stor2rrd-cgi">
        AllowOverride None
        SetHandler cgi-script
        Options ExecCGI Includes FollowSymLinks
        Require all granted
    </Directory>
    
    Apache restart:
    /opt/freeware/sbin/apachectl restart
    
  6. Change LPAR2RRD/STOR2RRD parameters:
    LPAR2RRD: edit /home/lpar2rrd/lpar2rrd/etc/lpar2rrd.cfg
    PERL=/usr/bin/perl
    PERL5LIB=/home/lpar2rrd/lpar2rrd/bin:/home/lpar2rrd/lpar2rrd/vmware-lib:/home/lpar2rrd/lpar2rrd/lib:/opt/freeware/lib/perl5/5.30/vendor_perl:/opt/freeware/lib64/perl5/5.30/vendor_perl
    RRDTOOL=/opt/freeware/bin/rrdtool_32
    
    STOR2RRD: edit /home/stor2rrd/stor2rrd/etc/stor2rrd.cfg
    PERL=/usr/bin/perl
    PERL5LIB=/home/stor2rrd/stor2rrd/bin:/home/stor2rrd/stor2rrd/lib:/opt/freeware/lib/perl5/5.30/vendor_perl:/opt/freeware/lib64/perl5/5.30/vendor_perl
    RRDTOOL=/opt/freeware/bin/rrdtool_32
    

Troubleshooting

  • RRDTOOL 1.7.2 problem (only 32bit one)
    /opt/freeware/bin/rrdtool_32 -v
      exec(): 0509-036 Cannot load program /opt/freeware/bin/rrdtool_32 because of the following errors:
      0509-130 Symbol resolution failed for /opt/freeware/lib/libpangocairo-1.0.a(libpangocairo-1.0.so.0) because:
      0509-136 Symbol __dbargs (number 185) is not exported from
      dependent module /opt/freeware/lib/libpixman-1.a(libpixman-1.so.0).
      0509-136 Symbol __dbsubc (number 186) is not exported from
      dependent module /opt/freeware/lib/libpixman-1.a(libpixman-1.so.0).
      0509-136 Symbol __dbsubg (number 187) is not exported from
      dependent module /opt/freeware/lib/libpixman-1.a(libpixman-1.so.0).
      0509-136 Symbol __dbsubn (number 188) is not exported from
      dependent module /opt/freeware/lib/libpixman-1.a(libpixman-1.so.0).
      0509-192 Examine .loader section symbols with the
      'dump -Tv' command.
    
    Fix it by removing "pixman" package, ignore dependencies
    yum erase pixman