How-to: Upgrade Apache 1.x to 2.0

ovsoft

Verified User
Joined
Oct 27, 2004
Messages
76
The only real change to DA is how the httpd.conf files are written. You can let DA know to use the apache 2 files by setting "apache_ver=2.0" in your directadmin.conf file, but the convertor will do that for you anyway.

New templates:
virtual_host2.conf
virtual_host2_sub.conf
virtual_host2_secure.conf
virtual_host2_secure_sub.conf

The only real difference being the replacement of User and Group with
SuexecUserGroup.

Once you've go this version of DA, you'll be able to update to apache 2 by updating the build script and installing apache 2. The script will convert your main httpd.conf file and recompile apache/php/mod_frontpage etc for you. It will also set the required DA settings and rewrite all user httpd.conf files to apache 2.

To get and build apache 2.0, run the following:

cd /usr/local/directadmin/customapache
./build update
./build clean
./build update_data_ap2
./build convert
./build apache_2
./build php_ap2
./build mod_frontpage_ap2
./build mod_perl_ap2
 
I dont know if this bug still exists but when I updated a box to apache 2.x the /etc/httpd/conf/httpd.conf remained in 1.x format so I renamed it so the file didnt exist and reran ./build convert this then placed a new 2.x version of the file there.
 
towards the end of the upgrade, it asks several questions like:
mCrypt is already installed. Do you want to build it again? (y/n) :

mHash is already installed. Do you want to build it again? (y/n) :

zZip is already installed. Do you want to build it again? (y/n) :

just for example (there are several more)

should i build it again?
 
Entirely up to you. We generally say yes if we have the time, to make sure they're properly integrated.

Jeff
 
Apache 2.0 + PHP5

I will soon install a new DA server for PHP5+MySQL5
so I wanted to know if Apache 2.0 would be fine for that setup
 
If that's what you want to offer your clients, yes.

There are some (but not many) differences between Apache 1.x and Apache 2.x, mostly having to do with which modules are available.

There are some (important) differences between php 4 and php 5, and some scripts written for php 4 won't run on php 5.

Jeff
 
Yeah, that is what I would like to have. A server with the latest versions:
Apache 2 + PHP 5 + MySQL 5

and another with legacy more compatible versions: Apache 1.3.x, PHP4 and MySQL4.
 
Is it possible to setup apache 2.x next to apache 1.x on different ip's?

I want the user choose which software they want to use.

Example:

IP 1:
Apache 1.3.34
PHP 4.4.2
MySQL 4.1.16

IP 2:
Apache 2.2.0
PHP 5.1.2
MySQL 4.1.16

The only thing the user should change in the configuration is the IP who is serving to the web.

Example.

www.domain.com points to the first ip will handle with the software on the first ip.

pointing www.domain.com to the second ip will be handled by the software on the second ip.
 
Anything is possible with enough work.

Including striking a match on a wet cake of soap (I think I might have posted that somewhere).

And of course running httpd 1.x and 2.x on different IP#s or even on different port numbers, on the same server.

DirectAdmin won't be able to manage both; it'll only manage one or the other, and it'll be a very tedious and time-consuming job to set it up, so it's probably an exercise in futility.

Jeff
 
ovsoft said:
The only real change to DA is how the httpd.conf files are written. You can let DA know to use the apache 2 files by setting "apache_ver=2.0" in your directadmin.conf file, but the convertor will do that for you anyway.

New templates:
virtual_host2.conf
virtual_host2_sub.conf
virtual_host2_secure.conf
virtual_host2_secure_sub.conf

The only real difference being the replacement of User and Group with
SuexecUserGroup.

Once you've go this version of DA, you'll be able to update to apache 2 by updating the build script and installing apache 2. The script will convert your main httpd.conf file and recompile apache/php/mod_frontpage etc for you. It will also set the required DA settings and rewrite all user httpd.conf files to apache 2.

To get and build apache 2.0, run the following:

cd /usr/local/directadmin/customapache
./build update
./build clean
./build update_data_ap2
./build convert
./build apache_2
./build php_ap2
./build mod_frontpage_ap2
./build mod_perl_ap2

I like to know what is the different between the "How to" and this one from the DA Knowledge base.


cd /usr/local/directadmin/customapache
./build clean
./build update
./build apache_mod_ssl

THanks
 
Re: Re: How-to: Upgrade Apache 1.x to 2.0

rocky said:
I like to know what is the different between the "How to" and this one from the DA Knowledge base.


cd /usr/local/directadmin/customapache
./build clean
./build update
./build apache_mod_ssl

THanks

This to update apache only 1.3.x
 
After installing i am getting this error :

(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down

and httpd can't start
 
massive said:
After installing i am getting this error :

(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down

and httpd can't start

Code:
netstat -lnp | grep '0.0.0.0:80'
then kill pid -9 then start httpd again :)
use Apache 1.3 batter then Apache 2
 
i've done that already but the process didn't exist.

I downgraded to 1.3. The error message gone but
httpd didn't work.

I reinstalled directadmin and everyting is ok now.

I want to upgrade to 2.0 but...
 
is strange but now i made the same steps and its working.
The only change that i've made was to delete the original php.ini file, just in case...

Now everything works except the incompatibility of ips.conf.

is there any script that change this?
Also if i reinstall DA apache 2 will remain?
 
Last edited:
Back
Top