AIX 6.1Apache 2.2.11 + PHP 5.1.6 installation help
So I am not very experienced with this OS.. well that is a misleading statement.. I actually have never used AIX before
I have not really installed apache and php before from src . I have gotten all my pre-requisite packages installed for apache and php .. got GCC installed now I need help getting apache 2.2.11 and PHP 5.1.6+ installed. even a push in the right direction. (needed apache modules = mod_rewrite) (needed php modules = soap and PECL/SSH2) All help is greatly appreciated. -Thank you [Voltxion] |
I assume you have download the apache server and php. i will be using y own version of apache and php.
For apache: Code:
cd to the directory where the installer resides Code:
./configure --prefix = /usr/local/apache2 Code:
/usr/local/apache2/bin/apachectl -k start You can find them by using this directory path: cd /usr/local/apache2/includes You can find the file in that directory As For Php Untar the php directory Code:
tar jxvf <name_of_php_directory.tar.bz2> Code:
./configure --prefix=/usr/local/php --with-apxs2=/usr/local/apache2/bin/apxs Code:
cp php.ini-recommended /usr/local/php/lib/php.ini doc_root="/usr/local/apache2/htdocs/" pecl i think can be found in the php bin directory. These are the steps i use to install. Hope you can install without any problems too. :) |
this is the error I get when I do Make install for php
Quote:
|
Well I gave up since I can't figure out how to change the default loader to the GNU loader and the buildtools to GNU ones so I ended up using this bundle ftp://ftp.hvcc.edu/pub/pware/aix53/bundles/amp I found it through IBMs website for AIX.
|
I figured this out. Dumbest thing I've ever seen.
Installing PHP SAPI module: apache2handler /usr/local/apache2/build/instdso.sh SH_LIBTOOL='/usr/local/apache2/build/libtool' libphp5.la /usr/local/apache2/modules rm -f /usr/local/apache2/modules/libphp5.so /usr/local/apache2/build/libtool --mode=install cp libphp5.la /usr/local/apache2/modules/ cp .libs/libphp5.a /usr/local/apache2/modules/libphp5.a cp .libs/libphp5.lai /usr/local/apache2/modules/libphp5.la libtool: install: warning: remember to run `libtool --finish /usr/sys/inst.images/php/php-5.3.0/libs' chmod 755 /usr/local/apache2/modules/libphp5.so chmod: /usr/local/apache2/modules/libphp5.so: A file or directory in the path name does not exist. apxs:Error: Command failed with rc=65536 It can't find libphp5.so because the first thing the 'make install' did was rm -f the exact file it needs to continue. The file it's deleting actually exists on the system in a different directory. In my case it was the directory I did the initial 'make' in. So the solution I used was to open two sessions. In the first session type out the cp command that copies the original file to the /usr/local/apache2/modules directory, DON'T hit the enter key. Example: cp /usr/sys/inst.images/php/php-5.3.0/.libs/libphp5.so /usr/local/apache2/modules/ Next, in the second session, run the 'make install'. Right away, click back to your first session and hit 'enter' to copy it back just after the Makefile does and rm -f on the libphp5.so file. Timing is everything, so it may take a couple tries. Your just recopying the the libphp5 file back to where the Makefile is looking for it so it can continue. It had to be done while your 'make install' is running. Stupidest thing I've ever seen in a compile, but this hack job works and it managed to finish successfully. Good luck :) |
required the actual output and test PHP
hi i have configured PHP and make make test was success , But durin make insatll getting the below error and while creation of PDO headers the insatllation is getting stoped and coming back to the folder ,
I m not sure wheather this installation was success or no and there is not error message also , can any one help on this And also can any one let me knwo how to test this installation success ? PHPH installed was : 5.4.16 $ make install Installing PHP CLI binary: /opt/Programs/PHP//bin/ Installing PHP CLI man page: /opt/Programs/PHP//php/man/man1/ Installing PHP CGI binary: /opt/Programs/PHP//bin/ Installing build environment: /opt/Programs/PHP//lib/php/build/ Installing header files: /opt/Programs/PHP//include/php/ Installing helper programs: /opt/Programs/PHP//bin/ Installing man pages: /opt/Programs/PHP//php/man/man1/ page: phpize.1 page: php-config.1 Installing PDO headers: /opt/Programs/PHP//include/php/ext/pdo |
And where is the error message? This is how 'make install' ends.
Try this too (you should see current dates): Code:
ls -l /usr/local/bin/php /usr/local/libexec/apache2/libphp5.* \ |
Thanks for your kind reply friend , then my install is success :)
I am struck with one more issue i.e presentely i am working on non-root access and I had install my apache and php, but i could not see the libphp5.so file in my apache modules folder not sure during wt phase this files gets genrated , is there any way to get package where i can insatll and copy this libphp5.so file can you provide me the link or some suggestions like when can i get this libphp5.so loaded ? Thanks in advance |
If you didn't specify something like LDFLAGS=-Wl,-brtl you most likely got a file called libphp5.a containing the shared object. That might be quite okay, or you might want to try to extract the shared object from it. (Use 'ar' or Midnight Commander)
Hopefully, you have a logfile of the make-process (eg: (make all && make install) 2>&1 | tee log.make), so you can search in it for 'libphp5.la' or 'Installing PHP SAPI module' or 'libexec/apache2' |
I have been very frustrated with packaging for AIX, and I have never quite finished the php build. This has always been a difficult one. Reading this makes me think it may be time to start again.
The projects I have done (e.g., apache 2.2.22 and 23 and 2.4.3 and 2.4.4) and, perhaps needed for the make install of php - is the coreutils install version. There are, subtle, and unknown differences in the installs. I have experimented with having /usr/ucb earlier in the path that /usr/bin to get ucb install. That has also worked in some instances. I am sure the IBM one is standards compliant - and GNU packaging seems to have their own standard - hence the need for another install program. btw - the logic for remove of the file is because if the file is active you cannot copy over it. using slibclean should have been enough - but that was a hack someone thought of YEARS ago. Very very hard to get it changed. Ah yes. If you are curious, my packages can be found via http://dl.aixtools.net |
seems i broke my virtual host entry, so the downloads are offline til i get home. my apologies.
|
Quote:
The last time I did this, was for PHP version 5.3.10, but I'm not aware of major changes in the process. If the above outout is all you saw from "make install", it doesn't look like the Apache module was installed. I got messages specific to libphp5.so before the "Installing PHP CLI binary" above, similar to this: Code:
and rerun make install. Can you post the "configure" command options you used? That might help us understand the setup. In particular, did you use an "--with-apxs2" option? As an aside, one alternate option might be to use Michael Perzl's PHP & Apache packages. I've switched from going through this pain myself to using his packages, and am running it happily on a number of servers. See http://www.perzl.org/aix/index.php?n=Main.Php. You'll need root access to install this, though. Good luck! |
From my point of view the root of all these problems is AIX's tradition to put shared objects into *.a acrhives. Everyday Unices don't do that, so programs like PHP aren't really prepared for it. I usually do every compilation from a script sg like this:
Code:
#!/bin/sh |
From my point of view, .a archives are normal (since 1978!). The .so naming convention for something that was already working using ranlib was just something new/different. Maybe there is something else different as well.
However, as far as AIX and archives are concerned - the issue is not really the file extension, except where applications demand it. Frequently hard and/or soft links are used to link .so and .a archives. The more important element is the name of the object in the archive - and when .so is again demanded, rather than .o, run-time linking may fail. The command to know - on AIX - is Quote:
|
Well, if you didn't experience problems when compiling PHP, you certainly shouldn't change anything.
|
All times are GMT -5. The time now is 04:23 AM. |