How do I point www.example.com to a.example.com?301 redirect root domain to www subdomain on godaddy windows...

Do I have a twin with permutated remainders?

Why are 150k or 200k jobs considered good when there are 300k+ births a month?

LaTeX closing $ signs makes cursor jump

Mathematical cryptic clues

Problem of parity - Can we draw a closed path made up of 20 line segments...

Can divisibility rules for digits be generalized to sum of digits

Can I make popcorn with any corn?

In Japanese, what’s the difference between “Tonari ni” (となりに) and “Tsugi” (つぎ)? When would you use one over the other?

How do we improve the relationship with a client software team that performs poorly and is becoming less collaborative?

How is it possible to have an ability score that is less than 3?

can i play a electric guitar through a bass amp?

Have astronauts in space suits ever taken selfies? If so, how?

The use of multiple foreign keys on same column in SQL Server

How could an uplifted falcon's brain work?

Is a tag line useful on a cover?

To string or not to string

Is it important to consider tone, melody, and musical form while writing a song?

Which models of the Boeing 737 are still in production?

Can I ask the recruiters in my resume to put the reason why I am rejected?

Why not use SQL instead of GraphQL?

How can bays and straits be determined in a procedurally generated map?

Is it possible to do 50 km distance without any previous training?

Languages that we cannot (dis)prove to be Context-Free

Approximately how much travel time was saved by the opening of the Suez Canal in 1869?



How do I point www.example.com to a.example.com?


301 redirect root domain to www subdomain on godaddy windows hosting accountRedirect all non-www subdomains to main www domain with Apache2Wordpress htaccess redirect destroys my non-www to www redirect.htaccess - redirect non www to www and retain subdomains from redirectingApache issue with VirtualHostsIIS 7.5 SSL RedirectHow can I get my MyDomain-registered domain to point to a new URL?Apache2: How to reverse proxy a subdomain to an internal server with sslwww and no www duplicate versions of the site?how to have domain without www and MX records work together?






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







-1















I have a synthetic record set up pointing example.com to www.example.com and this works.
I also have a CNAME pointing a.example.com to a website that hosts my images, and this works.



I want www.example.com to redirect to a.example.com, while I build a website to deploy on www.example.com.



I used CNAME from www.example.com to a.example.com and this did not work. Everything I read says that CNAME is the correct tool for this, so what is going on?










share|improve this question









New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
















  • 1





    Have you used an DNS resolution tools to see what is going on and what is being returned? dig can be very informative when troubleshooting DNS resolution issues. CNAME is typically the way to go for these types of things. Also obfuscating the domain in this circumstance actually hurts troubleshooting the issue. What DNS server are you using? What are your forward zone configs?

    – Dion Pezzimenti
    yesterday













  • So proper config would be something as such, A Record www.domain.com points to IP. CNAME a.domain.com points to www.domain.com

    – Dion Pezzimenti
    yesterday











  • In general saying "it does not work" is not very helpful as it lacks details about what you tried exactly, what error messages or undesired behavior you got and what results you expected. Also (badly) obfuscating DNS data is kind of silly as it both hinders help (no one can redo your troubleshooting steps to double check) and is pointless since the DNS is public anyway.

    – Patrick Mevzek
    6 mins ago




















-1















I have a synthetic record set up pointing example.com to www.example.com and this works.
I also have a CNAME pointing a.example.com to a website that hosts my images, and this works.



I want www.example.com to redirect to a.example.com, while I build a website to deploy on www.example.com.



I used CNAME from www.example.com to a.example.com and this did not work. Everything I read says that CNAME is the correct tool for this, so what is going on?










share|improve this question









New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
















  • 1





    Have you used an DNS resolution tools to see what is going on and what is being returned? dig can be very informative when troubleshooting DNS resolution issues. CNAME is typically the way to go for these types of things. Also obfuscating the domain in this circumstance actually hurts troubleshooting the issue. What DNS server are you using? What are your forward zone configs?

    – Dion Pezzimenti
    yesterday













  • So proper config would be something as such, A Record www.domain.com points to IP. CNAME a.domain.com points to www.domain.com

    – Dion Pezzimenti
    yesterday











  • In general saying "it does not work" is not very helpful as it lacks details about what you tried exactly, what error messages or undesired behavior you got and what results you expected. Also (badly) obfuscating DNS data is kind of silly as it both hinders help (no one can redo your troubleshooting steps to double check) and is pointless since the DNS is public anyway.

    – Patrick Mevzek
    6 mins ago
















