optional => 1,
type => 'string',
format => 'mac-prefix',
- description => 'Prefix for autogenerated MAC addresses.',
+ default => 'BC:24:11',
+ description => "Prefix for the auto-generated MAC addresses of virtual guests. The"
+ ." default 'BC:24:11' is the OUI assigned by the IEEE to Proxmox Server Solutions"
+ ." GmbH for a 24-bit large MAC block. You're allowed to use this in local networks,"
+ ." i.e., those not directly reachable by the public (e.g., in a LAN or behind NAT)."
+ ,
+ verbose_description => "Prefix for the auto-generated MAC addresses of virtual guests."
+ ." The default `BC:24:11` is the Organizationally Unique Identifier (OUI) assigned"
+ ." by the IEEE to Proxmox Server Solutions GmbH for a MAC Address Block Large (MA-L)."
+ ." You're allowed to use this in local networks, i.e., those not directly reachable"
+ ." by the public (e.g., in a LAN or NAT/Masquerading).\n"
+ ." \nNote that when you run multiple cluster that (partially) share the networks of"
+ ." their virtual guests, it's highly recommended that you extend the default MAC"
+ ." prefix, or generate a custom (valid) one, to reduce the chance of MAC collisions."
+ ." For example, add a separate extra hexadecimal to the Proxmox OUI for each cluster,"
+ ." like `BC:24:11:0` for the first, `BC:24:11:1` for the second, and so on.\n"
+ ." Alternatively, you can also separate the networks of the guests logically, e.g.,"
+ ." by using VLANs.\n\nFor publicly accessible guests it's recommended that you get"
+ ." your own https://standards.ieee.org/products-programs/regauth/[OUI from the IEEE]"
+ ." registered or coordinate with your, or your hosting providers, network admins."
+ ,
},
notify => {
optional => 1,
$res->{description} = $comment;
+ # it could be better to track that this is the default, and not explicitly set, but having
+ # no MAC prefix is really not ideal, and overriding that here centrally catches all call sites
+ $res->{mac_prefix} = $datacenter_schema->{properties}->{mac_prefix}->{default}
+ if !defined($res->{mac_prefix});
+
if (my $crs = $res->{crs}) {
$res->{crs} = parse_property_string($crs_format, $crs);
}