Age | Commit message (Collapse) | Author |
|
The location of the ifconfig binary has changed in
net-tools-1.60_p20120127084908, and if we do not check both locations
for it, the user will get errors like:
_is_wireless: command not found
_exists: command not found
X-Gentoo-Bug: 407757
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=407757
|
|
slow to update sometimes when interfaces are added rapidly. Use sysfs instead.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
X-Gentoo-Bug: 392223
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=392223
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
|
|
The previous bonding change of ensuring interfaces were down to add
slave interfaces, but it clobbered the IFACE variable, because it was
being passed to a bash function rather than a command.
X-Gentoo-Bug: 400613
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=400613
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
I missed removing a call to the old ethtool function wrapper that was
made unneeded by commit d02d3af02.
X-Gentoo-Bug: 399037
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=399037
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Allow users to shorten iproute arguments to the shortest unique argument
that will match a flag of iproute2.
X-Gentoo-Bug: 398721
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=398721
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
The program function in depend blocks is now able to search paths by
itself. If passed multiple arguments or multiple calls, at least one of
the arguments passed must be a program or a shell builtin (eg ip built
into busybox). If a qualified path is specified, only that path will be
checked, otherwise it will be checked as a builtin, then $PATH will be
checked for the named binary (via type).
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
The ethtool module checked in two places for the ethtool binary; now we
look for it in the path.
|
|
The iproute2, macvlan and vlan modules had several possible hard coded
paths for the iproute2 binary. Now we look for it in the path.
|
|
This reverts commit f583030e3cbfb1d2f30af3ebd00427e12fe66b70.
The previous commit did not account for the case of not having iproute2
installed.
Reported-by: Duncan <1i5t5.duncan@cox.net>
X-Gentoo-Bug: 397875
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=397875
|
|
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
X-Gentoo-Bug: 396429
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=396429
|
|
This test is incorrect, and we do not need the modprobe. If macvlan is a
module, it is automatically modprobed when the first macvlan link is
added. Also, the /sys directory referred to in the test does not exist
if macvlan is built into the kernel.
Reported-by: Marien Zwart <marienz@gentoo.org>
X-Gentoo-Bug: 396427
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=396427
|
|
The ${x/a/b} shell construct is NOT defined in the POSIX specification,
it's a bash addition.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
During stop of an interface, if it has been removed already (eg
hotunplug), not existing is fine.
X-Gentoo-Bug: 395859
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=395859
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Since commit 683a21b0a in Feburary 2011, iproute2 has been required for
new VLAN configuration. MACVLAN is also impossible to configure without
iproute2. However we did not check if iproute2 was actually in the
modules for a given interface, so it could end up hanging or giving
weird errors. Check for iproute2 before usage now.
X-Gentoo-Bug: 389437
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=389437
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
We need to create interfaces of custom names before we can sucessfully
start them. To do this, we have to add tunnels during prestart instead
of start. Split up the ip6to4 script to do this, saving the computed
variables for use in start with the new service data commands.
X-Gentoo-Bug: 372575
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=372575
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Broadcast and IPv6 should not be used together. Do not try to set the
keyword for auto-generation of the broadcast address. If the user passes
a broadcast address for IPv6, throw an error.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Several of the optional flags were not being handled correctly, they
were being passed as values only, without the keyword before them.
Affected keywords: anycast, label, scope, valid_lft, preferred_lft
Also change the handling of keywords to a common setup now, making
broadcast and peer strings the same as the above keywords.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
This includes address family specifications methods to help debug bug
358235 further.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
For creation of routing policy entries for IPv6, the family must be
explicitly specified to 'ip'.
X-Gentoo-Bug: 385833
X-Gentoo-Bug-URL: https://bugs.gentoo.org/385833
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Fix minor shell typo that broke setting mtu on vlans.
X-Gentoo-Bug: 392971
X-Gentoo-Bug-URL: https://bugs.gentoo.org/392971
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
This module should return failure if iproute2, openvpn or tunctl cannot
be found. Before it was returning success; this fixes the issue.
|
|
This patch was modified by William Hubbs <williamh@gentoo.org> to
document the new usage in net.example.
X-Gentoo-Bug: 394281
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=394281
|
|
Provide consistent methods using iproute2/ifconfig to check operational
and administrative up/down state of interfaces. This is not the same as
ethtool's "Link detected" field, which is the state of the layer 2
medium.
TODO: How to check operational state in BSD?
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
The old ifenslave binary forcibly set new slave interface to down before
adding into the kernel, as a way of show it's version to the kernel. We
need to duplicate this so that the kernel doesn't think it's an old
ifenslave version using the bonding setup interface.
X-Gentoo-Bug: 391881
X-Gentoo-Bug-URL: https://bugs.gentoo.org/391881
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
Thanks-to: Yun Zheng Hu <hu@fox-it.com>
|
|
The correct setting for this is /48.
Reported-by: MaratIK <marat.buharov@gmail.com>
X-Gentoo-Bug: 392723
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=392723
|
|
Reported-by: Spooky Ghost <spookyghost@blueyounder.co.uk>
X-Gentoo-Bug: 392593
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=392593
|
|
|
|
Reported-by: Alon Bar-Lev <alon.barlev@gmail.com>
x-Gentoo-Bug: 364907
x-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?364907
|
|
Convert the style:
var=$((${var} + 1))
to:
: $(( var += 1 ))
The latter is easier to read imo.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
Rework the makefiles to use pattern rules instead of suffix rules.
This is the preferred way to write implicit rules according to the gnu
make manual.
|
|
X-Gentoo-Bug: 384029
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=384029
|
|
No need for if() logic.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
Some variable references were written as $(foo), but the majority were
written as ${foo}. This commit changes all of the variable references
to using braces.
|
|
The tree contained many operating system specific Makefiles which were
being included in other Makefiles. This commit removes those and adds
the code to the makefiles which included them using make's conditional
processing.
X-Gentoo-Bug: 387441
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=387441
|
|
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
|
|
Make sure the VLAN interfaces as well as its rules will be removed prior
to the actual/parent interface.
The VLAN configs are gone in vlan_post_stop() already so we have to use
vlan_pre_stop() instead.
Reported-by: Bernd Bednarz <bernd.bednarz@avira.com>
X-Gentoo-Bug: 380603
X-Gentoo-Bug-URL: https://bugs.gentoo.org/380603
|
|
Make sure the RPDB rules will be removed.
|
|
iproute2_post_stop() does now check if the network interface still exist.
Reported-by: Yun Zheng Hu <hu@fox-it.com>
X-Gentoo-Bug: 379575
X-Gentoo-Bug-URL: https://bugs.gentoo.org/379575
|
|
ethtool.sh didn't reset the Internal Field Seperator (IFS) properly.
It now does, by storing the old IFS to OIFS, which will be used later
in the for loop.
It also fixes the "ethtool_ring_<if>" option.
Reported-by: Alois Schmid <alois.schmid@gmx.de>
X-Gentoo-Bug: 368525
X-Gentoo-Bug-URL: https://bugs.gentoo.org/368525
|
|
as OpenRC can be used on other distributions as well.
|
|
ARP replies may/do contain two MAC addresses when using iputils's
arping so we have to use the first one because it's always the "From"
address - which is what we want.
Thanks to Stefan Knoblich <s.knoblich@axsentis.de> for the fixed pattern.
Reported-by: cl@exomail.to
X-Gentoo-Bug: 379181
X-Gentoo-Bug-URL: https://bugs.gentoo.org/379181
|
|
|
|
This was originally to fix the fact that our code did not handle certain
orders of arguments in conversion, but it was easier to rewrite the
entire argument handling to support more options at the same time.
Now supports all options documented in the ip manpage, including the
IPv6-specific options that must be passed after the interface argument.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
Reported-by: Tony Vroon <chainsaw@gentoo.org>
X-Gentoo-Bug: 366905
X-Gentoo-Bug-URL: https://bugs.gentoo.org/366905
|
|
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|