Results 1 to 5 of 5

Thread: DNS resolves domain, than url changes to ip address

  1. #1
    Join Date
    Dec 2008
    Location
    USA
    Beans
    524
    Distro
    Ubuntu 12.04 Precise Pangolin

    DNS resolves domain, than url changes to ip address

    I just added a sub domain to my godaddy hosting.
    The main domain is hosted by go daddy. the sub is local to my office.
    its on an Ubuntu 12.04 box.

    If I go to sub.mydomain.org it works. However the url bar changes to the ip address.
    I tied 2 browsers to confirm. Is there something I need to do in apache2?
    Also will creating sub.mydomain.org/wow be an issue?
    Last edited by wlraider70; June 22nd, 2013 at 04:52 PM.
    I don' really like coffee. I guess I'll give my Ubuntu beans to my wife.

    Luke

  2. #2
    Join Date
    Nov 2008
    Location
    Metro Boston
    Beans
    11,508
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: DNS resolves domain, than url changes to ip address

    Do you have a <VirtualHost> stanza that includes sub.mydomain.org in a ServerName or ServerAlias directive?

    The answer to your second question is no.
    If you ask for help, please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  3. #3
    Join Date
    Dec 2008
    Location
    USA
    Beans
    524
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: DNS resolves domain, than url changes to ip address

    ok IF I understand you I now have


    Code:
    
     GNU nano 2.2.6             File: /etc/apache2/httpd.conf
    
    <VirtualHost *:80>
        # This first-listed virtual host is also the default for *:80
        ServerName www.apps.wi**.org
        ServerAlias apps.wil**.org
        DocumentRoot /var/www/
    
    </VirtualHost>
    the root is where i have the index.html file. is that correct?


    is this a problem?


    Code:
    server@philo:/etc/apache2$ sudo service apache2 restart
     * Restarting web server apache2                                                           apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
     ... waiting apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
    
           [ OK ]
    Last edited by wlraider70; June 21st, 2013 at 11:53 PM. Reason: took out lazy answer, put in effort
    I don' really like coffee. I guess I'll give my Ubuntu beans to my wife.

    Luke

  4. #4
    Join Date
    Nov 2008
    Location
    Metro Boston
    Beans
    11,508
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: DNS resolves domain, than url changes to ip address

    Add an entry to /etc/hosts like this

    Code:
    ip.addr.of.ext_interface  www.apps.xxx.org
    The first entry is the externally-facing IP address; the second is the hostname.

    Restart apache with "sudo service apache2 restart".

    This is only necessary when you do not have a DNS with a reverse ("PTR") record configured for the address.
    If you ask for help, please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  5. #5
    Join Date
    Dec 2008
    Location
    USA
    Beans
    524
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: DNS resolves domain, than url changes to ip address

    got it. thanks again.
    I don' really like coffee. I guess I'll give my Ubuntu beans to my wife.

    Luke

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
  •