How is the Ethernet MAC address for usb0 defined?

Dr. H. Nikolaus Schaller hns at computer.org
Tue Aug 7 23:32:06 CEST 2007


>
> 	This isn't a kernel problem - or at least it doesn't require a  
> kernel fix.

That is good news!

> The usb driver's mac address can be set from userland, like so:
>
> ifconfig usb0 down
> ifconfig usb0 hw ether 45:23:ED:23:98:34

I tried the same on the Sharp Zaurus (the OpenMoko is currently dead  
because
of the battery charging issues).

The Zaurus appears to permanently (re)set it to 40:00:01:00:00:01  
each time the
USB cable is plugged into the host. Having this reset is a good  
approach...

But this explains the trouble I had some time ago when I tried to  
connect two
Zaurus devices to the same host... Both share the same MAC address :-)

> 	Setting it to match the BT address (or the BT address plus one,  
> which is
> what I'd more likely expect; all my computers with multiple on- 
> board ethernet
> cards use consecutive mac addresses for each card) is fairly  
> trivial *except*
> that to get the BT mac address you have to load the BT modules and  
> turn BT on,
> so you'd be better off setting up a routine that does that if  
> necessary but
> then saves the new MAC address to disk and uses that disk cached  
> value in the
> future. It can all be done with a little bit of shell scripting on  
> boot.





More information about the device-owners mailing list