Operating System - HP-UX
1819575 Members
2795 Online
109603 Solutions
New Discussion юеВ

Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

 
SOLVED
Go to solution
went_2
Advisor

Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

I failed to build a 64-bit Apache Web Server on HP-UX Itanium. Can anybody help me? Thank you.
Following is what I did:

I tried following commands to build 64-bit Apache Web Server ::
export CFLAGS="-mlp64"
export CPPFLAGS="-mlp64"
./configure --prefix=
make
make install

After that, I successfully got Apache Web Server installed, and I got following information by "httpd -V" command ::
bash-3.00$ ./httpd -V
Server version: Apache/2.0.55
Server built: Jun 27 2006 19:51:23
Server's Module Magic Number: 20020903:11
Architecture: 64-bit
...

But the Web Server cannot start, not giving me any error message or response.


(If I add one line in httpd.conf file to load a customized module, I will get an error when I try to start the Web Server :" aCC runtime: Use of "-mt" must be consistent during both compilation and linking.")
22 REPLIES 22
Arunvijai_4
Honored Contributor
Solution

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

This could be a multithreaded issue. Export CFLAGS and CPPFLAGS="-mlp64 -mt" and try to build it. Also, what is # file httpd ?

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Then I got following error:

bash-3.00$ export CFLAGS="-mlp64 -mt"
bash-3.00$ export CPPFLAGS="-mlp64 -mt"
bash-3.00$ sudo ./configure --prefix=
checking for chosen layout... Apache
checking for working mkdir -p... yes
checking build system type... ia64-hp-hpux11.23
checking host system type... ia64-hp-hpux11.23
checking target system type... ia64-hp-hpux11.23

Configuring Apache Portable Runtime library ...

checking for APR... reconfig
configuring package in srclib/apr now
checking build system type... ia64-hp-hpux11.23
checking host system type... ia64-hp-hpux11.23
checking target system type... ia64-hp-hpux11.23
Configuring APR library
Platform: ia64-hp-hpux11.23
checking for working mkdir -p... yes
APR Version: 0.9.7
checking for chosen layout... apr
checking for gcc... gcc
checking for C compiler default output file name... configure: error: C compiler cannot create executables
See `config.log' for more details.
configure failed for srclib/apr
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi Arun,

What do you mean by "what is # file httpd ?" ?
^_^
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

is this what u want? this is the access control on the file:

-rw-r--r-- 1 root sys 35385 Jul 10 13:34 httpd.conf
Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

# file httpd will show you architecture related information. Do a # man file for more information. Make sure you use "-mt" everywhere. Also, have you created necessarry user/group for Apache ?

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

# file httpd:
httpd: ELF-64 executable object file - IA64

I am using root user to install and start apache.

Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

# file httpd:
httpd: ELF-64 executable object file - IA64

I am using root user to install and start apache.

I dont think it is good to start apache as root user. Try creating "www" user and start it. Also, check this out

Errors During Start-up

If Apache suffers a fatal problem during startup, it will write a message describing the problem either to the console or to the ErrorLog before exiting. One of the most common error messages is "Unable to bind to Port ...". This message is usually caused by either:

* Trying to start the server on a privileged port when not logged in as the root user; or
* Trying to start the server when there is another instance of Apache or some other web server already bound to the same Port.

http://httpd.apache.org/docs/2.2/invoking.html

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Now i am trying to build it again with following command:
# export CFLAGS="-mlp64 -mt"
# export CPPFLAGS="-mlp64 -mt"
# ./configure=

but the ./configure command failed with following information:

checking for chosen layout... Apache
checking for working mkdir -p... yes
checking build system type... ia64-hp-hpux11.23
checking host system type... ia64-hp-hpux11.23
checking target system type... ia64-hp-hpux11.23

Configuring Apache Portable Runtime library ...

checking for APR... reconfig
configuring package in srclib/apr now
checking build system type... ia64-hp-hpux11.23
checking host system type... ia64-hp-hpux11.23
checking target system type... ia64-hp-hpux11.23
Configuring APR library
Platform: ia64-hp-hpux11.23
checking for working mkdir -p... yes
APR Version: 0.9.7
checking for chosen layout... apr
checking for gcc... gcc
checking for C compiler default output file name... configure: error: C compiler cannot create executables
See `config.log' for more details.
configure failed for srclib/apr



Please see the config.log in attachement.
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

because i am integrating Apache with another application, it's required to start Apache using root user.

I used root user to build and start 32-bit Apache, and didn't face any problem.
Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