-1












-1








-1








I have a synthetic record set up pointing example.com to www.example.com and this works.
I also have a CNAME pointing a.example.com to a website that hosts my images, and this works.



I want www.example.com to redirect to a.example.com, while I build a website to deploy on www.example.com.



I used CNAME from www.example.com to a.example.com and this did not work. Everything I read says that CNAME is the correct tool for this, so what is going on?










share|improve this question









New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












I have a synthetic record set up pointing example.com to www.example.com and this works.
I also have a CNAME pointing a.example.com to a website that hosts my images, and this works.



I want www.example.com to redirect to a.example.com, while I build a website to deploy on www.example.com.



I used CNAME from www.example.com to a.example.com and this did not work. Everything I read says that CNAME is the correct tool for this, so what is going on?







domain subdomain www






share|improve this question









New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited 6 mins ago









Patrick Mevzek

2,87731225




2,87731225






New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 2 days ago









RyanRyan

99




99




New contributor




Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Ryan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.








  • 1





    Have you used an DNS resolution tools to see what is going on and what is being returned? dig can be very informative when troubleshooting DNS resolution issues. CNAME is typically the way to go for these types of things. Also obfuscating the domain in this circumstance actually hurts troubleshooting the issue. What DNS server are you using? What are your forward zone configs?

    – Dion Pezzimenti
    yesterday













  • So proper config would be something as such, A Record www.domain.com points to IP. CNAME a.domain.com points to www.domain.com

    – Dion Pezzimenti
    yesterday











  • In general saying "it does not work" is not very helpful as it lacks details about what you tried exactly, what error messages or undesired behavior you got and what results you expected. Also (badly) obfuscating DNS data is kind of silly as it both hinders help (no one can redo your troubleshooting steps to double check) and is pointless since the DNS is public anyway.

    – Patrick Mevzek
    6 mins ago
















  • 1





    Have you used an DNS resolution tools to see what is going on and what is being returned? dig can be very informative when troubleshooting DNS resolution issues. CNAME is typically the way to go for these types of things. Also obfuscating the domain in this circumstance actually hurts troubleshooting the issue. What DNS server are you using? What are your forward zone configs?

    – Dion Pezzimenti
    yesterday













  • So proper config would be something as such, A Record www.domain.com points to IP. CNAME a.domain.com points to www.domain.com

    – Dion Pezzimenti
    yesterday











  • In general saying "it does not work" is not very helpful as it lacks details about what you tried exactly, what error messages or undesired behavior you got and what results you expected. Also (badly) obfuscating DNS data is kind of silly as it both hinders help (no one can redo your troubleshooting steps to double check) and is pointless since the DNS is public anyway.

    – Patrick Mevzek
    6 mins ago










1




1





Have you used an DNS resolution tools to see what is going on and what is being returned? dig can be very informative when troubleshooting DNS resolution issues. CNAME is typically the way to go for these types of things. Also obfuscating the domain in this circumstance actually hurts troubleshooting the issue. What DNS server are you using? What are your forward zone configs?

– Dion Pezzimenti
yesterday







Have you used an DNS resolution tools to see what is going on and what is being returned? dig can be very informative when troubleshooting DNS resolution issues. CNAME is typically the way to go for these types of things. Also obfuscating the domain in this circumstance actually hurts troubleshooting the issue. What DNS server are you using? What are your forward zone configs?

– Dion Pezzimenti
yesterday















So proper config would be something as such, A Record www.domain.com points to IP. CNAME a.domain.com points to www.domain.com

– Dion Pezzimenti
yesterday





So proper config would be something as such, A Record www.domain.com points to IP. CNAME a.domain.com points to www.domain.com

– Dion Pezzimenti
yesterday













In general saying "it does not work" is not very helpful as it lacks details about what you tried exactly, what error messages or undesired behavior you got and what results you expected. Also (badly) obfuscating DNS data is kind of silly as it both hinders help (no one can redo your troubleshooting steps to double check) and is pointless since the DNS is public anyway.

