Questions tagged [iproute2]

iproute2 (ip) is a tool used to manipulate network configurations.

The ip command is meant to replace ifconfig/route commands on Linux. This command lets you perform advanced configurations that were not possible with ifconfig/route.

See:

242 questions
190
votes
4 answers

Should I quit using Ifconfig?

With the servers that mount Infiniband cards, when I use the ifconfig command, I get this warning: Ifconfig uses the ioctl access method to get the full address information, which limits hardware addresses to 8 bytes. Because Infiniband address has…
Zhen
  • 2,159
  • 4
  • 19
  • 31
42
votes
4 answers

Where is the statement of deprecation of ifconfig (on linux)?

A lot of people is stating that the ifconfig command is deprecated in favor of the ipone (on linux at least). This is often used as an argumentation to switch from ifconfig to ip (see some comment and answer of Should I quit using Ifconfig?). Where…
Bruno BEAUFILS
  • 523
  • 1
  • 4
  • 5
37
votes
1 answer

Why does removing an unused IP address from an interface kill connections unrelated to that address

Yesterday I did a quick reinstall of a (physical) server in the datacenter, and since I was short on time and with no easy access to our database I just assigned it an IP that I knew was available and would allow me later access to assign the…
GnP
  • 955
  • 8
  • 15
32
votes
4 answers

list all route tables

I need to know how to list the IDs of all route tables. For example, I can run: ip rule add fwmark 2 table 104 ip route add dev eth0 default via 192.168.3.7 table 104 A call to ip rule list shows: 0: from all lookup local 32765: from all fwmark…
nic
  • 890
  • 1
  • 7
  • 10
27
votes
2 answers

ip route show src field

I read the man page of ip and still do not understand what src is and I could not find much documentation. Please, if you can explain it thoroughly or point to some link it a good answer.
coredump
  • 397
  • 1
  • 3
  • 7
23
votes
2 answers

Routing selection: specificity vs metric

I understand that Linux chooses the most specific route to the destination when it does routing selection. But what about a route's metric? Does it have a higher priority than route's specificity? A reference to the details of the routing selection…
Eugene Yarmash
  • 2,433
  • 5
  • 34
  • 54
15
votes
3 answers

How can I move an interface out of a network namespace?

If I move an interface temporarily into a netns with ip link set eth10 netns myns then it no longer is visible in the root, only within the namespace myns. How do I move it back, something like (these obviously don't exist): ip link unset eth10 or…
deitch
  • 585
  • 1
  • 4
  • 15
15
votes
3 answers

Is it necessary to manually set the interface broadcast address?

I'm converting my scripts from old net-tools: ifconfig eth0 192.168.2.1 netmask 255.255.255.0 to iproute2: ip link set eth0 up ip addr add 192.168.2.1/24 dev eth0 and I notice that the new commands do not set the broadcast address by default. What…
Powerman
  • 575
  • 1
  • 4
  • 12
15
votes
3 answers

How do you display the IPv6 NDISC cache in Linux?

Suppose you've configured IPv6 proxy NDP on one of your Linux systems like so: ip -6 neighbor add proxy 2001:db8:1234::5 dev eth1 How do you verify that the configuration took? ip -6 neighbor show doesn't appear to show proxy entries and ip -6…
Gerald Combs
  • 6,441
  • 25
  • 35
12
votes
1 answer

How to achieve per-packet multipath routing on Linux?

Linux Kernel before 3.6 used route caching to do IPv4 multipath routing, which meant routing between two separate lines/ISPs was quite easy. From 3.6 the algorithm changed to being per-packet, meaning that some route table/rule/iptables marker…
bao7uo
  • 1,704
  • 12
  • 24
12
votes
1 answer

How many custom route tables can I have on Linux?

I've been working with custom route tables on Linux, and I'm a bit confused by some of the documentation and behavior of the "ip route" command. It seems that the only valid values should be 0-255 plus the names defined in…
Bob
  • 223
  • 1
  • 2
  • 5
11
votes
1 answer

Macvlan based interface pings from host but not from namespace

[EDIT] The production system is currently a mix physical and ESXi based system. We obviously would never use virtualbox even for a pre-production environment ! It was used here only to quickly narrow down the problem directly on my desktop. Thanks…
yadutaf
  • 474
  • 3
  • 12
10
votes
1 answer

iproute multiple ADSL load balancer through VM

For a long time (2 years?) I have been running a virtual machine (Ubuntu 12.04 server) with a very basic outbound load balancing capability, sending different outbound connections out different ADSL routers. Configured simply by using iproute with…
Drew Anderson
  • 408
  • 1
  • 5
  • 13
10
votes
1 answer

iproute2 rules and iptables NAT... what is the difference?

We have 2 different ISP connections. Our previous "IT guy" setup our firewall like so: When /etc/rc.local was executed on startup, it did a bunch of ip rule add and ip route add commands in order to route certain internal hosts to use certain ISP…
Jake Wilson
  • 8,814
  • 29
  • 97
  • 125
9
votes
3 answers

Command-line utility to test fwmark in ip rule / ip route?

I am trying to find a tool that will allow me to find the route a packet will take that comes in on a device, and has a particular destination address. ip route get will do most of what I am looking for. The issue is that I would like to test…
msumme
  • 93
  • 1
  • 3
1
2 3
16 17