Find the answer to your Linux question:
Results 1 to 5 of 5
Like Tree1Likes
  • 1 Post By Lazydog
I am trying to make a website work without having to type www If I type www with the sitename it works. But if I type just the site name ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2012
    Location
    Earth
    Posts
    10

    DNS Question


    I am trying to make a website work without having to type www If I type www with the sitename it works. But if I type just the site name without the www, it does not work. How do I fix this? Thank you for your help

  2. #2
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    What is the output from dig for your www.site.com record? If it is an A record then you want to place the ip address on the origin '@' record and make the www record a CNAME pointing to the origin record.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  3. #3
    Just Joined!
    Join Date
    Mar 2012
    Location
    Earth
    Posts
    10
    Quote Originally Posted by Lazydog View Post
    What is the output from dig for your wsite record? If it is an A record then you want to place the ip address on the origin '@' record and make the www record a CNAME pointing to the origin record.
    Thanks lazy dog. Thats what i believed the issue was also. I think it has to do with the A record. Utilizing the Dig command gives me

    ANSWER SECTION:
    wwsitename IN A IP address.

    In the origin @ record, it reads

    $ORIGIN sitename

    w.w.w IN A ip address

    The ip already seems to be in the origin @ record but like I stated above it reads w.w.w. Where do i go from here and how do I make the w.w.w record a CNAME pointing to the origin record? please excuse my lack of knowledge on this issue
    Thanks in advance
    Last edited by GermanShepherd; 03-07-2012 at 04:34 PM.

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    You would need to change the zone file to look like the following;

    Code:
    @       IN  A          <ip address>
    www   IN  CNAME  @
    GermanShepherd likes this.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  6. #5
    Just Joined!
    Join Date
    Mar 2012
    Location
    Earth
    Posts
    10
    Thanks Lazydog

Posting Permissions

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