What is the proper way to add a domain and set the A to resolve to a diffrent IP?

bcoker

Verified User
Joined
Sep 7, 2010
Messages
55
Hi All,

What is the proper way to add a domain and set the A to resolve to a diffrent IP? The user can have space here if that's required.

When I added my main .com in and the my .net wich is on another server that I will use for backup and whatnot, .net it just worked no problems at all.

Now my .net has the outside IP for all the records " I don't remember doing that". and thats the only difference for this new one, it has the main ip of the server for all theA records.

What I do is, I add the domain, go to DNS Management and delete the current A, and add a new A with the outside IP. Sometime I wait for a couple minutes sometimes I rndc reload the zone, However it still resolves to the server even when DNS outside reports the outside IP as the A record.

What good practices should I be using here? Also, what's the need for the localhost record. Never seen a A with that before.

WORKING - A set to another machine;

Code:
$TTL 14400
@       IN      SOA     ns1.ioncode.com.      hostmaster.ioncode.net. (
                                                2010091100
                                                14400
                                                3600
                                                1209600
                                                86400 )

ioncode.net.	14400	IN	NS	ns1.ioncode.com.
ioncode.net.	14400	IN	NS	ns2.ioncode.com.

ftp	14400	IN	A	173.230.131.64
ioncode.net.	14400	IN	A	173.230.131.64
localhost	14400	IN	A	127.0.0.1
mail	14400	IN	A	173.230.131.64
pop	14400	IN	A	173.230.131.64
smtp	14400	IN	A	173.230.131.64
www	14400	IN	A	173.230.131.64

ioncode.net.	14400	IN	MX	10 mail

NOT WORKING - A set to another machine;

Code:
$TTL 14400
@       IN      SOA     ns1.ioncode.com.      hostmaster.agncpa.com. (
                                                2010091200
                                                14400
                                                3600
                                                1209600
                                                86400 )

agncpa.com.	14400	IN	NS	ns1.ioncode.com.
agncpa.com.	14400	IN	NS	ns2.ioncode.com.

agncpa.com.	14400	IN	A	209.98.54.241
ftp	14400	IN	A	173.230.132.243
localhost	14400	IN	A	127.0.0.1
mail	14400	IN	A	173.230.132.243
pop	14400	IN	A	173.230.132.243
smtp	14400	IN	A	173.230.132.243
www	14400	IN	A	173.230.132.243

agncpa.com.	14400	IN	MX	10 mail



agncpa.com.	14400	IN	TXT	"v=spf1 a mx ip4:173.230.132.243 ~all"

Thank you.
 
Deleting and adding A records should be fine. Sometimes I restart bind if I don't want to wait.

But your nameservers ns1/2.ioncode.com aren't responding at all to querys, so no domains on those will resolve.
 
Arieh, Thank you. I rebuilt the VM this morning and reinstalled DA, this is why querys were failing for you. But for some reason I can't get the NS IPs to add right. This should be so simple but ever post on the subject is different. I'm Rebuilding again now and going to try again and try with this method.

http://www.directadmin.com/forum/showthread.php?s=&threadid=130

Setup Your Nameservers

To setup your nameservers, simply do the following:

- Login to your DirectAdmin panel as "admin"
- Go to your IP Management section, and add two new IP addresses
- Once they are added, click the check boxes next to the two IPs that you've just submitted. Assign these IPs to "admin"
- Now go to your Reseller panel, and navigate to your Nameserver section
- On this page, create your two nameservers, generally ns1. and ns2.
- Finally, go back to your Admin panel and go to your Administrator Settings page. Set your nameservers to the ones you have just created and save your changes.
 
Back
Top