Urgent help please

Discussion in 'General' started by Toucan, Jun 17, 2010.

  1. Toucan

    Toucan Member

    !!! NO LONGER URGENT !!! THANKS

    Apache is having problems starting....

    I enabled ssl on a site and minutes later everything came to a halt.

    I have tried restarting apache but this is the result I get:
    Code:
    badbuntu:~# /etc/init.d/apache2 restart
    Restarting web server: apache2[Thu Jun 17 21:36:50 2010] [warn] _default_ Virtua              lHost overlap on port 443, the first has precedence
    [Thu Jun 17 21:36:50 2010] [warn] _default_ VirtualHost overlap on port 443, the               first has precedence
     failed!
    badbuntu:~#
    
    Can someone help me resolve this urgently please. All my sites are down..
     
    Last edited: Jun 18, 2010
  2. itsnedkeren

    itsnedkeren New Member

    /etc/apache2/ports.conf

    Uncomment this line:

    Listen 443

    Restart apache server
     
  3. Toucan

    Toucan Member

    That line was already uncommmented

    It looks like this:
    Code:
    # If you just change the port or add more ports here, you will likely also
    # have to change the VirtualHost statement in
    # /etc/apache2/sites-enabled/000-default
    # This is also true if you have upgraded from before 2.2.9-3 (i.e. from
    # Debian etch). See /usr/share/doc/apache2.2-common/NEWS.Debian.gz and
    # README.Debian.gz
    
    NameVirtualHost *:80
    Listen 80
    
    <IfModule mod_ssl.c>
        # SSL name based virtual hosts are not yet supported, therefore no
        # NameVirtualHost statement here
     Listen 443
    </IfModule>
    
    apache won't let me do anything:
    Code:
    badbuntu:/etc/apache2# /etc/init.d/apache2 stop
    Stopping web server: apache2[Thu Jun 17 22:19:32 2010] [warn] _default_ VirtualHost overlap on port 443, the first has precedence
    .
    
     
  4. itsnedkeren

    itsnedkeren New Member

    Code:
    # If you just change the port or add more ports here, you will likely also
    # have to change the VirtualHost statement in
    # /etc/apache2/sites-enabled/000-default
    # This is also true if you have upgraded from before 2.2.9-3 (i.e. from
    # Debian etch). See /usr/share/doc/apache2.2-common/NEWS.Debian.gz and
    # README.Debian.gz
    
    NameVirtualHost *:80
    Listen 80
    
    <IfModule mod_ssl.c>
        # SSL name based virtual hosts are not yet supported, therefore no
        # NameVirtualHost statement here
    [COLOR="Red"] #Listen 443[/COLOR]
    </IfModule>
    Uncomment the line, as above and restart apache.
     
  5. ivomendonca

    ivomendonca Banned

    Same error as reported before.

    Delete your SSL files and remove from vhost manualy, then when all is working again just add the ssl file the right way. (you can makeit from 2 ways using the interface, one will work)
    Before maybe you shoud disable ssl in all sites using ssl and add a ip just for that domain.
     
    Last edited: Jun 17, 2010
  6. Toucan

    Toucan Member

    Solved the problem.. probably the wrong way but solved never the less!

    I manually removed the vhost files for the website that caused the problems, restarted apache successfully.

    I then could log into the control panel, remove the offending site from there. I then readded the site and restored the content from a backup.

    What is the way that works to enable ssl on a site?

    Thanks both for your help.
     
  7. ivomendonca

    ivomendonca Banned

    You dont need to delete the vhost files, just the lines related to ssl.
    Is like you did last time, the problem is when you select the domain (www) or the (*.), one of those will kill apache and one will work, remember you need a ip just to that site. not a shared ip.
    When trying u need to kill problematic apache process before starting again.(dont reboot :), that is only on ruindows)
     
    Last edited: Jun 18, 2010
  8. Toucan

    Toucan Member

    I did actually try commenting out the lines that I thought related to ssl but that didn't seem to work.. so i took the hard route!

    I didn't realise you couldn't have more than one SSL on a shared IP between virtual hosts... I won't forget that in a hurry. Sadly my ISP will only give one IP and I'm getting ready to prepare one day for a change of ISP!
     

Share This Page