> Now... all this works in terms of the plumbing but *all* the UMLs have
> the same eth device HWAddr (mac address) so they all get the same IP.
> I want them to have different IPs.
> I thought, because they were all using different tun devices that they
> would get different IPs (each of the tun devices in the bridge has a
> different HWAddr).
The mac address assigned to the tap device on the host is used by the
*host*, not the uml. The mac address used by the guest is the one
associated with its ethX device corresponding to the tap device on the
You can think of a uml guest running with eth0=tuntap as being connected
to the host by a "virtual crossover cable":
|host tapN|===|eth0 uml guest|
| mac| |mac |
| 32:61:ae:6b:a4:05| |fe:fd:00:00:00:02|
> Can someone explain how to make the UML side of the tun devices have
> unique HWAddrs?
The host tuntap side of the link always gets a random address assigned
by a call to random_ether_addr() in tun.c.
Unless you somehow specify otherwise, though, the uml side always gets
As mentioned, you can generate random (unique?) ones yourself, and
assign them to the uml on the uml command line using
You can also change the mac address within the uml with
"ip link set dev eth0 address fe:fd:00:00:00:02". I think you can do it
with ifconfig too.
Finally, if you assign an IP to the interface within the UML guest
_before_ bringing the interface up, then the last four octets of the mac
will be set to match the IP assigned.