[EMAIL PROTECTED] said:
> 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
host.

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
fe:fd:00:00:00:00. 

As mentioned, you can generate random (unique?) ones yourself, and
assign them to the uml on the uml command line using
"eth0=tuntap,tap0,fe:fd:00:00:00:02".

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.

HTH,

Jason



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
User-mode-linux-user mailing list
User-mode-linux-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user

Reply via email to