dns configuration question.
Hi
I wondering if is possible to configure my local dns server to forward all traffic for a certain dns prefix to one ip address. e.g. all traffic for xyz.* goes to 192.168.0.4 so xyz.example.com and xyz.anything.com would point to 192.168.0.4 The reason I would want to do this is my company has a lot of urls and i would like users to be able to switch between the remote live server and local test server by changing prefix. e.g. www.example.com points to live but xyz.example.com points to test. Adding the test urls manually would be really time consuming and the list grows constantly. Is it possible ? Thanks J. |
John,
Since you're going to have to have individual zone files for each domain, I can't see how you would gain from this strategy. There's no overall zone file for all domains. If there were, then your server would have to be authoritative for every domain! You will need to use something like xyz IN A 192.168.0.4 www IN A 1.2.3.4 for each zone file. |
Yes you can. Look at Apache Virtual Hosting.
|
Sorry Aurora, but I think that's wrong.
Apache virtual hosting will let you have multiple hosts pointed to the same IP and will serve different websites according to the hostname specified in the http request. e.g.: In example.com zone file: www.example.com IN A 192.168.0.4 xyz.example.com IN A 192.168.0.4 In anything.com zone file: www.anything.com IN A 192.168.0.4 xyz.anything.com IN A 192.168.0.4 Virtual hosting will allow you to server between 1 and 4 different sites for each of these hostnames. However you still need to have different zone files for each domain. AS such, it doesn't answer John's question as to whether it's possible to have a single zone file where www.* and xyz.* (using * as a wildcard here) will work. The answer is that it won't. There's no such thing as a universal zone file. Carl. |
All times are GMT -5. The time now is 06:11 AM. |