I dont see any errors in config.log. But, i strongly feel you should go with aCC for -mt option. I dont have a 11.23 with GCC installed to check this. Try installing aCC and compile again.

http://h20293.www2.hp.com/portal/swdepot/displayProductInfo.do?productNumber=B9007AAEVAL

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

aCC has been installed on this machine.
Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

Then, try building with aCC and +DD64 option along with -mt

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

I can compile apache with no error using
#export CFLAGS="-mlp64" (no -mt)
#export CPPFLAGS="-mlp64" (no -mt)
Then I found following errors in Apache error_log when I tried to start it.

(if "-mt" is used, the compilation will faile.)

[Mon Jul 10 17:14:13 2006] [emerg] (22)Invalid argument: Couldn't set permissions on cross-process lock; check User and Group directives
[Mon Jul 10 17:34:17 2006] [warn] pid file /usr/local/huanfang/apache2.0.55-64-2/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

ok, let me try.
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

I am not familiar with Unix system, can you tell me how to specify aCC to be used when compiling?
Setting some flags before running ./configure ?
Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

You can just use # export CC= before starting ./configure

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

aCC is installed in /opt/aCC directory.
I tried:
export CC=/opt/aCC/bin/aCC
export CFLAGS="+DD64 -mt"
export CPPFLAGS="+DD64 -mt"
./configre --prefix=<...>

but got error like this:

checking for chosen layout... Apache
checking for working mkdir -p... yes
checking build system type... ia64-hp-hpux11.23
checking host system type... ia64-hp-hpux11.23
checking target system type... ia64-hp-hpux11.23

Configuring Apache Portable Runtime library ...

checking for APR... reconfig
configuring package in srclib/apr now
checking build system type... ia64-hp-hpux11.23
checking host system type... ia64-hp-hpux11.23
checking target system type... ia64-hp-hpux11.23
Configuring APR library
Platform: ia64-hp-hpux11.23
checking for working mkdir -p... yes
APR Version: 0.9.7
checking for chosen layout... apr
checking for gcc... /opt/aCC/bin/aCC
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... no
checking whether /opt/aCC/bin/aCC accepts -g... yes
checking for /opt/aCC/bin/aCC option to accept ANSI C... -Ae
Applying APR hints file rules for ia64-hp-hpux11.23
adding "-DHPUX11" to CPPFLAGS
adding "-D_REENTRANT" to CPPFLAGS
adding "-D_XOPEN_SOURCE_EXTENDED" to CPPFLAGS
(Default will be unix)
checking whether make sets $(MAKE)... yes
checking how to run the C preprocessor... /opt/aCC/bin/aCC
configure: error: C preprocessor "/opt/aCC/bin/aCC" fails sanity check
See `config.log' for more details.
configure failed for srclib/apr
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

==================================
export CC=/opt/aCC/bin/aCC
export CFLAGS="+DD64 -mt -I/opt/aCC/include"
export CPPFLAGS="+DD64 -mt -I/opt/aCC/include"
export LDFLAGS="-L/opt/aCC/lib"
./configure

I got following error. Did I miss something?
----------Error-------------------
...
checking for /opt/aCC/bin/aCC option to accept ANSI C... none needed
Applying APR hints file rules for ia64-hp-hpux11.23
adding "-DHPUX11" to CPPFLAGS
adding "-D_REENTRANT" to CPPFLAGS
adding "-D_XOPEN_SOURCE_EXTENDED" to CPPFLAGS
(Default will be unix)
checking whether make sets $(MAKE)... yes
checking how to run the C preprocessor... /opt/aCC/bin/aCC
configure: error: C preprocessor "/opt/aCC/bin/aCC" fails sanity check
See `config.log' for more details.
configure failed for srclib/apr
Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi Went,

Which version of aCC you have in your system ? # what /opt/aCC/bin/aCC will be helpful. Try to patch it to recent version and do it one more time.

Also, do a # swverify to make sure your installation is correct.

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

The aCC version is:
HP aC++/C for Itanium(R)-based systems B3910B A.05.60 [Aug 25 2004]

But for swverify, the system say:
swverify: command not found
Arunvijai_4
Honored Contributor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

Hi,

aCC version seems to be old, You can try with this latest patch PHSS_34047 or PHSS_34351. You can download from, http://www2.itrc.hp.com/service/patch/mainPage.do entering the patch ID.

Also, Try # /usr/sbin/swverify

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
went_2
Advisor

Re: Got problem when building 64-bit Apache Web Server on HP-UX Itanium.

#swverify say nothing.

I need to call IT people to upgrade aCC.
I will try again after upgrading. thank u.