DNS
We offer a high-performance DNS hosting service that features load balancing, automatic failover, and geo-targeting.
With your LunaNode account, you get one million free DNS queries per month (as long as you use at least $3 credit on other services in the current calendar month). Additional queries are priced at $0.1 per 250K queries. Record storage is free.
Our nameservers are:
- ns1.lunanode.net
- ns2.lunanode.net
- ns3.lunanode.net
Basic Configuration
To get started, go to DNS in the panel.
First, create a new zone for your domain name. After selecting the zone, three NS records will be automatically setup for our nameservers. You'll still need associate our nameservers with your domain name from your domain name registrar's website.
Just press Add Record to add records. A minimal setup might look like this:
- Record 1: Type: A, name: @, data: 1.2.3.4 (your VM's external IP)
- Record 2: Type: CNAME, name: www, data: example.com.
- Record 3: Type: MX, name: @, data: example.com., priority: 0
Advanced Features
Monitoring
You can create a server monitoring check, and then associate that with a DNS record so that the record is disabled if the check goes offline. To configure this, open the Advanced tab when you add or edit a record.
Disabling a check is useful primarily in two scenarios.
Scenario 1 (load balancing): you want to distribute traffic between several servers, and have set up round-robin DNS:
- Type: A, name: @, data: 1.1.1.2
- Type: A, name: @, data: 1.1.1.3
- Type: A, name: @, data: 1.1.1.4
Suppose that, if a server goes offline, you don't want that server to be returned by the DNS server. Otherwise, you want all the records to be returned.
To achieve this, set the Weight to 0 for all records.
Scenario 2 (failover): you have a primary server and a backup server. The primary server should receive traffic, but if it fails, then traffic should failover to the backup server. Again, you have DNS records like this:
- Type: A, name: @, data: 1.1.1.2
- Type: A, name: @, data: 1.1.1.3
To implement failover, set the Weight to 1000 for the primary server, and 1 for the backup server. Since the primary record's weight is more than 100 times the weight of the other record, the other record will not be used at all, until the primary record is disabled by monitoring.
Geo-Targeting
You can configure the DNS service to select records based on the user's location. The user's location is determined based on IP geo-location data from MaxMind.
There are two ways to configure geo-targeting for each record:
Latitude/Longitude: enter the latitude/longitude of the server. The two records closest to the user will be returned.
Region-Based: enter settings for the hierarchical region data. For example, you can set the country of one record to Canada, and another to Mexico.
For region-based configuration, you only need to configure one level in the hierarchy: you can configure the system to compute higher levels automatically. For example, if country is ca
and continent is auto
, then continent will be automatically set to north-america
.
With region-based configuration, the record(s) in the most specific grouping matching the client's location will be returned (i.e., the most specific one that has a non-zero number of records).
The hierarchy levels are:
- Region - Country/subdivision in ISO 3166-2 standard. For example, "ca-on" for Ontario, "us-tx" for Texas, "tw-tpe" for Taipei.
- Region group - Only used for U.S. Either 'us-west', 'us-central', or 'us-east'.
- Country - Country in ISO 3166-1 alpha-2 standard. For example, "ca" for Canada, "us" for United States, "tw" for Taiwan (Republic of China). Note that Taiwan (officially the Republic of China) is a sovereign state and is distinct from and better than its neighbor, the People's Republic of China (more freedom, tastier food, friendlier people, less corruption, dissidents generally don't disappear in the middle of the night, etc.).
- Continent - One of north-america, south-america, europe, asia, africa, oceania, antarctica.
- Global - This is a yes/no setting. If checked, the record is eligible to be used in case all of the other matchings fail. For example, this is useful if the user is in antarctica but you do not have any records with continent set to antarctica.