– Patrick Mevzek
6 mins ago







In general saying "it does not work" is not very helpful as it lacks details about what you tried exactly, what error messages or undesired behavior you got and what results you expected. Also (badly) obfuscating DNS data is kind of silly as it both hinders help (no one can redo your troubleshooting steps to double check) and is pointless since the DNS is public anyway.

– Patrick Mevzek
6 mins ago












3 Answers
3






active

oldest

votes


















1














So you can check my comments for a little bit of insight on how to troubleshoot your issue. But I suppose a definitive answer to how DNS records work and how to achieve the redirection you are looking for would be more appropriate. RFCs probably are the proper way to site sources, but I like to explain with my own examples. So I will provide screen shots from my Windows 2016 Active Directory server that runs DNS locally on the server as well. Now if you use something like bind on Linux/Windows then the concepts should hold true, but obviously a different approach to configuration.



So your DNS server is going to have a Forward Lookup zone configured for your domain. Mine for this instance is digiecho.xyz as you can see in the screenshot below:



DNS Forward Zone Example



In the lookup zone you can see that I have an assortment of A records that point to IP addresses. These are the most common types of records created in my experience. So you should have one A record where your www.domain.com points to some IP. For my example I'm going to use my A record for VC01.



A CNAME or Canonical Name allows you to create used to alias one name to another. I'm going to create a CNAME record vcenter.digiecho.xyz and point it to my A record VC01 (see screen shot below for record creation example, and info on CNAMEs):



https://support.dnsimple.com/articles/cname-record/



CNAME Record Creation



You then can use DNS tools like dig or nslookup to troubleshoot what is going on. Since this is all on my internal network I just used nslookup from another server on my virtual host to show some relevant outputs to help you in your troubleshooting:



nslookup Example



As you can see it not only tells me the true canonical domain the alias points to. However it should report back the server that is reporting back the record. So if you have like a master-slave configuration in your DNS environment you will want to make sure the zone transfers have occurred from the master to all the slaves to ensure that they all have the correct. If you are using Linux just man dig for the command parameters. But really those basic DNS checks and troubleshooting should be sufficient to solve a CNAME issue.






