Softpanorama
May the source be with you, but remember the KISS principle ;-)

Contents Bulletin Scripting in shell and Perl Network troubleshooting History Humor

Compiling Apache 2.2.8 on AIX

News

Open Source packages for AIX

Redbooks Recommended Links GCC on AIX Compilation of open source on AIX
aix toolbox Apache+PHP on AIX Compiling Apache 1.3 on AIX Humor Etc

There are two ways to install Apache on AIX:

The description below is adapted from IBM Wikis - AIX 5L Wiki - aixopen

Precompiled versions of apache for AIX

Precompiled binaries of Apache for AIX if available from several sources. RPM packages are probably the best choice and are available from several sources:

AIX 5L Open Source Packages Main - Apache lists dependencies for Apache:

Source RPM:

Package dependencies:

Compiling Apache 2.2.8 on AIX

By A default AIX 5.3 ML 03 is "Apache-friendly": the the only additional package the Apache requires is libgcc.

  1. Make sure you have a few hundred MB of free space in following places
  2. Download
  3. Install the gcc compiler and libgcc library as the root user
    rpm -Uvh gcc-4*.rpm
    rpm -Uvh libgcc-4*rpm
  4. Uncompress the Apache Web Server source
    gunzip -c <  httpd-2.2.8.tar.gz  | tar xvf - 
  5. Add /opt/freeware/bin to the PATH

    export PATH=/opt/freeware/bin:$PATH

  6. Run the configure script (it take approximately 20 min on a reasonably powerful server):

    Compilation with LDAP libraries

    1. export PATH=/opt/freeware/bin:$PATH
    2. ./configure -C --prefix=/usr/local/apache2 \
      --enable-so --enable-info\
      --with-ldap \
      --enable-ldap=static \
      --enable-authnz-ldap=static

    Or in a single line

    ./configure -C --enable-so --enable-info --prefix /usr/local/apache2 -with-ldap=yes --enable-ldap=static --enable-authnz-ldap=static  
     
  7. Compile Apache2 by typing (as a regular AIX user):
    make
  8. Install Apache2 - all the important stuff will be in /usr/local/apache2. Type as the root user:
    make install
  9. If it all goes wrong, you can run "make clean" to start again from point 6.

Configuring Apache2+ on AIX

Assuming you have just compiled and installed Apache2+ as in the above section, you need several steps to configure Apache on AIX:

  1. You will need to make at least one modification to the Apache config file before you start it: change the line "User daemon" to "User nobody" and the line "Group daemon" to "Group nobody".
    vi /usr/local/apache2/conf/httpd.conf
  2. Test the Apache2 configuration
    /usr/local/apache2/bin/apachectl -t
  3. Start Apache2
    /usr/local/apache2/bin/apachectl -k start
  4. Point your browser at http:/your-machine-dns-name and you should be informed that it is working (Apache will load the test page that comes with the installation).

Configuring Apache2.2.8 on AIX - For Production Use

Note: the default web pages directory (/usr/local/apache2/htdocs) is not a good location as you risk filling up the /usr filesystem. this is what I recommend as a minimum of changes to the default Apache configuration:

Below we assume you will use default /usr/local/apache2/htdocs for some quick testing and will set up the alternative filesystem later on but don't forget.

NEWS CONTENTS

Old News

[Jul 29, 2013]  Open Source Bootstrap on AIX = RPM dependencies from hell Fixed (AIXpert Blog)

May 2

Installing Open Source on AIX  systems can be a little .... um .... frustrating and I have just been round that loop with installing Ganglia the excellent Performance Monitoring tool to demonstrate it and actually use it too on my own servers.  The hard bit is that for every Open Source program, that you want to install, there is 10 to 20 prerequisite packages that you need to install first and you go round this the loop four times as the prerequisites have prerequisites ....  This has got known as the "RPM dependencies form hell" problem.

So here is what to do: Download the AIX Toolbox version of wget as this version has no prerequisites - phew! This will act as our RPM fetching tool.

  1. Browse to http://www.ibm.com/systems/power/software/aix/linux/toolbox/alpha.html
  2. Search for wget
  3. Click the RPM link (assuming your lawyer approves)
  4. And it downloads the file:  wget-1.9.1-1.aix5.1.ppc.rpm
  5. Move this to your repository or home AIX machine on which you can as root install this package.
  6. Run: rpm -Uvh wget-1.9.1-1.aix5.1.ppc.rpm

