Results 1 to 6 of 6
  1. #1
    Join Date
    Dec 2007
    Location
    Sao Paulo, Brazil
    Posts
    108

    how to display domain index.html at ip and nameserver

    How do I have mydomain.com display at the main IP address as well as the nameserver IE server01.mydomain.com?

    now all that is displayed there is the Apache page

    Thanks

  2. #2
    Join Date
    May 2009
    Location
    SLASH ROOT
    Posts
    853
    Dear zooserve,

    If you want your main IP display the contents of the domain "mydomain.com", you should disable Name based hosting for this IP.

    >> In Apache's configuration file there will be a NameVirtualHost tag for this IP, comment this and only assign this IP under the <VirtualHost> tab of this domain.

    No need of any additional settings in DNS server, but the IP provided for the "mydomain.com" under <VirtualHost> should be same in the DB records too.

  3. #3
    Join Date
    Dec 2007
    Location
    Sao Paulo, Brazil
    Posts
    108
    this will not effect other domains on the server?

    I was under the impression I could do something simple like a symlink for www or public_html for mydomain.com
    where ever this Apache page is displayed from.

    Thank You

  4. #4
    Join Date
    May 2009
    Location
    SLASH ROOT
    Posts
    853

  5. #5
    Change the documentRoot of the server to the directory where your files are located.

    By default it is /usr/local/apache/htdocs

    Second set CNAME for server01.mydomain.com to point to mydomain.com.

  6. #6
    Join Date
    Oct 2004
    Location
    Kerala, India
    Posts
    4,750
    Add the following at the beginning of the virtualhost section. Assuming document root of mydomain.com is /home/mydomain/public_html

    Code:
    <VirtualHost Server_IP>
    ServerName server01.mydomain.com
    DocumentRoot /home/mydomain/public_html
    </VirtualHost>
    David | www.cliffsupport.com
    Affordable Server Management Solutions sales AT cliffsupport DOT com
    CliffWebManager | Access WHM from iPhone and Android

Similar Threads

  1. Setting index.html as default page instead of index.php?
    By Joel Theodore in forum Hosting Security and Technology
    Replies: 1
    Last Post: 06-23-2008, 11:53 AM
  2. static index.html pages hacked, also *index* files
    By tormeu in forum Hosting Security and Technology
    Replies: 5
    Last Post: 09-12-2007, 11:53 AM
  3. httpd is calling index.html and not index.htm?
    By VagrantHost in forum Hosting Software and Control Panels
    Replies: 4
    Last Post: 04-11-2004, 08:06 PM
  4. index.htm and index.html - how to solve this problem??? Help
    By AvailableHost in forum Programming Discussion
    Replies: 2
    Last Post: 06-17-2003, 04:38 AM
  5. Replies: 1
    Last Post: 06-16-2002, 08:19 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
  •