Arping is a nice little tool that, as its name suggests, can be used to detect the MAC address of an IP, or (more useful) to find out the IP when you know the MAC. I used it more than once when I “lost” machines in a network.
The not so funny part is that there are actually two arping packages. One is “iputils-arping”, and is installed by default on Ubuntu. The other is called “arping” and conflicts with the first one. The two programs, while they share the same name, are not identical – they don’t even have the same command line parameters.
The arping from iputils-arping is next to useless, because it does not support “pinging” MAC addresses. You need arping from the arping package to do that. But if you’re brave enough to try to install it, you’ll find out that it is in conflict with arping-utils. And if you uninstall arping-utils, you will also uninstall network-manager.
Let me repeat: two programs who don’t do the same thing are called the same. Their packages conflict and you can’t install the “good” one because uninstalling the “bad” arping will also remove network manager. Great! Thanks a lot, Ubuntu developers, you’re geniuses.
I suppose naming one of the binary “arping2″ or “arpping” or “pingarp” or something like that was just too hard. Or manage them with update-alternatives. It’s good they have enough time to do stupid things like moving the menu in the task bar, right?
Anyway, since I really wanted to use the arping binary from the arping package, I had to extract it from the deb file and rename it arping2:
- I downloaded the arping deb file from http://packages.ubuntu.com/natty/arping .
- I installed a dependency of arping, libnet1:
$ sudo apt-get install libnet1 - I unpacked the deb file:
$ dpkg-deb -x arping_2.09-2_amd64.deb ./destdir - And finally, moved the needed file somewhere in the path:
$ sudo mv ./destdir/usr/sbin/arping /usr/local/sbin/arping2
And this, kids, is why open source is great: even is a package maintainer fucks up, you can fix it yourself.
Image credit: devslashtux.
Related posts:






