Public bug reported: As smoser pointed out, lxc-start-ephemeral needs to do the same kinds of things that lxc-clone does, such as this:
# change hwaddrs mv ${c} ${c}.old ( while read line; do if [ "${line:0:18}" = "lxc.network.hwaddr" ]; then echo "lxc.network.hwaddr= 00:16:3e:$(openssl rand -hex 3| sed 's/\(..\)/\1:/g; s/.$//')" else echo $line fi done ) < ${c}.old > ${c} rm -f ${c}.old # set the hostname cat <<EOF > $rootfs/etc/hostname $hostname EOF # set minimal hosts cat <<EOF > $rootfs/etc/hosts 127.0.0.1 localhost $hostname EOF We have a version that does this, and will propose it. ** Affects: lxc (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/949956 Title: lxc-start-ephemeral keeps same MAC address, and so same IP address, as base instance To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/lxc/+bug/949956/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs