Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
when plugged however, they don't register as AsiX like in the article
the problem is that all of them appear to have the same MAC address
dmesg | tail -n 20
Code:
[ 628.298714] usb 1-1.3: new full speed USB device number 3 using ehci_hcd
[ 628.461486] dm9601 1-1.3:1.0: eth5: register 'dm9601' at usb-0000:00:1a.0-1.3, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 628.461516] usbcore: registered new interface driver dm9601
[ 628.543572] dm9601 1-1.3:1.0: eth5: link up, 100Mbps, full-duplex, lpa 0xFFFF
[ 639.244058] eth5: no IPv6 routers present
[ 654.906849] usb 1-1.6: new full speed USB device number 4 using ehci_hcd
[ 655.018019] dm9601 1-1.6:1.0: eth6: register 'dm9601' at usb-0000:00:1a.0-1.6, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 655.119109] udevd[675]: renamed network interface eth6 to rename10
[ 717.081829] usb 1-1.4: new full speed USB device number 5 using ehci_hcd
[ 717.196783] dm9601 1-1.4:1.0: eth6: register 'dm9601' at usb-0000:00:1a.0-1.4, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 717.294212] udevd[676]: renamed network interface eth6 to rename11
[ 745.996647] usb 1-1.5: new full speed USB device number 6 using ehci_hcd
[ 746.107159] dm9601 1-1.5:1.0: eth6: register 'dm9601' at usb-0000:00:1a.0-1.5, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 746.189000] udevd[675]: renamed network interface eth6 to rename12
ifconfig -a (with other interfaces ommitted)
Code:
eth5 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
inet6 addr: fe80::2e0:4cff:fe53:4458/64 Scope:Link
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
rename10 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
rename11 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
rename12 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
without -a switch in the ifconfig command only eth5 is shown and there is no trace of those rename interfaces
is is possible that it is the driver issue that it sees those adapters with some generic MAC address?
how can I get all 4 of them working and appear to have different MAC addresses?
Right. This isn't supposed to happen, but it certainly can and does.
As uhelp said, we need to know your Linux distro and version. You can set arbitrary MAC addresses using ifconfig(8), and you'll need to make some configuration changes for the settings to be "permanent" (i.e. surviving a reboot).
No, you can't easily get two or more nics with the same mac. That would be bad. There is no way you should have this.
What is looks like to me is you cloned some install and now it doesn't correctly view nics or some other deal that isn't right.
Maybe someone tried to rename them and messed up.
Linux ubuntu 3.0.0-12-generic #20-Ubuntu SMP Fri Oct 7 14:56:25 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
dmesg | tail -n 20
Quote:
[ 1156.154454] usb 1-1.6: new full speed USB device number 3 using ehci_hcd
[ 1156.300364] dm9601 1-1.6:1.0: eth5: register 'dm9601' at usb-0000:00:1a.0-1.6, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1156.300448] usbcore: registered new interface driver dm9601
[ 1156.670538] dm9601 1-1.6:1.0: eth5: link up, 100Mbps, full-duplex, lpa 0xFFFF
[ 1166.875789] eth5: no IPv6 routers present
[ 1186.704092] usb 1-1.5: new full speed USB device number 4 using ehci_hcd
[ 1186.814252] dm9601 1-1.5:1.0: eth6: register 'dm9601' at usb-0000:00:1a.0-1.5, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1186.890991] dm9601 1-1.5:1.0: eth6: link up, 100Mbps, full-duplex, lpa 0xFFFF
[ 1197.297673] eth6: no IPv6 routers present
[ 1222.778642] usb 1-1.3: new full speed USB device number 5 using ehci_hcd
[ 1222.892353] dm9601 1-1.3:1.0: eth7: register 'dm9601' at usb-0000:00:1a.0-1.3, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1222.969414] dm9601 1-1.3:1.0: eth7: link up, 100Mbps, full-duplex, lpa 0xFFFF
[ 1229.686504] usb 1-1.4: new full speed USB device number 6 using ehci_hcd
[ 1229.800937] dm9601 1-1.4:1.0: eth8: register 'dm9601' at usb-0000:00:1a.0-1.4, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1229.876181] dm9601 1-1.4:1.0: eth8: link up, 100Mbps, full-duplex, lpa 0xFFFF
[ 1233.771934] eth7: no IPv6 routers present
ifconfig
Quote:
eth5 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
inet6 addr: fe80::2e0:4cff:fe53:4458/64 Scope:Link
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
eth6 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
inet6 addr: fe80::2e0:4cff:fe53:4458/64 Scope:Link
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:1 dropped:0 overruns:0 frame:1
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
eth7 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
inet6 addr: fe80::2e0:4cff:fe53:4458/64 Scope:Link
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
eth8 Link encap:Ethernet HWaddr 00:e0:4c:53:44:58
inet6 addr: fe80::2e0:4cff:fe53:4458/64 Scope:Link
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
so I guess that this is what it should look like
I will look into rules naming my ETH interfaces
//edit: /etc/udev/rules.d/70-persistent-net.rules
contained only 1 entry for all those Davicom cards and was forcing it to have the name of ETH5.
this probably caused the interfaces to be renamed.
after deleting that entry and rebooting,
this was added to that file automatically
he problem now is that you may not be able to predict how the usb's attach in order.
I guess that some script that searches through dmesg could do that.
I agree that I can't tell which one is eth8 after reboot
what I can do however, is to parse through this output
[ 1156.300364] dm9601 1-1.6:1.0: eth5: register 'dm9601' at usb-0000:00:1a.0-1.6, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1186.814252] dm9601 1-1.5:1.0: eth6: register 'dm9601' at usb-0000:00:1a.0-1.5, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1222.892353] dm9601 1-1.3:1.0: eth7: register 'dm9601' at usb-0000:00:1a.0-1.3, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[ 1229.800937] dm9601 1-1.4:1.0: eth8: register 'dm9601' at usb-0000:00:1a.0-1.4, Davicom DM9601 USB Ethernet, 00:e0:4c:53:44:58
and since I am not changing their point of attachement (USB port) I should be able to identify them by that 1.3 - 1.6 number
So I would know which adapter is which, then I can set their MAC addresses and then I could somehow trigger interface renumbering with 77-persistent-net.rules
does that sound possible?
I am gonna use them just for playing with my Cisco CAT3550 switches, for some serious traffic I have Dlink DFE580TX quad ethernet card
You could try it. Just that usb sometimes is affected by odd things. There may be a way to grep some id off them. I get the feeling they are clones by some crooked company.
This will not help you have multiple of these devices on any one machine *as the rule would do the same to each device) but it can be used so that you could use multiple of these devices at the same time but on different computers.
In each computer you could edit the appropriate udev rule (distro dependent) to do something like this:
# USB device 0x0fe6:0x9700 (usb)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:e0:4c:53:44:58", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1", RUN="/sbin/ifconfig eth1 hw ether 00:e0:4c:53:44:59"
and on each computer you could have a different mac address assigned to the card
RUN="/sbin/ifconfig eth1 hw ether 00:e0:4c:53:44:60" ...
so that at least they can be used on different pc.
I'm looking for a way to permanently change the register that holds the mac address on the device ... but dumping the register shows "00:00:00:00:00:00" so I suspect that it may not be possible.
when dumping that register and it returns "00:00:00:00:00:00" try this
if I remember correctly, after plugging it in when Windows OS was running (for me Windows 7 x64, there should be support for Win7 and older maybe even default Win8 driver will work)
in control panel when selecting device manager and then that specific USB NIC look for a field "Network Address" or similar that let's you set custom MAC address
apply your new MAC address and close everything, reboot Windows and see if new MAC address persisted across reboot
now if I am not mistaken, that MAC address should be read by linux and dumping that register should return MAC address you set on Windows (for some time, never tested how long this will last)
I could be wrong of course but I think I remember this the way I described it
I don't run windows on any of my pc ... and I think that only instructs the system to change the mac address in software ... it's not e permanent change on the NIC itself (if you take it to another PC you are back to the original MAC).
I suspect that it does more or less what I suggested for linux ... that in any case is permanent across reboots on the pc where it's done.
One could actually choose to replace it with an exotic mac like this:
de:ad:be:ef or b1:6b:00:b5
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.