mac address messiness

Any technical questions about the Epiphany chip and Parallella HW Platform.

Moderator: aolofsson

mac address messiness

Postby magorian » Sat Jan 04, 2014 11:42 pm

Normally Linux SBCs with one net int show up as eth0. Since my application manipulates subifs and vlans, I looked into why one of mine shows up as eth15 and the other eth16. I found that /etc/udev/rules.d/70-persistent-net.rules had a lot of rules manually matching by mac addr:

# net device ()
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4f:8b:00:00:00", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# net device ()
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4f:8b:00:00:73", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

# net device ()
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4f:8b:00:00:84", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"

... including a line of control chars left in the middle in the dist version till it matched on mine:

^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@
# net device ()
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4f:8b:00:00:2a", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth14"

# net device ()
#SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4f:8b:00:00:05", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth15"

Normally this file only has one rule matching the mac addr to eth0. Obviously one can edit the file to match eth0 to your board's mac addr, but what was somebody trying to do here? it kind of looks like there were 16 mac addrs generated and all shipped Parallellas would have one of them. Needless to say not having unique mac addrs for all the boards in our clusters would be quite problematic since it's a flat nonrouted lan, and also I didn't expect to have to edit this file for each board in each cluster to hack my way around this kind of issue.

Thanks.

Dan
magorian
 
Posts: 33
Joined: Tue Dec 24, 2013 4:11 am

Re: mac address messiness

Postby ed2k » Sun Jan 05, 2014 12:59 am

if you plan to have a clusters of the board with same image, all these udev rules need to be adjusted.
apparently the file made in sd image is some easy hack to fix mac address with eth number.
ed2k
 
Posts: 113
Joined: Mon Dec 17, 2012 3:27 am

Re: mac address messiness

Postby tnt » Sun Jan 05, 2014 9:02 am

That's usually a symptom when you booted the same SD on different boards. That file should be cleared in the image on the FTP and it will be re-created on boot with the proper MAC.
tnt
 
Posts: 408
Joined: Mon Dec 17, 2012 3:21 am

Re: mac address messiness

Postby magorian » Sun Jan 05, 2014 10:20 pm

In theory yes, but in reality clearing that file causes the image on boot to not create an ethx interface, which is probably why they left it messy but working in the initial release. Possibly a bug somewhere in the 12.04 code, which may or may not have been fixed subsequently... Leaving one rule set to eth0 does work, but impractical to mod by hand with many cluster boards. Dan
magorian
 
Posts: 33
Joined: Tue Dec 24, 2013 4:11 am

Re: mac address messiness

Postby aolofsson » Mon Jan 06, 2014 12:07 am

Dan,
There might be a little too much "history" in the current Ubuntu distro...we will try to get a new clean version uploaded by tomorrow that should get rid of the crud you are seeing. (fingers crossed that the new version will solve some of the hdmi issues folks are seeing as well...)
Andreas
User avatar
aolofsson
 
Posts: 1005
Joined: Tue Dec 11, 2012 6:59 pm
Location: Lexington, Massachusetts,USA

Re: mac address messiness

Postby magorian » Mon Jan 06, 2014 5:25 am

Andreas:

Sounds good... I would also encourage you to work on the image's performance. Since my 2 cards' physical interfaces are broken I've tried to use vnc, but it's so sluggish as to be unusable, even set to 800x600, 8-bit pixel depth, and compression. Also the image takes many minutes to boot due to the bluetooth process respawning (best left off unless people explicitly turn it on), dns is broken due to resolv.conf or /etc/network/interfaces fixes needed, and just using ssh for things like nmap and vi slug noticably. Quite a few things need cleaning up.

I would suggest that you switch to the much lighter weight Lubuntu or something comparable because clearly ther Zinq doesn't have the horsepower for the standard Unity processes, even tho the load averages look fine. Also a server version w/o any gui installed or at least default it to off for people that just want ssh, which is probably most people that buy it to use the Epiphany cores.

Obviously this has nothing to do with the core Epiphany stuff, but you won't convince people it's a hot board if it seems sluggish. Remember that the RaspberryPi's huge success was not just the cheap hardware, but in large part due to the optimized minimal Raspbian Debian port done by Mike Thompson and Peter Green (which tried its best to compensate for the obsolete ARM11 used). It probably would be still languishing in obscurity if all that was done was the POC image. OK, you may not have a volunteer Linux angel like Mike Thompson, but you can optimize the image yourselves...

"Hardware is the invisible enabler, but software is what people experience".

Dan
magorian
 
Posts: 33
Joined: Tue Dec 24, 2013 4:11 am

Re: mac address messiness

Postby magorian » Mon Jan 06, 2014 6:13 am

Also:

"Unity has serious performance issues. Improvements are slowly starting to trickle in, but even then, the current state of affairs leaves a lot to be desired. Making Unity faster and slicker should be Canonical's top priority in my opinion, and that is why I am still a big proponent of "Project Butter" for Ubuntu. Let's just hope that, Unity's performance will get the deserved attention it needs to compete with the best out there. Seems like Canonical heard your (and others as well) opinion(s) and Unity in Ubuntu 13.04 is much, much faster than any previous Ubuntu version."

(I run 13.10 myself, and I agree that it's a huge improvement over 12.X)

As well as other suggestions like:

http://www.techdrivein.com/2013/03/4-si ... buntu.html

Dan
magorian
 
Posts: 33
Joined: Tue Dec 24, 2013 4:11 am

Re: mac address messiness

Postby shodruk » Mon Jan 06, 2014 11:57 am

sudo apt-get install lxde
Shodruky
shodruk
 
Posts: 464
Joined: Mon Apr 08, 2013 7:03 pm

Re: mac address messiness

Postby magorian » Mon Jan 06, 2014 2:16 pm

Yes, I know how to install it, but take a look at how annoying it is to remove Unity. Plus you're overlooking my main points about performance and image optimization. Dan
magorian
 
Posts: 33
Joined: Tue Dec 24, 2013 4:11 am

Re: mac address messiness

Postby shodruk » Mon Jan 06, 2014 6:06 pm

You don't have to remove unity. just select LXDE on login screen.
Shodruky
shodruk
 
Posts: 464
Joined: Mon Apr 08, 2013 7:03 pm


Return to Epiphany and Parallella Q & A

Who is online

Users browsing this forum: No registered users and 19 guests