Now the excellent techie Michael Perzl (who works hard on behalf of all AIX people wanting up to date Open Source packages) has come up with a way to list dependencies so you can download them all quickly (with wget) and then simply run one rpm command to install them all. He also compiles 100's of Open Source packages for us all and makes them available from his personal website. You can read more about this at Michael's website http://www.perzl.org/aix/index.php?n=FAQs.FAQs#rpm-dependency-hell and from here you can get the FTP list of dependency files.

 Note: The below websites are not from IBM and IBM takes no responsibility for them

In the below we use, as an example, the Apache 2.4 webserver. When writing this Apache 2.4.3 is the latest version - that will change with time.

  1. Find the dependencies file for Apache 2.4
    1. Browse to http://www.oss4aix.org/download/rpmdb/deplists/aix71/ (this is for AIX 7.1 - for AIX 6.1 it end in 61)
    2. Search for httpd - that is the package name for Apache (it is historic too).
    3. Download the dependency list file: httpd-2.4.3-1.aix5.1.ppc.deps - if you do this on your workstation, copy the .deps file to your AIX machine in a new directory or as it is small you can even cut'n'paste it in to your AIX terminal emulation window like Putty.
       
  2. Download Apache and everything it needs using wget
    1. Apache with:          wget     ftp://www.oss4aix.org/everything/RPMS/httpd-2.4.3-1.aix5.1.ppc.rpm
    2. Prerequisites with: wget -B ftp://www.oss4aix.org/everything/RPMS/  -i httpd-2.4.3-1.aix5.1.ppc.deps
      - this reads the .deps file for all the files to download
       
  3. Install Apache and everything it needs:
    • rpm -Uvh *.rpm

Job done - Michael, you are a genius.

For Ganglia, I did the same for adding other things it needs:

For Ganglia itself - it is back to Michael Perzl's website http://www.perzl.org  He has it compiled for AIX and actually developed all the POWER / AIX & Linux add-ons for Ganglia and has them ready for downloading and installing - perhaps more of that in another blog.

Runtime definitions missing for 2.2.8 on AIX 5.3 Apache Users

On Thu, Feb 14, 2008 at 10:30 AM, O'DELL, TODD E (ATTOPS)
<to2958[at]att.com> wrote:
> I'm able to build the 2.2.8 Apache on a AIX 5.3 server. It will compile
> and install but when I go to start it I get this:
>
> exec(): 0509-036 Cannot load program httpd because of the following
> errors:
> rtld: 0712-001 Symbol XML_ParserFree was referenced
> from module /web/apache/production/lib/libaprutil-1.so(), but a
> runtime definition
> of the symbol was not found.

ISTR a problem with libtool on AIX where the relinkde/installed
version of apr-util has a hard-coded reference to expat that cannot be
overridden by LIBPATH. This should only affect running the Apache code
on a different system, as the hard-coded path ought to at least be
correct.

You might want to try temporarily using the apr-util libs from
srclib/apr-util/.libs/ instead of the ones re-linked by libtool, and
see if it helps at all.

You might also want to try picking up a newer libtool and re-building.

Bug 40765 – library libgcc_s_pthread not found

------- Comment #1 From Neal Daskal 2006-10-16 10:41:36 PST -------
libgcc rpm was missing - why didn't ./configure pick this up?
------- Comment #2 From Joe Orton 2006-10-17 01:08:30 PST -------
configure never attempts to link a shared library.  This is a system
configuration issue.

Error when compile httpd 2.2.8 on AIX 5.2 - The UNIX Forums

Originally Posted by aldowsary

collect2: library libgcc_s_pthread not found

seems to be the root of all evil. Maybe a wrongly set LIBPATH or missing library at all? There is a library libpthread.so in AIX 5.3, but you seem to need an equivalent library for the gcc compiler.

TekWire.Net - Building Apache & PHP on AIX 5.2

21 December 2006

Compiling Apache2 and PHP 5.1 on AIX

July 9th, 2006 | FASherman

This build was accomplished on AIX 5.3 ML 03 with no IBM compilers installed. I highly recommend building and installing Apache 2 and PHP 5.1 together. Performing these separately can have unpredicted results.

Prerequisites

  1. Make sure you have the necessary free space in the following filesystems:
    • /usr
    • /opt
    • /home
    • /tmp
  2. Download the following:
  3. Install libm.a from the AIX CDROM
  4. Install the compiler and library

    rpm -Uvh gcc-4*.rpm
    rpm -Uvh libgcc-4*rpm
Compiling Apache2+ using GCC
  1. Uncompress the Apache Web Server source into your home directory

    # gunzip httpd-2*tar.gz
    # tar xvf httpd-2*.tar
    # cd httpd*

  2. Build the configuration file enabling shared object

    # ./configure -C --enable-so --prefix /usr/local/apache2

  3. Compile the server

    # make

  4. Install the server (/usr/local/apache2)
