Results 1 to 5 of 5
  1. #1

    <VirtualHost> directive missing closing '>'

    Hi

    I am trying to enable a site in apache2 but when i try to restart apache i get the following error:

    Syntax error on line 230 of /etc/apache2/apache2.conf: Syntax error on line 20 of /etc/apache2/sites-enabled/zynkron.com: </VirtualHost> directive missing closing '>'

    Now the said line in sites-enabled/zynkron.com reads:
    </VirtualHost *>
    because my start tag is <VirtualHost *> so if I remove the * I will get an error about mixing * and non* ports not being supported, so that's not an option.

    Can anyone help me please?

    Anders

  2. #2
    Join Date
    Mar 2011
    Location
    Edinburgh, UK
    Posts
    567
    The end tag is </VirtualHost> , not </VirtualHost *>

    so:

    <VirtualHost *:80>
    #your stuff
    </VirtualHost>
    Last edited by mike86; 06-08-2012 at 07:46 AM.

  3. #3
    As i wrote at the end of my post, if i dont have the * in my endtag i get another error saying it should be there...

  4. #4
    Join Date
    Mar 2011
    Location
    Edinburgh, UK
    Posts
    567
    Please post the whole tag you are creating.

    Take a look here:

    http://httpd.apache.org/docs/2.0/mod...amevirtualhost

    What you want is:

    NameVirtualHost *:80

    <VirtualHost *:80>
    ServerName zynkron.com
    # ...extra stuff
    </VirtualHost>
    Last edited by mike86; 06-08-2012 at 08:16 AM.

  5. #5

    .

    I do not use the nameVirtualHost line. I followed this guide debian-administration.org/articles/412

    The entire sites-available file looks like this:

    <VirtualHost *>
    ServerAdmin webmaster@zynkron.com
    ServerName zynkron.com
    ServerAlias zynkron.com

    # Indexes + Directory Root.
    DirectoryIndex index.html
    DocumentRoot /var/www/zynkron.com/htdocs/

    # CGI Directory
    ScriptAlias /cgi-bin/ /var/www/zynkron.com/cgi-bin/
    <Location /cgi-bin>
    Options +ExecCGI
    </Location>


    # Logfiles
    ErrorLog /var/www/zynkron.com/logs/error.log
    CustomLog /var/www/zynkron.com/logs/access.log combined
    </VirtualHost>

    Thanks for helping

Similar Threads

  1. VirtualHost directive
    By ~Lee~ in forum Hosting Security and Technology
    Replies: 1
    Last Post: 01-14-2007, 09:22 AM
  2. cpanel addon domains missing / reseller accounts missing from list
    By UnrealSilence in forum Hosting Security and Technology
    Replies: 17
    Last Post: 01-27-2006, 09:43 PM
  3. Replies: 5
    Last Post: 08-21-2005, 07:16 AM
  4. Girl Missing 6 Weeks Found, Brother Still Missing
    By The Dude in forum Web Hosting Lounge
    Replies: 8
    Last Post: 07-05-2005, 04:50 PM
  5. <VirtualHost> directive missing closing '>'
    By Fremont Servers in forum Hosting Security and Technology
    Replies: 3
    Last Post: 09-04-2004, 12:47 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •