|
|
|
|
|
|
|
|
|
|
xen-devel
Re: [Xen-devel] Random MAC addresses?
On 21/09/2009 22:09, "Andrew Brennan" <andrew.brennan@xxxxxxxxxx> wrote:
> I'm curious about this bit of documentation - "By default xend will select
> a random address[.]" [ http://wiki.xensource.com/xenwiki/XenNetworking ]
> A couple paragraphs later, this appears - "It's recommended to use a MAC
> address inside the range 00:16:3e:xx:xx:xx. This address range is reserved
> for use by Xen." My user has MACs starting with 1A5DA4, 42A1FD and CE8CF4
> so these would appear to be bogus MACs (and potentially evidence of a bad
> ethernet driver).
Our MAC address generator is below, and seems to do the right thing. The
user may have specified their own MAC addresses in their VM configuration
files (either manually, or perhaps the file could get generated by a vendor
'wizard' application).
-- Keir
mac = [ 0x00, 0x16, 0x3e,
random.randint(0x00, 0x7f),
random.randint(0x00, 0xff),
random.randint(0x00, 0xff) ]
return ':'.join(map(lambda x: "%02x" % x, mac))
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|