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

learn more… | top users | synonyms

3
votes
2answers
99 views

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 ...
2
votes
0answers
52 views

How to route traffic through different interfaces based on the port number?

iptables -A PREROUTING -i usb0 -t mangle -p tcp --dport 8080 -j MARK --set-mark 1 iptables -L Chain INPUT (policy ACCEPT) target prot opt source destination Chain ...
3
votes
1answer
97 views

Change source IP address based on the system user

I would like to make a certain user have a specific source IP address. For this purpose, I added a secondary IP address to the network interface and tried to enforce the source IP using ip6tables and ...
0
votes
1answer
115 views

Failed to ping through gateway which is not default gateway

I have the following network interface configuration, eth0: 192.168.78.1/24 eth1: 192.168.254.76/24 (Gateway 192.168.254.1) eth2: 192.168.253.131/24 (Gateway 192.168.253.1) where both gateways ...
25
votes
4answers
1k views

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 ...
1
vote
1answer
998 views

ip route add works manually but throws “Error: an inet prefix is expected rather than …” when run via bash script

I'm trying to run a script that should add this route to a table 11: ip route add local 10.1.3.212 dev eth1 proto kernel scope host src 10.1.3.212 table 11 If I run this command manually, it is ...
0
votes
1answer
94 views

What is the meaning of “/usr/bin/ip route add 180.151.157.4/32 via 0.0.0.0”

In the process of setting up a VPN client side, openvpn tries to add a route but it fails: /usr/bin/ip route add 180.151.157.4/32 via 0.0.0.0 RTNETLINK answers: No such device The reason why we add ...
2
votes
1answer
149 views

OpenVPN redirect-gateway breaks other tunnels

This is my ifconfig setup: eth1 Link encap:Ethernet HWaddr 54:04:a6:49:99:16 inet addr:192.168.0.12 Bcast:192.168.0.255 Mask:255.255.255.0 inet6 addr: ...
0
votes
0answers
335 views

OpenVPN --route-up Missing environment variables when passing to script

I'm diving into the glory of OpenVPN and I'm having a bit of trouble manually configuring the routing tables. I'm on Arch Linux. I know OpenVPN automatically updates the routing tables when ...
0
votes
0answers
40 views

Conflicting ip routes with local table on attaching a virtual network interface

I have an EC2 instance with these ip rules: $ sudo ip rule show 0: from all lookup local 32766: from all lookup main 32767: from all lookup default I can attach an elastic network interface to ...
0
votes
2answers
534 views

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
votes
0answers
28 views

What is the relationship between iproute2 and distro config files?

For various ip manipulation activities, what is the difference/relationship between iproute2 and modifying the distro's config files? For instance, some sources recommend ip address del for deleting ...
2
votes
2answers
189 views

ip link set not assigning IP Address but ifup does

Since ip is set to replace ifconfig, I'm trying to get myself used to using the ip suite of commands. I'm trying to enable my NIC with ip link set eth3 up That doesn't assign an IPv4 address ...
6
votes
0answers
428 views

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 ...
0
votes
0answers
123 views

No connectivity between aliased IP networks of different subnet

I am trying to set up two virtual networks(different subnets) to test site to site VPN in my Laptop. My host OS is Debian Wheezy and i am using Virtual box to virtualise my setup. I have two aliased ...
1
vote
0answers
159 views

Routing LDAP traffic from Application server to Proxy to internet

I've included a drawing so you get an idea how it would work. (Red = LDAP connections , Blue = HTTP / AJP in the backend) Problem: We want to connect our customer application server to an LDAP of ...
1
vote
1answer
366 views

Reply on the same interface as incoming with DNATed IP

A server has 3 ifaces, 2 internal (eth1/2) in different public networks, one external (eth0). There is a service (openvpn) that can't bind to some IPs/ifaces, only to all or one, but I need it to ...
-1
votes
1answer
47 views

