View previous topic :: View next topic |
Author |
Message |
jamapii l33t
Joined: 16 Sep 2004 Posts: 637
|
Posted: Mon Apr 29, 2013 10:22 pm Post subject: /sbin/ip or /bin/ip, a warning about iproute2 |
|
|
Hi,
iproute2-3.8.0 installs its binaries in /bin, no longer /sbin. This will break openvpn-2.3.1 (at least for me), which isn't in portage, but who knows what else it will break (vtun? your scripts?).
See also
https://forums.gentoo.org/viewtopic-p-7191632-highlight-.html#7191632
My script to prevent breakage becomes:
Code: | #!/bin/sh
grep -E "^obj /s?bin/" /var/db/pkg/*-*/{net-tools,iproute2}-*/* | cut -d" " -f2 |
while read file; do
prog=$(basename $file)
bin=/bin/$prog
sbin=/sbin/$prog
[ -e $bin -a -e $sbin ] && continue
if [ $file = $bin ]; then
file2=$sbin
else
file2=$bin
fi
echo ln -s $file $file2
done |
(this creates symlinks in /sbin and /bin, whatever doesn't exist.)
If you run this script and later update net-tools or iproute2, it may complain about collisions. In this case, you can do Code: | FEATURES="-collision-protect" emerge -1 iproute2 # or whatever | to force the update. |
|
Back to top |
|
|
khayyam Watchman
Joined: 07 Jun 2012 Posts: 6227 Location: Room 101
|
Posted: Mon Apr 29, 2013 11:32 pm Post subject: |
|
|
jamapii ...
I'm not sure the script is such a good idea, having stray (non-package installed) links in /bin, /sbin, etc, should be avoided. The problem will get resolved (iproute2-3.8.0 is ~arch), and as I understand it packages, specifically openvpn, find the location of ip/ifconfig at buildtime, so linking will just perpetuate the issue. This was the case with the ifconfig relocation (which I assume is the link you provided), and a re-emerge of openvpn was enough to resolve the problem.
best ... khay |
|
Back to top |
|
|
kurly Apprentice
Joined: 02 Apr 2012 Posts: 260
|
Posted: Tue Apr 30, 2013 12:27 am Post subject: |
|
|
khayyam wrote: | The problem will get resolved (iproute2-3.8.0 is ~arch) |
The rest of your point is valid, but I should point out that iproute2-3.8.0 is currently stable on alpha, amd64, arm, hppa, ia64, m68k, ppc, ppc64, sparc, and x86. It remains ~arch on mips, s390, and sh.
This is part of why I've given up on stable and track ~arch. The shield that protects stable users from unexpected change is weakening. Since ~arch itself is very usable nowadays, I see fewer reasons to use stable, unfortunately.
Obviously tracking ~arch doesn't help in this situation, but tracking stable doesn't either... *shrug* |
|
Back to top |
|
|
Ant P. Watchman
Joined: 18 Apr 2009 Posts: 6920
|
Posted: Tue Apr 30, 2013 12:37 am Post subject: |
|
|
Did stable get a huge version bump recently? I've had it in /bin/ip for years now (and vastly prefer that to having to prefix all my commands with /sbin/ or su -c). |
|
Back to top |
|
|
khayyam Watchman
Joined: 07 Jun 2012 Posts: 6227 Location: Room 101
|
Posted: Tue Apr 30, 2013 1:54 am Post subject: |
|
|
kurly wrote: | khayyam wrote: | The problem will get resolved (iproute2-3.8.0 is ~arch) |
The rest of your point is valid, but I should point out that iproute2-3.8.0 is currently stable on alpha, amd64, arm, hppa, ia64, m68k, ppc, ppc64, sparc, and x86. It remains ~arch on mips, s390, and sh. |
kurly ... haha, ok, thanks for pointing that out. My reason for thinking it was still ~arch was that I'd keyworded it only the other day to see if the previous version was the cause of my "RTNETLINK answers: Operation not supported" error, so that was still fresh in my mind (yes, all the necessary NETLINK options bar NET_SCH_INGRESS, which seems to have disapeared, are enabled).
best ... khay |
|
Back to top |
|
|
Anon-E-moose Watchman
Joined: 23 May 2008 Posts: 6095 Location: Dallas area
|
Posted: Tue Apr 30, 2013 9:54 am Post subject: |
|
|
I find it rather stupid to do something like change the directory where ip resides without taking into account the different packages that expect it to be in /sbin, on the order of udev type stupid.
Yes, I recompiled openvpn and it works ok. But deluge doesn't (recompiling didn't help) so I assume that the fault is somewhere in a python module. I just didn't feel like spending time chasing it down this morning. So I put in a temp link to /sbin just to get it working.
Are there no developers who can think further than "I'll change this simply because I can"
[/rant] _________________ PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|