Questions tagged [dns]

DNS QUESTIONS MUST BE PROGRAMMING RELATED. Use this tag for programming questions related to writing code that interacts with the Domain Name System (DNS); for example, writing code that uses gethostbyname()

Don’t use this tag for questions that aren’t about programming. StackOverflow as a site is only for questions about programming. If you have a DNS-related question about server configuration, DNS configuration, or other non-programming questions, consider instead posting on:

Background information on DNS

The Domain Name System (DNS) is a hierarchical naming system built on a distributed database. It translates domain names meaningful to humans into the IP addresses associated with the networking device. For example: www.stackoverflow.com => 64.34.119.12

One thing that DNS makes possible is changing the IP address while not changing the name. This allows moving the site to another provider, without requiring users to learn anything new. It is also possible to have several different DNS names resolve to the same IP address, and have the same http web server at that IP address handle the different names as different websites.

As already stated, DNS is hierarchical and distributed system. In looking up cs.luc.edu four different DNS servers may be required: for the so-called "DNS root zone", for edu, for luc.edu and cs.luc.edu. Searching hierarchy can be cumbersome, so DNS search results are usually cached locally.

Specification

The concepts of the Domain Name System are explained in RFC1034. The specification and implementation are described in RFC1035.

Reference

Domain Name System on Wikipedia

An Introduction to Computer Networks by Peter L Dordal


16205 questions
147
votes
5 answers

Set up DNS based URL forwarding in Amazon Route53

I'm trying to setup forwarding in Amazon Route53. My last DNS service (Nettica) allowed me to route requests to "aws.example.com" to "https://myaccount.signin.aws.amazon.com/console/". Is this functionality supported by Route53? How does Nettica…
Saurav
  • 2,906
  • 3
  • 17
  • 12
145
votes
11 answers

jquery, domain, get URL

How can I get the domain name with jquery ??
AlexC
  • 9,529
  • 17
  • 61
  • 96
137
votes
1 answer

Nginx Different Domains on Same IP

I would like to host 2 different domains in the same server using nginx. I redirected both domains to this host via @ property. Although I configure 2 different server blocks, whenever I try to access second domain, it redirects to first one. Here…
berkayk
  • 2,268
  • 3
  • 18
  • 26
134
votes
15 answers

Using DNS to redirect to another URL with a path

I'm trying to redirect a domain to another via DNS. I know that using IN CNAME it's posible. www.proof.com IN CNAME www.proof-two.com. What i need is a redirection with a path. When someone types www.proof.com, it should take them to to…
contacto contact
  • 1,373
  • 2
  • 9
  • 3
124
votes
9 answers

Create subdomains on the fly with .htaccess (PHP)

I am looking to create a system which on signup will create a subdomain on my website for the users account area. e.g. johndoe.website.com I think it would be something to do with the .htaccess file and possibly redirecting to another location on…
Ben McRae
  • 3,411
  • 11
  • 34
  • 30
122
votes
5 answers

RRSet of type CNAME with DNS name foo.com. is not permitted at apex in zone bar.com

I own foo.com and bar.com. I am managing both in Route53. foo.com hosts my site, and I'd like to direct traffic from bar.com to foo.com. I tried to set up a CNAME record for bar.com pointing to foo.com, but I got the error message: RRSet of type…
fredley
  • 29,323
  • 39
  • 131
  • 223
121
votes
8 answers

How to overcome root domain CNAME restrictions?

We are hosting many web applications for our customers. As is obvious they want to use their own domains to refer to those applications, usually they want that any user that either type http://www.customer1.example or http://customer1.example goes…
Geo
  • 8,329
  • 13
  • 61
  • 90
120
votes
4 answers

Static hosting on Amazon S3 - DNS Configuration

I'm working on a little webapp (all client-side) I want to host it on Amazon S3. I've found several guides on this and have managed to create myself a bucket (with the same name as my domain), set it as a website and upload some content. Where I'm…
Merlin Mason
  • 1,547
  • 2
  • 11
  • 12
111
votes
4 answers

How to link godaddy domain with AWS Elastic Beanstalk environment?

I'm running into this problem trying to link my Godaddy domain with an AWS Elastic Beanstalk instance. I found a lot of documentation on how to link an EC2 instance with a domain on Godaddy but not for Elastic Beanstalk instance. So I ended up with…
Bob Bill
  • 1,111
  • 2
  • 8
  • 3
109
votes
4 answers

Set up Heroku and GoDaddy?

I am trying to get a domain name I bought through GoDaddy to work with my Heroku hosted site. How do I configure my domain name to work with Heroku?
allegutta
  • 5,487
  • 8
  • 35
  • 51
107
votes
7 answers

How to make Java honor the DNS Caching Timeout?

We use GSLB for geo-distribution and load-balancing. Each service is assigned a fixed domain name. Through some DNS magic, the domain name is resolved into an IP that's closest to the server with least load. For the load-balancing to work, the…
ZZ Coder
  • 70,824
  • 28
  • 129
  • 163
106
votes
8 answers

Does hosts file exist on the iPhone? How to change it?

I am developing an application that query to the server. In my Mac, I use the hosts file to change the dns to point to a local server within my local area network. Now I need to test it with my iPhone, the problem is that my iPhone does not…
Hoang Pham
  • 6,789
  • 11
  • 54
  • 69
105
votes
17 answers

Get the subdomain from a URL

Getting the subdomain from a URL sounds easy at first. http://www.domain.example Scan for the first period then return whatever came after the "http://" ... Then you remember http://super.duper.domain.example Oh. So then you think, okay, find the…
jb.
  • 9,477
  • 11
  • 37
  • 35
103
votes
13 answers

How can I eliminate slow resolving/loading of localhost/virtualhost (a 2-3 second lag) on Mac OS X Lion?

Since setting up my development environments on Mac OS X Lion (brand new macbook air purchased in January 2012), I have noticed that resolving to a virtual host is very slow (around 3 seconds) the first time but after that is fast as long as I…
Adam Gries
  • 1,661
  • 3
  • 14
  • 11
101
votes
7 answers

How to configure heroku application DNS to Godaddy Domain?

I have created a heroku application and wants to give domain to it from godaddy.com. I have configured all three hosts provided by heroku but now I am getting error saying: Heroku | No such app There is no app configured at that hostname. Perhaps…
Arpit Vaishnav
  • 4,487
  • 6
  • 34
  • 52