[pve-devel] [PATCH v2 cluster] add mac_prefix option to datacenter.cfg

Wolfgang Bumiller w.bumiller at proxmox.com
Thu Jul 14 08:44:29 CEST 2016


We allow up to 3 fixed prefix bytes.
---
Changes to v1: changed limit from 5 to 3 bytes

 data/PVE/Cluster.pm | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/data/PVE/Cluster.pm b/data/PVE/Cluster.pm
index fa4a08f..fe741cf 100644
--- a/data/PVE/Cluster.pm
+++ b/data/PVE/Cluster.pm
@@ -1347,6 +1347,12 @@ my $datacenter_schema = {
 	      " With both all two modes are used." .
 	      "\n\nWARNING: 'hardware' and 'both' are EXPERIMENTAL & WIP",
 	},
+	mac_prefix => {
+	    optional => 1,
+	    type => 'string',
+	    pattern => qr/[a-f0-9]{2}(?::[a-f0-9]{2}){0,2}:?/i,
+	    description => 'Prefix for autogenerated MAC addresses.',
+	},
     },
 };
 
-- 
2.1.4




More information about the pve-devel mailing list