How to choose source IP from multiple virtual IP's based on specific destination

I am having two private IP attached to an interface. inet 10.255.0.127/24 brd 10.255.0.255 scope global eth1 inet 10.255.0.153/24 brd 10.255.0.255 scope global secondary eth1 When traffic leaves ...
0
votes
1answer
528 views

IP/GRE compiled in kernel but gre0 interface doesnt exist

Im trying to create IP over GRE tunnel but i get No such device: ip tunnel add gre0 mode gre remote 192.168.152.22 local 192.168.152.21 ttl 255 ioctl: No such device I have compiled GRE support in ...
2
votes
1answer
291 views

iptables - Multiple IP's, only one is IP Prerouting correctly

I am trying to redirect all requests on port 80 to port 9000 across all my IP's I have 1 server hosting several IP addresses on eth0. For the sake of my problem, lets say they all use apache to ...
1
vote
1answer
178 views

How to override default source address on packets originating from a router

My broadband router runs PPPoA and is dynamically assigned a single ipv4 internet address by my ISP. I have a static subnet which I host on a linux router/firewall (called chenin). The linux firewall ...
0
votes
0answers
75 views

Multiple routes and gateways with NAT

My setup is a VM host with two network interfaces where I want to use one as private/internal and the other one as public (which will get a public address on the host), where all the NAT magic to the ...
0
votes
1answer
295 views

Route traffic to some host in Internet via VPN server

I need route traffic to some host in Internet via VPN server. Configuration: Computer: ubuntu-12.04 eth0 - x.x.x.x/24 tun0 - inet addr:10.8.0.6 P-t-P:10.8.0.5 Mask:255.255.255.255 There is ...
1
vote
3answers
707 views

Incoming (ingress) traffic shaping on Linux - bw is lower than expected

I want to limit incoming (download) speed for Linux box. Both, the box, which is configured, and trafic source (HTTP server) are connected to the same switch, if shaping is not configured, download ...
3
votes
3answers
2k views

Almost working: How to set up iptables and iproute2 rules on dual WAN linux server?

I have a Raspberry Pi (running Raspbian) with three network interfaces (one ethernet and two USB wifi nics). What I want to achieve is this: I have two WAN connections to the internet (DSL + Cable), ...
0
votes
2answers
288 views

How to DHCP request a second, different, IP for the same physical interface?

(Similar to this question, but with two different DHCP-assigned IPs) Is there any way to let dhclient or dhcpcd request two different IPs for one physical interface, e.g. via virtual interfaces eth0 ...
6
votes
1answer
839 views

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 ...
1
vote
1answer
101 views

Forwarding ports from server with 2 internet connections

I have 3 interfaces on my main server, first is used for the local network, second and third are internet connections (each has its own ip routing table): eth0 192.168.0.1 eth1 9.9.9.9 eth2 7.7.7.7 ...
0
votes
1answer
113 views

Linux Firewall & sharing files between computers in different subnets connected to single switch

EDIT : I've edited the question & the title to bring more clarity hoping that someone will be able to point me in the right direction. ************************* * Internet ...
1
vote
0answers
53 views

what is PAT exactly?

In attempt to understand PAT, I've setup the following setup where I have a Linux Router that masquerades from in internal interface to the external. Thus both clients are able to talk to outside ...
0
votes
1answer
108 views

Multi-homing: ip rule syntax for multiple uplinks

I'm trying to create ip rules for multiple WAN links and keep connectivity across multiple local networks. I have currently two network cards each connected to a different gateway to the internet ...
1
vote
2answers
85 views

Is it possible to see the routing table at the gateway (next-hop) router?

Suppose the output of the "route -n" (on Red Hat/Debian) command is as follows: Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 a.b.c.d 0.0.0.0 ...
0
votes
1answer
144 views

Special setup for a linux server to route to itself

I've got two linux servers in question. When one server initiates a request for a specific IP address that the other server has, I would like the initiating server to route the request back to itself ...
0
votes
1answer
319 views