share|improve this answer































    1














    A CNAME record should not point to another CNAME record.



    Find out where your a.example.com CNAME actually points to, and then set your www.example.com CNAME to also point directly to that.






    share|improve this answer


























    • A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

      – Patrick Mevzek
      3 mins ago



















    0














    name                optional_TTL   CLASS   RR      canonical name
    www.example.net. 3600 IN CNAME a.example.com.


    Simplified a DNS CNAME record does nothing more than pointing a DNS record to the canonical name of another host by using that hosts DNS name rather than by creating an A entering that hosts IP-address.



    After that DNS change you will usually need to reconfigure a.example.com and make the services running there aware of the fact they can be accessed by an additional hostname www.example.net. rather than only via a.example.com.



    If you don't do that, things may work out, for instance a web server running plain http and only one website will display that website regardless of the hostname used to access the web server, but for a web server running multiple virtual hosts on HTTPS you will need to both request a new TLS certificate with the www.example.net. domain name AND you need to either create a new virtual host entry, or add www.example.net. to a specific existing virtual host.






    share|improve this answer
























      Your Answer








      StackExchange.ready(function() {
      var channelOptions = {
      tags: "".split(" "),
      id: "2"
      };
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function() {
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled) {
      StackExchange.using("snippets", function() {
      createEditor();
      });
      }
      else {
      createEditor();
      }
      });

      function createEditor() {
      StackExchange.prepareEditor({
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: true,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: 10,
      bindNavPrevention: true,
      postfix: "",
      imageUploader: {
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      },
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      });


      }
      });






      Ryan is a new contributor. Be nice, and check out our Code of Conduct.










      draft saved

      draft discarded


















      StackExchange.ready(
      function () {
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f961617%2fhow-do-i-point-www-example-com-to-a-example-com%23new-answer', 'question_page');
      }
      );

      Post as a guest















      Required, but never shown

























      3 Answers
      3






      active

      oldest

      votes








      3 Answers
      3






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      1














      So you can check my comments for a little bit of insight on how to troubleshoot your issue. But I suppose a definitive answer to how DNS records work and how to achieve the redirection you are looking for would be more appropriate. RFCs probably are the proper way to site sources, but I like to explain with my own examples. So I will provide screen shots from my Windows 2016 Active Directory server that runs DNS locally on the server as well. Now if you use something like bind on Linux/Windows then the concepts should hold true, but obviously a different approach to configuration.



      So your DNS server is going to have a Forward Lookup zone configured for your domain. Mine for this instance is digiecho.xyz as you can see in the screenshot below:



      DNS Forward Zone Example



      In the lookup zone you can see that I have an assortment of A records that point to IP addresses. These are the most common types of records created in my experience. So you should have one A record where your www.domain.com points to some IP. For my example I'm going to use my A record for VC01.



      A CNAME or Canonical Name allows you to create used to alias one name to another. I'm going to create a CNAME record vcenter.digiecho.xyz and point it to my A record VC01 (see screen shot below for record creation example, and info on CNAMEs):



      https://support.dnsimple.com/articles/cname-record/



      CNAME Record Creation



      You then can use DNS tools like dig or nslookup to troubleshoot what is going on. Since this is all on my internal network I just used nslookup from another server on my virtual host to show some relevant outputs to help you in your troubleshooting:



      nslookup Example



      As you can see it not only tells me the true canonical domain the alias points to. However it should report back the server that is reporting back the record. So if you have like a master-slave configuration in your DNS environment you will want to make sure the zone transfers have occurred from the master to all the slaves to ensure that they all have the correct. If you are using Linux just man dig for the command parameters. But really those basic DNS checks and troubleshooting should be sufficient to solve a CNAME issue.






      share|improve this answer




























        1














        So you can check my comments for a little bit of insight on how to troubleshoot your issue. But I suppose a definitive answer to how DNS records work and how to achieve the redirection you are looking for would be more appropriate. RFCs probably are the proper way to site sources, but I like to explain with my own examples. So I will provide screen shots from my Windows 2016 Active Directory server that runs DNS locally on the server as well. Now if you use something like bind on Linux/Windows then the concepts should hold true, but obviously a different approach to configuration.



        So your DNS server is going to have a Forward Lookup zone configured for your domain. Mine for this instance is digiecho.xyz as you can see in the screenshot below:



        DNS Forward Zone Example



        In the lookup zone you can see that I have an assortment of A records that point to IP addresses. These are the most common types of records created in my experience. So you should have one A record where your www.domain.com points to some IP. For my example I'm going to use my A record for VC01.



        A CNAME or Canonical Name allows you to create used to alias one name to another. I'm going to create a CNAME record vcenter.digiecho.xyz and point it to my A record VC01 (see screen shot below for record creation example, and info on CNAMEs):



        https://support.dnsimple.com/articles/cname-record/



        CNAME Record Creation



        You then can use DNS tools like dig or nslookup to troubleshoot what is going on. Since this is all on my internal network I just used nslookup from another server on my virtual host to show some relevant outputs to help you in your troubleshooting:



        nslookup Example



        As you can see it not only tells me the true canonical domain the alias points to. However it should report back the server that is reporting back the record. So if you have like a master-slave configuration in your DNS environment you will want to make sure the zone transfers have occurred from the master to all the slaves to ensure that they all have the correct. If you are using Linux just man dig for the command parameters. But really those basic DNS checks and troubleshooting should be sufficient to solve a CNAME issue.






        share|improve this answer


























          1












          1








          1







          So you can check my comments for a little bit of insight on how to troubleshoot your issue. But I suppose a definitive answer to how DNS records work and how to achieve the redirection you are looking for would be more appropriate. RFCs probably are the proper way to site sources, but I like to explain with my own examples. So I will provide screen shots from my Windows 2016 Active Directory server that runs DNS locally on the server as well. Now if you use something like bind on Linux/Windows then the concepts should hold true, but obviously a different approach to configuration.



          So your DNS server is going to have a Forward Lookup zone configured for your domain. Mine for this instance is digiecho.xyz as you can see in the screenshot below:



          DNS Forward Zone Example



          In the lookup zone you can see that I have an assortment of A records that point to IP addresses. These are the most common types of records created in my experience. So you should have one A record where your www.domain.com points to some IP. For my example I'm going to use my A record for VC01.



          A CNAME or Canonical Name allows you to create used to alias one name to another. I'm going to create a CNAME record vcenter.digiecho.xyz and point it to my A record VC01 (see screen shot below for record creation example, and info on CNAMEs):



          https://support.dnsimple.com/articles/cname-record/



          CNAME Record Creation



          You then can use DNS tools like dig or nslookup to troubleshoot what is going on. Since this is all on my internal network I just used nslookup from another server on my virtual host to show some relevant outputs to help you in your troubleshooting:



          nslookup Example



          As you can see it not only tells me the true canonical domain the alias points to. However it should report back the server that is reporting back the record. So if you have like a master-slave configuration in your DNS environment you will want to make sure the zone transfers have occurred from the master to all the slaves to ensure that they all have the correct. If you are using Linux just man dig for the command parameters. But really those basic DNS checks and troubleshooting should be sufficient to solve a CNAME issue.






          share|improve this answer













          So you can check my comments for a little bit of insight on how to troubleshoot your issue. But I suppose a definitive answer to how DNS records work and how to achieve the redirection you are looking for would be more appropriate. RFCs probably are the proper way to site sources, but I like to explain with my own examples. So I will provide screen shots from my Windows 2016 Active Directory server that runs DNS locally on the server as well. Now if you use something like bind on Linux/Windows then the concepts should hold true, but obviously a different approach to configuration.



          So your DNS server is going to have a Forward Lookup zone configured for your domain. Mine for this instance is digiecho.xyz as you can see in the screenshot below:



          DNS Forward Zone Example



          In the lookup zone you can see that I have an assortment of A records that point to IP addresses. These are the most common types of records created in my experience. So you should have one A record where your www.domain.com points to some IP. For my example I'm going to use my A record for VC01.



          A CNAME or Canonical Name allows you to create used to alias one name to another. I'm going to create a CNAME record vcenter.digiecho.xyz and point it to my A record VC01 (see screen shot below for record creation example, and info on CNAMEs):



          https://support.dnsimple.com/articles/cname-record/



          CNAME Record Creation



          You then can use DNS tools like dig or nslookup to troubleshoot what is going on. Since this is all on my internal network I just used nslookup from another server on my virtual host to show some relevant outputs to help you in your troubleshooting:



          nslookup Example



          As you can see it not only tells me the true canonical domain the alias points to. However it should report back the server that is reporting back the record. So if you have like a master-slave configuration in your DNS environment you will want to make sure the zone transfers have occurred from the master to all the slaves to ensure that they all have the correct. If you are using Linux just man dig for the command parameters. But really those basic DNS checks and troubleshooting should be sufficient to solve a CNAME issue.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered yesterday









          Dion PezzimentiDion Pezzimenti

          130119




          130119

























              1














              A CNAME record should not point to another CNAME record.



              Find out where your a.example.com CNAME actually points to, and then set your www.example.com CNAME to also point directly to that.






              share|improve this answer


























              • A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

                – Patrick Mevzek
                3 mins ago
















              1














              A CNAME record should not point to another CNAME record.



              Find out where your a.example.com CNAME actually points to, and then set your www.example.com CNAME to also point directly to that.






              share|improve this answer


























              • A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

                – Patrick Mevzek
                3 mins ago














              1












              1








              1







              A CNAME record should not point to another CNAME record.



              Find out where your a.example.com CNAME actually points to, and then set your www.example.com CNAME to also point directly to that.






              share|improve this answer















              A CNAME record should not point to another CNAME record.



              Find out where your a.example.com CNAME actually points to, and then set your www.example.com CNAME to also point directly to that.







              share|improve this answer














              share|improve this answer



              share|improve this answer








              edited 2 mins ago









              Patrick Mevzek

              2,87731225




              2,87731225










              answered yesterday









              telcoMtelcoM

              2,737715




              2,737715













              • A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

                – Patrick Mevzek
                3 mins ago



















              • A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

                – Patrick Mevzek
                3 mins ago

















              A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

              – Patrick Mevzek
              3 mins ago





              A CNAME record can absolutely point to another CNAME there is nothing wrong about that, you just need to be careful as it may have consequences on resolution time. It fact it happens often nowadays with the use of CDNs, just try to resolve www.microsoft.com you will see a chain of 3 CNAME records!

              – Patrick Mevzek
              3 mins ago











              0














              name                optional_TTL   CLASS   RR      canonical name
              www.example.net. 3600 IN CNAME a.example.com.


              Simplified a DNS CNAME record does nothing more than pointing a DNS record to the canonical name of another host by using that hosts DNS name rather than by creating an A entering that hosts IP-address.



              After that DNS change you will usually need to reconfigure a.example.com and make the services running there aware of the fact they can be accessed by an additional hostname www.example.net. rather than only via a.example.com.



              If you don't do that, things may work out, for instance a web server running plain http and only one website will display that website regardless of the hostname used to access the web server, but for a web server running multiple virtual hosts on HTTPS you will need to both request a new TLS certificate with the www.example.net. domain name AND you need to either create a new virtual host entry, or add www.example.net. to a specific existing virtual host.






              share|improve this answer




























                0














                name                optional_TTL   CLASS   RR      canonical name
                www.example.net. 3600 IN CNAME a.example.com.


                Simplified a DNS CNAME record does nothing more than pointing a DNS record to the canonical name of another host by using that hosts DNS name rather than by creating an A entering that hosts IP-address.



                After that DNS change you will usually need to reconfigure a.example.com and make the services running there aware of the fact they can be accessed by an additional hostname www.example.net. rather than only via a.example.com.



                If you don't do that, things may work out, for instance a web server running plain http and only one website will display that website regardless of the hostname used to access the web server, but for a web server running multiple virtual hosts on HTTPS you will need to both request a new TLS certificate with the www.example.net. domain name AND you need to either create a new virtual host entry, or add www.example.net. to a specific existing virtual host.






                share|improve this answer


























                  0












                  0








                  0







                  name                optional_TTL   CLASS   RR      canonical name
                  www.example.net. 3600 IN CNAME a.example.com.


                  Simplified a DNS CNAME record does nothing more than pointing a DNS record to the canonical name of another host by using that hosts DNS name rather than by creating an A entering that hosts IP-address.



                  After that DNS change you will usually need to reconfigure a.example.com and make the services running there aware of the fact they can be accessed by an additional hostname www.example.net. rather than only via a.example.com.



                  If you don't do that, things may work out, for instance a web server running plain http and only one website will display that website regardless of the hostname used to access the web server, but for a web server running multiple virtual hosts on HTTPS you will need to both request a new TLS certificate with the www.example.net. domain name AND you need to either create a new virtual host entry, or add www.example.net. to a specific existing virtual host.






                  share|improve this answer













                  name                optional_TTL   CLASS   RR      canonical name
                  www.example.net. 3600 IN CNAME a.example.com.


                  Simplified a DNS CNAME record does nothing more than pointing a DNS record to the canonical name of another host by using that hosts DNS name rather than by creating an A entering that hosts IP-address.



                  After that DNS change you will usually need to reconfigure a.example.com and make the services running there aware of the fact they can be accessed by an additional hostname www.example.net. rather than only via a.example.com.



                  If you don't do that, things may work out, for instance a web server running plain http and only one website will display that website regardless of the hostname used to access the web server, but for a web server running multiple virtual hosts on HTTPS you will need to both request a new TLS certificate with the www.example.net. domain name AND you need to either create a new virtual host entry, or add www.example.net. to a specific existing virtual host.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered yesterday









                  HBruijnHBruijn

                  56.1k1190150




                  56.1k1190150






















                      Ryan is a new contributor. Be nice, and check out our Code of Conduct.










                      draft saved

                      draft discarded


















                      Ryan is a new contributor. Be nice, and check out our Code of Conduct.













                      Ryan is a new contributor. Be nice, and check out our Code of Conduct.












                      Ryan is a new contributor. Be nice, and check out our Code of Conduct.
















                      Thanks for contributing an answer to Server Fault!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid



                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.


                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function () {
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f961617%2fhow-do-i-point-www-example-com-to-a-example-com%23new-answer', 'question_page');
                      }
                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      As a Security Precaution, the user account has been locked The Next CEO of Stack OverflowMS...

                      Список ссавців Італії Природоохоронні статуси | Список |...

                      Українські прізвища Зміст Історичні відомості |...