Operating System - HP-UX
1819804 Members
3209 Online
109607 Solutions
New Discussion юеВ

check the apache version running.

 
SOLVED
Go to solution
royalsun
Occasional Advisor

check the apache version running.

HI All,

Can anyone tell me how I can find out the version of apache running.Also is it difficult to upgrade the apache ( any hints ).

Thanks, I would appreciate any information.

Mille
10 REPLIES 10
Patrick Chim
Trusted Contributor

Re: check the apache version running.

Hi,

Locate to the bin directory that you install the apache, e.g. /opt/hpws/apache/bin, then type "./apachectl -v" and it will show your the version just like the follows,

> ./bin/apachectl -v
Server version: HP-UX_Apache-based_Web_Server/2.0.46
Server built: Jun 26 2003 04:41:28

I don't think it's difficult to upgrade. In my practice, I prefer uninstall the apache and install the new version again. But, of course, you have to backup the httpd.conf file so that you can keep the same setting in the new apache.

Regards,
Patrick
Steven E. Protter
Exalted Contributor
Solution

Re: check the apache version running.

Several ways.

If you isntalled off depot.

swlist -l product | grep -i apache

With the browser.

http://hostname/page_that_is_not_there

Displays the version of the web server.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Con O'Kelly
Honored Contributor

Re: check the apache version running.

Hi

Use the following command
# httpd -v

You might need to give the full path to httpd
eg /opt/apache/bin/httpd -v.

Cheers
Con
twang
Honored Contributor

Re: check the apache version running.

# swlist -l product |grep -i apache
Rajeev  Shukla
Honored Contributor

Re: check the apache version running.

apachectl -v works only for Apache server 2.X
for lover versions best to use
httpd -v
even if its compiled apache or swinstalled apache httpd -v will help

Also upgrading is not difficult, backup your root doc default ~apache/htdocs and ~apache/conf
uninstall current version and install new versions. Check the path in your webpages coz if you upgrade to 2.X using the swinstall it will take /opt/apache2 as default path.
Use the source code and compile your won using gcc there you can prefix the path.

Rajeev
Peter_328
New Member

Re: check the apache version running.

If you have PHP installed you could do the following.

Create a file in the root html directory called phpinfo.php containing the following code.

phpinfo();
?>

This will display alot of information about your configuration including the Apache version, Release, API Version, Hostname:Port etc.
Also Apache Environment Details.
Gregory Fruth
Esteemed Contributor

Re: check the apache version running.

You can usually get the version number by entering a bad URL
in your browser's Location box.

http://myserver.mydomain.com/a_bad_url

You'll get a message like:

Not Found
The requested URL /a_bad_url was not found on this server.
Apache/1.3.27 Server at myserver.mydomain.com Port 80

I don't believe there's an Apache "upgrade" in the sense of
"upgrade" vs. "cold install". You normally just remove the
old version and "cold install" the new version. Installing
Apache 1.x is quite easy. I installed Apache 2.x a while
back but went back to 1.x. Perhaps 2.x has improved
since then.
Shannon Petry
Honored Contributor

Re: check the apache version running.

Actually if I enter a bad URL I get a squid error :)

Apache on HP-UX, Squid on HP-UX, Bind on HP-UX, DNS on HP-UX, and FTP on HP-UX. Ahhh, what a day.

Regards,
Shannon
Microsoft. When do you want a virus today?
Dario_1
Trusted Contributor

Re: check the apache version running.

Hi!

Do the following:

cd apache/bin
./httpd -v

Regards,

Dario
royalsun
Occasional Advisor

Re: check the apache version running.

Hi Folks,

Many thanks for all these responses, they are much appreciated - I can now determine that my "apachectl -v" ( which I did not mention ) did not work as I was on a pre 2.0 version namely 1.3.9 .

Cheers and good luck,

Regards,

Mille