Can a machine(physical or virtual) accept and process UDP packets with a different IP address coming from a known device?

Before everything, thanks for reading the next question. I have script,(ipUDPspoof.rb), which is a client/server script in Ruby (you choose the parameter 1 to be server and 0 to be client, at ...
0
votes
1answer
2k views

iptables: Internal port forwarding with fwmark and routing tables

I have 2 servers and I need to forwart to internal port. To explain I use the server with 2 interfaces (internal/external) as server A and the internal server as server B. In server A i use ...
0
votes
1answer
214 views

Troubleshooting a failing SIP connection

I have a linux Asterisk server that is behind a firewall. The firewall has three interfaces : eth0 is the LAN, where Asterisk resides, eth2 is the default gateway to the internet (via an ADSL modem ...
1
vote
1answer
1k views

Static route without knowing the nexthop (linux)

I have an eth3 interface in a linux router, with an adsl modem. This adsl modem is in bridged mode, so the public IP is assigned to eth3 (say 11.22.33.44), and the modem is just not seen by my server. ...
0
votes
1answer
1k views

Got “RTNETLINK answers: Invalid argument” when trying to add a IPv6 route

When I try to add an IPv6 route I get an error message: root@lx-anielsen ~ $ ip -6 route add ::a:6:0/112 via ::a:4:1 dev eth1.1001 RTNETLINK answers: Invalid argument Here is what my interface ...
0
votes
1answer
151 views

Routing config between internet load balancers and backend

Im facing a problem due my lack of experiencie on routing. I need to config the next things (all run on my computer virtualized, if works, i will pass it to hardware) [internet] ---- ...
3
votes
1answer
264 views

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 ...
0
votes
1answer
158 views

Multiple VPN devices with the same IP

Well, this is a rather awkward inquiry and I'm pretty pessimistic about it, but lets see what the community has to say. The scenario: A server connecting to multiple VPN endpoints doing all sort of ...
90
votes
4answers
12k views

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 ...
1
vote
3answers
2k views

Linux policy routing - packets not coming back [closed]

i am trying to set up policy routing on my home server. My network looks like this: Host routed VPN gateway Internet link through VPN 192.168.0.35/24 ---> 192.168.0.5/24 ...
1
vote
0answers
61 views

Multiple Internet connections, multiple networks and split access in Linux [duplicate]

Possible Duplicate: load balancing multiple gateway using route and iptables I am having trouble setting up multiple internet connections for split access in Linux. We have 3 internet ...
1
vote
2answers
195 views

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.
3
votes
1answer
679 views

Why doesn't TUN device have BROADCAST flag?

When creating a TUN device in Linux, on my machine the created TUN device has following flags: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> Clearly MULTICAST is listed in there but not ...
1
vote
2answers
486 views

Gateway redundancy on a single subnet

I'm trying to discover if there are any methods to have more than 1 default gateway (in a fail-over strategy) on a single subnet. If one gateway goes down then I would like to have servers fail-over ...
0
votes
1answer
126 views

Deleting all IPs on an interface with iproute2

I have an interface that I setup like this ip addr add 192.168.1.1/24 dev eth0 ip addr add 192.168.1.2/24 dev eth0 ip addr add 192.168.1.3/24 dev eth0 etc. Is there an easy way to delete all of ...
3
votes
1answer
280 views

Iproute2 tools vs conntrack tools

I have a linux box which is setup as firewall/gateway for the network. Was just wondering why ss and other iproute2 tools show much less than iptables conntrack. Is it because the router function is ...
-1
votes
2answers
1k views

Route forwarded traffic through eth0 but local traffic through tun0

I have a Ubuntu 12.04/Zentyal 2.3 server configured with WAN NATed on eth0, local interfaces eth1 and wlan0 bridged on br1 on which DHCP runs, and an OpenVPN connection on tun0. I only need the VPN ...