ISPConfig and IPv6 in a mirror-setup 1

I use ISPConfig one some servers running in a mmirror-enviroment. Since IPv6 ist the way to use within the next years, i need a way to add a individual IPv6 for each vhost and this IP must be set, according to the subnet, on each mirror.

You can easily add a webdomain with a defined address within the interface. The ip will be written to the database.

I have for example the subnets Subnets 2a01:4f8:150:2262::/64 (Master-Server) and 2a01:4f8:120:1084::/64 (Mirror-Server).

Since the IP on the mirror is fetched from the database, only this ip will be written to each vhost. But the (mirror)server can´t of course listen to a foreign ip.

The solution is quite simple: if a vhost is written, the IPv6 must be changed so it fits the local subnet.

If i add a website with IPv6 2a01:4f8:150:2262::aaaa, the prefix (2a01:4f8:150:2262::) will be changed on the mirror with the own (2a01:4f8:150:2262::).

First we define the subnet in /usr/local/ispconfig/server/lib/

And add a few lines to (just behind if($data['new']['ipv6_address'] != '') {
(in ISPConfig- it´s line 1052)

if (isset($conf['ipv6_subnet']) && $conf['ipv6_subnet'] <> '') {
for ( $i = 0; $i <= count($explode_v6prefix)-3; $i++ ) {
$explode_v6[$i] = $explode_v6prefix[$i];} $data['new']
['ipv6_address'] = implode(':',$explode_v6);

//** IP-handling

Leave a comment

Your email address will not be published. Required fields are marked *

I confirm

One thought on “ISPConfig and IPv6 in a mirror-setup