# Uninstall & Reinstall Apache2

## tony25

Hello guys.

I got a dedicated server for the first time with gentoo on it (first I had debian), anyway the farm preinstalled apache2 ssl and when I create a virtual host the only way to conect to the website is with https but I really dont want it like this. I would like to have http and I dont know how todo. I have tryed to configure th virtual host, to deactivate the ssl conection but I get an error. I go to apache server, then virtual server, then ssl options and I deactivate the ssl protocols and when I do Aply changes I get this error 

Failed to apply changes : 

Syntax error on line 35 of /usr/local/apache/conf/ssl.conf:

Expected  before end of configuration

So I thought to uninstall apache2 ssl and install the normal apache2 but I dont know how to do that. If anyone can help me to just configure the actual apache that I have would be grate, but uninstalling and reinstalling the normal http apache would be nice too.

ps: sorry my english

Thankey!

----------

## snIP3r

hi!

we can only help you if you post the config file /usr/local/apache/conf/ssl.conf

i don't think you have to deinstall apache. i think its only a matter of settings. how did you configure your apache? with a webgui (perhaps plesk)?

HTH

snIP3r

----------

## tony25

Hello.

I use Webmin to configure apache and other things on my server. Anyway I found more simple to reinstall apache, for more I dont need apache ssl, I will never use ssl so if you can pls just tell me how to uninstall it in safe  :Smile: 

Thanks!

----------

## tony25

Sory for double post but anyway this is the line 35 where I get the error (I am pasting from line 30 to 39 so line 35 is <IfDefine SSL>)

#SSLRandomSeed startup file:/dev/random  512

#SSLRandomSeed startup file:/dev/urandom 512

#SSLRandomSeed connect file:/dev/random  512

#SSLRandomSeed connect file:/dev/urandom 512

<IfDefine SSL>

#

# When we also provide SSL we have to listen to the 

# standard HTTP port (see above) and to the HTTPS port

----------

## snIP3r

hi!

ok, normally the support for ssl is controlled by the use flags in /etc/make.conf. if theres a "ssl" in the use flags apache will be installed with ssl support. but you can change the modules loaded by apache in /etc/conf.d/apache2. this file looks like this:

```

APACHE2_OPTS="-D DEFAULT_VHOST -D INFO -D LANGUAGE -D SSL -D SSL_DEFAULT_VHOST -D PROXY -D PHP5 -D DAV -D AUTH_DIGEST"
```

simply delete the passage

```

-D SSL

```

restart apache and the ssl module will not be loaded anymore. i would _NOT_ suggest do delete "ssl" in your use flags because other installed packages require ssl support to work properly. 

if you want to build only apache without ssl-support you can also modify your /etc/portage/package.use and add something like this:

```

www-servers/apache -ssl

```

after this you have to rebuild apache and it will be reinstalled without ssl support...

but i would not change the installation like this. just delete the "-D SSL" passage as i described above, this will do it for you.

HTH

snIP3r

----------

## tony25

Thanks sniper. But anyway I did before manualy adding a virtual host on httpd.conf and I set SSL Engine Off , and it works.  :Smile:  Anyway I am going to save your sugestion to, maybe it will help me someday.

But afterall, now I am more curious how can I uninstall apache...

----------

