Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: webmin + apache2 + virtual host

  1. #1
    Join Date
    Dec 2009
    Beans
    21

    webmin + apache2 + virtual host

    Hey everybody I would like to learn a trick.

    I have been looking on the internet for some time (read 5 days) and can not figure it out. I have done a lot of how-to;s and no result

    Here is my setup

    ubuntu 9.10
    webmin 1.500
    apache 2.2.12
    php, mysql, phpmyadmin proftpd etc.

    static ip 145.x.x.13
    domain haarik.nl (redirected to 145.x.x.13 by hostcompany)

    webmin virtual server
    andles the name-based server on address *.
    Address Any
    Port 80
    Server Name Automatic
    Document Root /var/www/

    Handles the name-based server on all addresses
    Address Any
    Port 443
    Server Name Automatic
    Document Root /var/www
    Handles the name-based server haarik.nl on all addresses
    Address Any
    Port 80
    Server Name haarik.nl
    Document Root /var/www/haarik.nl/

    when i try to acces haarik.nl on the web i can see my website but the source is different.
    <HTML>
    <HEAD>
    <TITLE>haarik.nl</TITLE>
    </HEAD>
    <FRAMESET ROWS="*,0">
    <FRAME SRC="http://145.x.x.13/haarik.nl" NORESIZE>
    <NOFRAMES>
    Your browser does not support frames.
    </NOFRAMES>
    </FRAMESET>
    </HTML>
    I would like to add this site to google but first need to verify that this is mine. So google will search for a document googlexxxxxxx.html as in www.haarik.nl/googlexxxxxx.html but then i get the error 404 not found.


    How can i add my site (and more sites) to google using webmin or config files?

    thank you very much



  2. #2
    Join Date
    Jun 2008
    Location
    North Carolina
    Beans
    271
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: webmin + apache2 + virtual host

    You don't really add your site to google. You can notify google that your site exists (I forget how, but just about any web design book has the information). Even when you do this, there is no guarantee as to what sort of ranking you will get. It will undoubtedly be low at first, meaning you won't be very visible, even by google.

  3. #3
    Join Date
    Dec 2009
    Beans
    21

    Re: webmin + apache2 + virtual host

    I know that i will appear low in ranking, the problem is not adding the site to google but make is accessible for google. At this moment I can access my website but if i look @ the source it is a redirection. So when i try to access for instance the file img34.jpg in the root directory www.haarik.nl/img34.jpg it will say 404 file not found.

  4. #4
    Join Date
    Apr 2008
    Location
    Far, far away
    Beans
    2,148
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: webmin + apache2 + virtual host

    Why do you have a redirect configured? You should just have your DNS settings point your domain to your IP address. Is there something about your hosting situation you have not explained? When I try your site I get a DNS error.

  5. #5
    Join Date
    Dec 2009
    Beans
    21

    Re: webmin + apache2 + virtual host

    I have a range of ip adresses from my provider

    and have the server on 145.99.241.13

    I have registered my domain @ hostnet.nl and they have forwarded (dns type A) straight to my ip.

    try www.haarenik.nl (this now works because i have made this the standard virtual host)

    now i would like to add my site edi-factuur.nl with the same options but this dont works.

  6. #6
    Join Date
    Dec 2009
    Beans
    21

    Re: webmin + apache2 + virtual host

    or should I make my own nameserver on my server? still have some ip adresses unused

  7. #7
    Join Date
    Dec 2006
    Location
    Chicago
    Beans
    3,839

    Re: webmin + apache2 + virtual host

    haarenik.nl resolves to 145.99.241.13
    edi-factuur.nl resolves to 91.184.0.95

    The web server at 91.184.0.95 gives a reply with a simple page which places your real site (http://145.99.241.13/haarenik.nl) in a frame. I'm guessing you probably don't have access to the server which that domain resolves to since it is probably a redirection service. You don't want a redirection service. What you want is to configure edi-factuur.nl to also resolve to 145.99.241.13, then create a new vhost/site (not a subdirectory) for that domain.

  8. #8
    Join Date
    Dec 2009
    Beans
    21

    Re: webmin + apache2 + virtual host

    I will ask hostnet to forward everything to my ip.

    Hopefully we know more tomorrow.

    thankyou

  9. #9
    Join Date
    Apr 2008
    Location
    Far, far away
    Beans
    2,148
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: webmin + apache2 + virtual host

    You don't need to run your own name server but you do need access to configuring your domain at hostnet.nl. You need to add another A record for edi-factuur.nl pointing to your IP (as cdenley indicates). Once that name resolves to your server then you can configure a new site on your server for that name.

    If you are not familiar with the VirtualHost directive in Apache (I assume your web server) then you will need to read up on that. It allows you to run multiple sites on the same IP address.

    If you want to use a different address in your range then you can set your A record to that instead, but you still need to configure Apache to listen and serve on that IP as well.

  10. #10
    Join Date
    Dec 2009
    Beans
    21

    Re: webmin + apache2 + virtual host

    OK now i have both the domains pointed to my ip
    www.edi-factuur.nl
    www.haarenik.nl

    www.haarenik.nl load good
    but edi-factuur.nl points to /var/www/

    this is my httpd.conf
    NameVirtualHost *:80

    <VirtualHost *:80>
    ServerName www.haarenik.nl
    ServerAlias haarenik.nl *.haarenik.nl
    DocumentRoot /var/www/haarenik.nl
    </VirtualHost>

    <VirtualHost *:80>
    ServerName www.edi-factuur.nl
    ServerAlias edi-factuur.nl *.edifactuur.nl
    DocumentRoot /var/www/edi-factuur.nl
    </VirtualHost>


    and i have 000-default and default-ssl in /etc/apache2/sites-available

    what is it that i`m missing?

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

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