# make install
Compiling PHP using GCC
  1. Uncompress the PHP source code file and untar the file

    # gunzip php*tar.gz
    # tar xvf php*.tar
    # cd php-5.1.4

  2. Build the configuration file enabling shared objects

    # export PATH=/opt/freeware/bin:$PATH
    # ./configure --prefix=/usr/local --with-apxs2=/usr/local/apache2/bin/apxs --with-config-file-path=/usr/local/apache2/conf --with-gd --with-pear --with-gettext --with-mime-magic --with-zlib-dir=/opt/freeware/lib --enable-shared --disable-static --with-png --with-zlib --with-bz2 --with-xml --with-jpeg-dir=/opt/freeware/lib --with-png-dir=/opt/freeware/lib --with-xpm-dir=/opt/freeware/lib --with-freetype-dir=/opt/freeware/lib

  3. Compile PHP with the following command:

    # make

    NOTE: There will be compiler warnings about pointers type mismatches. The can be disregarded.

  4. Install PHP with the following two commands
# cp .libs/libphp5.so /usr/local/apache2/modules
# cp php.ini-recommended /usr/local/apache2/conf/php.ini

Configuring Apache2 with PHP
  1. Stop Apache2

    # /usr/local/apache2/bin/apachectl -k stop

  2. Edit /usr/local/apache2/conf/httpd.conf, adding the following at the end

    LoadModule php5_module modules/libphp5.so
    AddType application/x-httpd-php .php
    DirectoryIndex index.php

  3. Edit the /usr/local/apache2/conf/php.ini file

    Change the php variable:
    ;date.timezone =
    to reflect your timezone

  4. Restart Apache2

    # /usr/local/apache2/bin/apachectl -k start

  5. Now test PHP with Apache2
    • Create a test web page

      # vi /usr/local/apache2/htdocs/phpinfo.php

      <h1> PHP testing </h1>
      <?PHP phpinfo() ?>

    • Open the page in your browser: http://your_server/phpinfo.php
    • Verify the php data
    • Delete phpinfo.php

      # rm /usr/local/apache2/htdocs/phpinfo.php

hints on Apache 2 and PHP on AIX

IBM Wikis - AIX 5L Wiki - aixopen

This Wiki page contains the following sections:

Recommended Links

Softpanorama Top Visited

Softpanorama Recommended




Etc

FAIR USE NOTICE This site contains copyrighted material the use of which has not always been specifically authorized by the copyright owner. We are making such material available in our efforts to advance understanding of environmental, political, human rights, economic, democracy, scientific, and social justice issues, etc. We believe this constitutes a 'fair use' of any such copyrighted material as provided for in section 107 of the US Copyright Law. In accordance with Title 17 U.S.C. Section 107, the material on this site is distributed without profit exclusivly for research and educational purposes.   If you wish to use copyrighted material from this site for purposes of your own that go beyond 'fair use', you must obtain permission from the copyright owner.

Society

Groupthink : Two Party System as Polyarchy : Corruption of Regulators : Bureaucracies : Understanding Micromanagers and Control Freaks : Toxic Managers :   Harvard Mafia : Diplomatic Communication : Surviving a Bad Performance Review : Insufficient Retirement Funds as Immanent Problem of Neoliberal Regime : PseudoScience : Who Rules America : Neoliberalism  : The Iron Law of Oligarchy : Libertarian Philosophy

Quotes

War and Peace : Skeptical Finance : John Kenneth Galbraith :Talleyrand : Oscar Wilde : Otto Von Bismarck : Keynes : George Carlin : Skeptics : Propaganda  : SE quotes : Language Design and Programming Quotes : Random IT-related quotesSomerset Maugham : Marcus Aurelius : Kurt Vonnegut : Eric Hoffer : Winston Churchill : Napoleon Bonaparte : Ambrose BierceBernard Shaw : Mark Twain Quotes

Bulletin:

Vol 25, No.12 (December, 2013) Rational Fools vs. Efficient Crooks The efficient markets hypothesis : Political Skeptic Bulletin, 2013 : Unemployment Bulletin, 2010 :  Vol 23, No.10 (October, 2011) An observation about corporate security departments : Slightly Skeptical Euromaydan Chronicles, June 2014 : Greenspan legacy bulletin, 2008 : Vol 25, No.10 (October, 2013) Cryptolocker Trojan (Win32/Crilock.A) : Vol 25, No.08 (August, 2013) Cloud providers as intelligence collection hubs : Financial Humor Bulletin, 2010 : Inequality Bulletin, 2009 : Financial Humor Bulletin, 2008 : Copyleft Problems Bulletin, 2004 : Financial Humor Bulletin, 2011 : Energy Bulletin, 2010 : Malware Protection Bulletin, 2010 : Vol 26, No.1 (January, 2013) Object-Oriented Cult : Political Skeptic Bulletin, 2011 : Vol 23, No.11 (November, 2011) Softpanorama classification of sysadmin horror stories : Vol 25, No.05 (May, 2013) Corporate bullshit as a communication method  : Vol 25, No.06 (June, 2013) A Note on the Relationship of Brooks Law and Conway Law

History:

Fifty glorious years (1950-2000): the triumph of the US computer engineering : Donald Knuth : TAoCP and its Influence of Computer Science : Richard Stallman : Linus Torvalds  : Larry Wall  : John K. Ousterhout : CTSS : Multix OS Unix History : Unix shell history : VI editor : History of pipes concept : Solaris : MS DOSProgramming Languages History : PL/1 : Simula 67 : C : History of GCC developmentScripting Languages : Perl history   : OS History : Mail : DNS : SSH : CPU Instruction Sets : SPARC systems 1987-2006 : Norton Commander : Norton Utilities : Norton Ghost : Frontpage history : Malware Defense History : GNU Screen : OSS early history

Classic books:

The Peter Principle : Parkinson Law : 1984 : The Mythical Man-MonthHow to Solve It by George Polya : The Art of Computer Programming : The Elements of Programming Style : The Unix Hater’s Handbook : The Jargon file : The True Believer : Programming Pearls : The Good Soldier Svejk : The Power Elite

Most popular humor pages:

Manifest of the Softpanorama IT Slacker Society : Ten Commandments of the IT Slackers Society : Computer Humor Collection : BSD Logo Story : The Cuckoo's Egg : IT Slang : C++ Humor : ARE YOU A BBS ADDICT? : The Perl Purity Test : Object oriented programmers of all nations : Financial Humor : Financial Humor Bulletin, 2008 : Financial Humor Bulletin, 2010 : The Most Comprehensive Collection of Editor-related Humor : Programming Language Humor : Goldman Sachs related humor : Greenspan humor : C Humor : Scripting Humor : Real Programmers Humor : Web Humor : GPL-related Humor : OFM Humor : Politically Incorrect Humor : IDS Humor : "Linux Sucks" Humor : Russian Musical Humor : Best Russian Programmer Humor : Microsoft plans to buy Catholic Church : Richard Stallman Related Humor : Admin Humor : Perl-related Humor : Linus Torvalds Related humor : PseudoScience Related Humor : Networking Humor : Shell Humor : Financial Humor Bulletin, 2011 : Financial Humor Bulletin, 2012 : Financial Humor Bulletin, 2013 : Java Humor : Software Engineering Humor : Sun Solaris Related Humor : Education Humor : IBM Humor : Assembler-related Humor : VIM Humor : Computer Viruses Humor : Bright tomorrow is rescheduled to a day after tomorrow : Classic Computer Humor

The Last but not Least


Copyright © 1996-2014 by Dr. Nikolai Bezroukov. www.softpanorama.org was created as a service to the UN Sustainable Development Networking Programme (SDNP) in the author free time. This document is an industrial compilation designed and created exclusively for educational use and is distributed under the Softpanorama Content License. Site uses AdSense so you need to be aware of Google privacy policy. Original materials copyright belong to respective owners. Quotes are made for educational purposes only in compliance with the fair use doctrine.

FAIR USE NOTICE This site contains copyrighted material the use of which has not always been specifically authorized by the copyright owner. We are making such material available to advance understanding of computer science, IT technology, economic, scientific, and social issues. We believe this constitutes a 'fair use' of any such copyrighted material as provided by section 107 of the US Copyright Law according to which such material can be distributed without profit exclusively for research and educational purposes.

This is a Spartan WHYFF (We Help You For Free) site written by people for whom English is not a native language. Grammar and spelling errors should be expected. The site contain some broken links as it develops like a living tree...

You can use PayPal to make a contribution, supporting hosting of this site with different providers to distribute and speed up access. Currently there are two functional mirrors: softpanorama.info (the fastest) and softpanorama.net.

Disclaimer:

The statements, views and opinions presented on this web page are those of the author and are not endorsed by, nor do they necessarily reflect, the opinions of the author present and former employers, SDNP or any other organization the author may be associated with. We do not warrant the correctness of the information provided or its fitness for any purpose.

Last modified: February 19, 2014