• Debian 11 is approaching its end-of-life (vendor EOL date - August 31, 2026). Plesk Obsidian 18.0.80 will be the last release to support it.
    If you are running Plesk Obsidian on Debian 11, we recommend you upgrade those servers to Debian 12 using our dist-upgrade tool.
  • We plan to deprecate and remove the support for XML RPC protocol versions earlier than 1.6.9.1 in Plesk Obsidian 18.0.82. We strongly recommend that you update all existing integrations using earlier versions of the XML RPC protocol to comply with the version 1.6.9.1 specification.

Adding a whole range instead of individual IPv6 addresses

Ross_Fisher

New Pleskian
Greetings!

My provider provides a /64 block of IPv6 addresses to use. In cPanel, I could simply dump in the range and mass automagically enable a unique IPv6 address for each domain/account.

I have IPv6 addresses 2001:19f0:4009:4204:0000:0000:0000:0000-
2001:19f0:4009:4204:ffff:ffff:ffff:ffff

How do I add a range into Plesk and have it assign an IPv6 per account/domain?
 
Hi Ross_Fisher,

due to the case that there is no "automatic" assignment - feature, you might find it interesting to read this external article:

http://www.ispcolohost.com/2013/07/11/create-ipv6-addresses-based-on-ipv4-on-a-plesk-server/ ( External link, ples. inform me if the link goes dead! )

The author provided a self-made-script ( usage on your very own risk! ), which you could modify to fit your needs:

Code:
# Define IPv6 /32 as "####:####"
$ipv6Assignment = "2001:db8";
# Define site ID as just an integer
$ipv6SiteID = "1";
# Define VLAN of server
$vlan = "500";
# Define primary network interface name; typically eth0 or em1
$iface = "eth0";
# Define IPv6 subnet mask; should very rarely be anything other than /64
$mask = "64";
@ipList = `/usr/local/psa/bin/ipmanage --ip_list`;
foreach $line (@ipList) {
chomp $line;
if ( $line =~ /^0     E    $iface:(\d+)\.(\d+)\.(\d+)\.(\d+)\// ) {
  $ipv6 = sprintf("$ipv6Assignment:$ipv6SiteID:$vlan:%X:%X:%X:%X",$1,$2,$3,$4);
  $ipv4 = "$1.$2.$3.$4";
  #
  # Doesn't matter of the IPv6 address already exists
  # because Plesk will just give an error about adding it.
  #
  print "/usr/local/psa/bin/ipmanage -c $ipv6 -type exclusive -mask $mask -interface $iface\n";
}
}
 
Last edited by a moderator:
Back
Top