lxc.net.0.type = veth
lxc.net.0.link = lxcbr0
lxc.net.0.flags = up
-lxc.net.0.hwaddr = 00:16:3e:xx:xx:xx
+lxc.net.0.hwaddr = 10:66:6a:xx:xx:xx
USE_LXC_BRIDGE="true"
LXC_BRIDGE="lxcbr0"
-LXC_BRIDGE_MAC="00:16:3e:00:00:00"
+LXC_BRIDGE_MAC="10:66:6a:00:00:00"
LXC_ADDR="10.0.3.1"
LXC_NETMASK="255.255.255.0"
LXC_NETWORK="10.0.3.0/24"
# If you have the dnsmasq daemon installed, you'll also have to update
# /etc/dnsmasq.d/lxc and restart the system wide dnsmasq daemon.
LXC_BRIDGE="lxcbr0"
-LXC_BRIDGE_MAC="00:16:3e:00:00:00"
+LXC_BRIDGE_MAC="10:66:6a:00:00:00"
LXC_ADDR="$SUBNET.1"
LXC_NETMASK="255.255.255.0"
LXC_NETWORK="$SUBNET.0/24"
seed = randseed(false);
- ret = strnprintf(hwaddr, 18, "00:16:3e:%02x:%02x:%02x", rand_r(&seed) % 255,
+ ret = strnprintf(hwaddr, 18, "10:66:6a:%02x:%02x:%02x", rand_r(&seed) % 255,
rand_r(&seed) % 255, rand_r(&seed) % 255);
#else
(void)randseed(true);
- ret = strnprintf(hwaddr, 18, "00:16:3e:%02x:%02x:%02x", rand() % 255,
+ ret = strnprintf(hwaddr, 18, "10:66:6a:%02x:%02x:%02x", rand() % 255,
rand() % 255, rand() % 255);
#endif
if (ret < 0)
goto out;
}
- if (!c->set_config_item(c, "lxc.net.0.hwaddr", "00:16:3e:xx:xx:xx")) {
+ if (!c->set_config_item(c, "lxc.net.0.hwaddr", "10:66:6a:xx:xx:xx")) {
fprintf(stderr, "%d: failed to set network.hwaddr\n", __LINE__);
goto out;
}
cat > $f << EOF
lxc.net.0.type = veth
-lxc.net.0.hwaddr = 00:16:3e:xx:xx:xx
+lxc.net.0.hwaddr = 10:66:6a:xx:xx:xx
EOF
lxc-create -t busybox -f $f -n lxctestc
grep -q "xx:xx" /var/lib/lxc/lxctestc/config && { echo "hwaddr not expanded"; exit 1; }