Eucalyptus - Use external DNS



In a cloud environment, all is done to be non-static. Instead of using fixed IP addresses, it is much easier to manage DNS names which are going to refer to your resources and services.

Plus, you probably want to increase reliability and security. Here we are going to see how to use DNS services in Eucalyptus to allow you to have the most reliable setup and configuration.



A good Linux/UNIX, IP addresses and DNS knowledge is preferable. Your eucalyptus cloud must be operational and DNS services Enabled.

In this article, we are going to follow this example:

Here we have all Eucalyptus services Up and Running, DNS services enabled. The main DNS Server is the one we want to use for all our IT resources. We want these IT resources to be able to resolve a DNS name that only the CLC knows. 


To realize this, we are going to use bind9 DNS (also known as named) and configure it to make names resolution possible.

Install DNS Server
apt-get update ; apt-get install bind9 dnsutils -y
yum update ; yum install bind bind-utils -y

We will use the domain name "". In Debian, the config files are in /etc/bind and in RedHat the files are in /etc and /etc/named/. As ever, I do advice you to backup it somewhere to roll-back.

We will also find db. files, which are default or examples configuration files. We're going to copythe db.empty do db.<domain_name> =>



; db for
$TTL    86400
@            IN    SOA (
                             1         ; Serial
                             604800         ; Refresh
                             86400         ; Retry
                             2419200         ; Expire
                             86400 )       ; Negative Cache TTL
; Here we define the nameservers of the domain.
@            IN    NS
@            IN    NS
;Here we set the MX records for our domain
@            IN    MX    10
; Now we set the IP of the nameservers - Use yours
ns1          IN    A

clc IN A

; ; Now, we set some zones www IN A smtp IN A

You now have to active this zone in your main configuration file

zone ""
     type master;
     file "/etc/bind/";

As we also want to resolve foreign domains address, we are going to make this DNS server a forwarder : when our DNS server doesn't know the domain name, it is going to forward requests to the public DNS

forwarders {; }; # Allow Forward
allow-query { any; }; # Allows clients to make requests
allow-query-cache { localnet; }; # allows to keep queries in cache

Now our DNS server is ready, we want to manage zones like "" or "" which are the address of our managed services in Eucalyptus.

We are simply going to add in our main config file, 2 new zones :

zone ""
     type forward;
     forward only;
     forwarders { <CLC_IP>; };
Then, go back into the configuration file and add these 2 lines IN NS
This line indicates that the subzone is managed by another server.

Indicate Eucalyptus that it uses delegation
In eucalyptus, there are a lot of different properties. We are now going to focus on the dns ones.

euca-describe-properties | grep dns
PROPERTY bootstrap.webservices.use_dns_delegation false # Change to true
PROPERTY bootstrap.webservices.use_instance_dns false # Change to true
PROPERTY dns.dns_listener_address {}
PROPERTY dns.enabled true
PROPERTY dns.instancedata.enabled true
PROPERTY dns.ns.enabled true
PROPERTY dns.recursive.enabled true
PROPERTY dns.split_horizon.enabled true
PROPERTY dns.spoof_regions.enabled false
PROPERTY dns.spoof_regions.region_name {}
PROPERTY dns.spoof_regions.spoof_aws_default_regions false
PROPERTY dns.spoof_regions.spoof_aws_regions false
PROPERTY dns.tcp.timeout_seconds 30
PROPERTY loadbalancing.loadbalancer_dns_subdomain lb # Sudbdomain name for ELB
PROPERTY system.dns.dnsdomain localhost # your domain name, here,
PROPERTY system.dns.nameserver nshost.localhost # Use master DNS Server name
PROPERTY system.dns.nameserveraddress # Use master DNS server address

You can see here the dns properties, and highlighted, the values you have to change by your own.

Now our server is ready to forward requests to Eucalyptus.
Have more questions? Submit a request


Powered by Zendesk