Adding IPv6 Functionality

DirectAdmin is a fantastic control panel and obviously, the one we recommend to all of our clients. However, our one complaint is that IPv6 capability is not activated by default. Luckily, enabling IPv6 is very easy. Parts of this guide were taken directly from the How-To written by DirectAdmin here, so all credit goes to them. Please be sure to read this guide in it's entirety and see our special note at the bottom.

1) The first step, is to tell DirectAdmin that you want to use IPv6.  To do this, add this to your /usr/local/directadmin/conf/directadmin.conf, and restart DirectAdmin:

ipv6=1


2) Adding IPs to DirectAdmin is done the same way as with IPv4 IPs:
Admin Level -> IP Manager

Note that the netmask 255.255.255.0 only applies for IPv4 IPs and will be ignored here.
The IPv6 mask format, eg: /64 is not yet supported.  When adding IPs you can use either the full or short form, but DA will expand it to the full format of IPv6 values.  Don't use [] around the IP here, just the IP is fine, eg:  1:2::9

3) You can assign IPs to Users normally, as with IPv4.  As of 1.37.0, the multi-IP system allows you to assign both an IPv4 and IPv6 IP to an account.  See this guide on how to do that.
NOTE: If you're upgrading to 1.37.0+, and want to use the mutli-IP system, you must convert to the unified ftp password format.  Systems installed with 1.37.0 won't need to.   You'll know you need to convert if you can't find the tables for "Additional IPs".

4) The DNS system should be ready for IPv6.  We have the dns_a.conf and dns_aaaa.conf default records for newly created zones.  Each of these template files have checks on the IP type.  When an IP is sent to the template, the IP type is also included, so the template can chose to ignore adding any records if the IP type doesn't match it's format, or (with customization) you can add some other value if you'd like.  For most people, leaving it along will be best.
NOTE:  Backup/Restores with the multi-ip system and dns are yet complete.   If you use multiple IPs on a domain, you may need to adjust the zone after restore as the "Additional IPs" may still be in the zone, even if the account is on a different IP.



Services

In order to connect to to a service with IPv6, that service must be compiled to support IPv6.

DirectAdmin: For 1.37.0 and older, DirectAdmin can setup configs with IPv6, but doesn't support IPv6 for connections on port 2222.
However, for 1.37.1, DirectAdmin can now allow incoming connections on IPv6 on 2222.

Apache: Apache support IPv6 out of the box. No need for changes.

Exim:Exim does support IPv6, but you need to ensure it's compiled in.  To check, type:

[root@server ~]# /usr/sbin/exim -bV | grep Support
Support for: crypteq IPv6 Perl OpenSSL move_frozen_messages Content_Scanning DKIM Old_Demime

which should give you an output similar to above.  Ensure you see IPv6 in the output.
If you don't see IPv6 in the output, then you'll need to recompile exim, either using rpms, or from source.  The latest Makefiles should have the required HAVE_IPV6=YES to ensure it's included.

Dovecot:If you're using the latest version of Dovecot 2.0.x, edit your /etc/dovecot.conf.  You'll see these lines:

#IPv4
listen = *

#IPv4 and IPv6:
#listen = *, ::

Change them to look like this, then restart dovecot:

#IPv4
#listen = *

#IPv4 and IPv6:
listen = *, ::

For Dovecot 1.2.x, add this to your /etc/dovecot.conf (top section) and restart dovecot:

listen = "*, [::]"


ProFTPd: Apache support IPv6 out of the box. No need for changes.

Bind:(named) You might need to add this code to the options section of your named.conf:

listen-on-v6 port 53 { any; };

Special Note: IPv6 is now activated on your server but if you want to enable your websites to use BOTH IPv6 and IPv4, you will need to bind the IP addresses. Without doing this step, enabling IPv6 will be pointless as all your websites will continue to use IPv4. To do this, login to DirectAdmin as admin and go to the IP Management section under Admin Tools. From there, obviously add your first IPv6 address. Once this has been done, click on the IPv4 address that you want to bind the IPv6 address to. Under the section Select an IP to Link to xxx.xxx.xxx.xxx select the IPv6 address you wish to use from the drop down menu. Ensure the tick boxes Add to DNS, Add to Apache, and Apply to existing Domains are checked and click Link. Now any website that was using the IPv4 address will also use the IPv6 address as well. If you have other IPv4 addresses, you can do this for them as well and repeat the process until each IPv4 address is linked with an IPv6 address. If you have a website that you don't want IPv6 activated for, just don't link its dedicated IP address to an IPv6.

Obviously, you can also enable IPv6 websites too by assigning just an IPv6 address as a dedicated IP address to a specific website. However, ensure that you have at least one IPv6 enabled name servers on the server, otherwise the domain you have done this for will not resolve.

That's it, your server and all its websites are now both IPv4 and IPv6 enabled. As IPv4 becomes depleted, it will be more and more important to ensure your server has IPv6 enabled. Since Mean Servers supports IPv6 natively and not through some tunnel, it just makes sense to enable IPv6 from the start, that way you won't need to worry about it in the future. If you need IPv6 addresses. contact our Sales Department, there is no charge for having IPv6 addresses issued!

  • 88 Users Found This Useful
Was this answer helpful?

Related Articles

Protect DirectAdmin from Brute Force Attacks

A common method of gaining access over a server is to use a technique called a brute force...

Upgrading to MariaDB 10 from MySQL 5.6 with DirectAdmin

MariaDB 10 is the next generation of MySQL and improves on both speed and performance over MySQL...

Change Domain in DirectAdmin

This tutorial was written for those wishing to change their domain when using DirectAdmin as...