Questions tagged [iproute2]

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

Filter by
Sorted by
Tagged with
1 vote
2 answers
111 views

Pass web traffic to VPN endpoint other than the OpenVPN envelope through the VPN itself

I have a Linux server that is an OpenVPN endpoint, but also hosts a webserver. When my client connects to the server address for the webserver, the packets travel outside the VPN. Rightly so, since ...
user3450564's user avatar
0 votes
0 answers
19 views

Masquerading from a custom routing table does not work

In Ubuntu 22.04 server, masquerading/NATing from a custom routing table does not work (for VPN clients). It does work however when I do not route traffic to a custom table (and let it remain in the ...
Mustafa Mohiuodin's user avatar
0 votes
0 answers
64 views

Openstack VM AlmaLinux OS 9.3-Multiple subnet NIC not working

I have situation to migrate Centos 7.9 to Almalinux 9.3 VM. Everything is working after migration and i have problem with Openstack Multi NIC not working in different subnet in AlmaLinux 9.3 OS. eth0 ...
Ck_7's user avatar
  • 111
0 votes
1 answer
128 views

Debugging combination of tproxy and policy based routing

let me preface this by saying that I know I am combining a wild amount of things in here, but sometimes that is where things take you. So the scenario: I'm using squid and tproxy to transparently ...
Mart Allini's user avatar
0 votes
0 answers
139 views

Requests between docker containers on same host using the public IP

I have a server with Docker and some containers executing. The host has a public ip and a service listening on port 80 from one of the containers. If I try to wget the service using the public ip from ...
Giuseppe Nardiello's user avatar
1 vote
0 answers
221 views

How to make secondary IP routable

I am trying to assign a secondary IP to my primary interface. I added the IP to my eth0 interface ip addr add 172.20.14.253/21 dev eth0 $ ip a show dev eth0 2: eth0: <BROADCAST,MULTICAST,UP,...
Hussain Nagri's user avatar
0 votes
0 answers
45 views

In a Linux environment, does the order of commands "ip Route" affect routing?

I attached multiple ethernets to the server, one for LAN and the rest for PPPOE. Each packet connected to each PPPOE was sent by itself. It works fine on CentOS 6.10. In the 8 series, packets are ...
Cholho Lee's user avatar
1 vote
0 answers
277 views

network namespace with veth bridge not working - ICMP sent but no reply

I'm attempting to achieve a somewhat standard bridged netns setup with a veth pair, with one end in the ns and the other on the bridge : iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE iptables -...
simonw's user avatar
  • 35
1 vote
1 answer
241 views

VPN gateway in custom route table fails

My goal is configure a container behave as a router which load balances over a number of VPN connections. To do this I'm probabilistically marking initiating packets with: iptables -I PREROUTING -t ...
simonw's user avatar
  • 35
0 votes
0 answers
235 views

Best way of configuring a OpenVPN to allow access from the Internet to hosts behind a firewall

I have a Proxmox node with a bunch of VMs connected to a virtual bridged network. I have one VM on that bridged network that I want to connect to a Cloud VPS running OpenVPN. I then want to run an ...
obevan's user avatar
  • 1
0 votes
1 answer
794 views

How to set up Parallel Redundancy Protocol on linux?

I'm trying to setup a PRP connection between to Linux machines (Ubuntu 20-04 LTS) following the doc from TI. The module hsr is present (modprobe hsr works), but when I tried to use iproute2, it seems ...
grep's user avatar
  • 186
2 votes
1 answer
1k views

Why is Linux policy-based routing (PBR) not working for ping?

First of all, it seems as if this question is about Linux, but it seems to me that it is about basic routing concepts. I happen to have the following configuration: What I am trying to do is to ...
Tedpac's user avatar
  • 23
2 votes
1 answer
1k views

Use netns to bind programs to specific IP addresses

I have an IP address on my server, say, 192.168.0.3, I want to share in a net namespace, so to run apps there which will only be able to communicate to the internet using that 192.168.0.3. I can "...
Avenger's user avatar
  • 21
1 vote
0 answers
297 views

How to make Wireguard and Tasilscale coexist on the same machine?

Seems that restarting the wg service always creates a routing table with higher priority than Tailsales which results in the inability to. connect to the machine via Tailscale until both services are ...
dzhi's user avatar
  • 830
0 votes
1 answer
155 views

Ubuntu on VMWare with multiple adapters - can't ping outside

I've made a machine with 3 nic adapters. Everything works inside configured networks, but It looks like routing is not working correctly: ping 8.8.8.8 ping: connect: Network is unreachable Here's my ...
Alby11's user avatar
  • 123
1 vote
1 answer
1k views

How "ip route get" decides outgoing interface

Wondering what decides the outgoing interface. Here is my setup Eno1 - 192.168.3 0.2/24, Gateway - 192.168.30.1 Eno2 - 192.168.50.2/24, Gateway - 192.168.50.1 My routing table looks like this - [...
Manny's user avatar
  • 11
1 vote
1 answer
5k views

Ubuntu 22.04 Jammy netplan goes missing

I would like to know if anybody experienced this. I am running the server cli version of Ubuntu 22.04. After running apt, I see a message saying to run apt autoremove. (I did this) I also got a ...
Edwin Drood's user avatar
1 vote
1 answer
936 views

Linux with 2 Interface, ping secondary interface fault

I have ubuntu 20.04 server with 2 interfaces / eth0:94.101.177.244 eth1:94.101.176.149 Eth0 is work well and When i ping from server to out with eth1, it success. But when i ping from pc eth1, it ...
Mahdi's user avatar
  • 61
1 vote
0 answers
1k views

Multiple DHCP NIC and local LAN - Debian, Proxmox

tl;dr: How can i get 3 NIC to route, backup/failover and communicate together? I got a proxmox server with 3 NIC vmbr1: company lan - dhcp (engineering department) vmbr2: robotics network (static) ...
MightyMirko's user avatar
4 votes
0 answers
860 views

Setting up multiple IPv6 routes over a single interface on Linux

tldr; A LAN device is able to get 2 separate internet connection (1 NATted from ISP Router, 1 from manual PPP connection). Able to separate ISP-WAN and PPP-WAN IPv4 into 2 routes using ip rules but ...
RuMAN S's user avatar
  • 61
0 votes
0 answers
331 views

How can I set up a transparent proxy (TPROXY type) across network namespaces?

I want to setup a transparent proxy across network namespaces. I have two network namespaces, "nsx" and "nsy", each one has a veth pair, the pair of "nsx" is pointed to ...
phantomcraft's user avatar
0 votes
1 answer
215 views

Why "vlan: 3 parent interface: en0"

I have created a VLAN: Linux vconfig add en0 3 ip addr add 192.168.126.5/24 dev en0.3 ip link set up en0.3 can be translated to macOS by e.g. MacOS ifconfig vlan0 create ifconfig vlan0 vlan 3 vlandev ...
Chris G.'s user avatar
  • 227
0 votes
1 answer
998 views

List "hardware" Network Interfaces Controllers

When using ifconfig or ip link show commands, it lists not only hardware interfaces, but also software interfaces - I would expect only the physically interfaces? Note: I am running on MacOS. ip link ...
Chris G.'s user avatar
  • 227
0 votes
0 answers
2k views

Wireguard networking issues

I'm having some wireguard networking issues and hope you guys can help me. My goal is to build a side to side vpn. For that I have host A (public) and host B (private). Below is my config to create ...
Andreas's user avatar
3 votes
2 answers
2k views

In Linux how to add a route to a prefix via a specific device with certain destinations in that prefix going via default route?

I'm currently dealing with a VPN which connection endpoint lies within the subnet which prefix shall be tunneled via that specific VPN. Essentially the problem thus boils down to match against a (...
datenwolf's user avatar
  • 299
0 votes
1 answer
250 views

Redirect specific traffic through a VPN interface

I, I would like to redirect specific ports through a specific interface. Until now what I accomplished it was cat /etc/iproute2/rt_tables | grep "200 force.route" > /dev/null if [ $? != ...
Ricardo Matos's user avatar
0 votes
1 answer
458 views

Send response back through same device for connections coming in through Wireguard

I have a server lanserver running in my private LAN that is connected to a public server publicserver using Wireguard. publicserver forwards TCP connections to certain ports to lanserver through the ...
cdauth's user avatar
  • 993
3 votes
1 answer
3k views

Why I get "cache" in the output of `ip route get`?

I'm using kernel 5.11.0 and in the ip-route manual [1] it can be read: Starting with Linux kernel version 3.6, there is no routing cache for IPv4 anymore. Hence ip route show cached will never print ...
mosquetero's user avatar
0 votes
1 answer
410 views

Unable to use fwmark on Debian 11 (bulleyes) to change routing behavior

I have a recipe I already use on many cases, but this time doesn't works on Debian 11 (kernel 5.10.0-10-amd64) my setup is basically an internal interface eth0 for a RFC1918 LAN, and two external ...
dominix's user avatar
  • 456
0 votes
1 answer
2k views

Force new process to use the specific network interface (using netns/network namespaces)

I have a number of interfaces available on Ubuntu 20.04 machine. Among others enx0c5b8f279a64 and usb0 with the later being used as the default one. I want to make sure that a particular process ...
Kira's user avatar
  • 11
0 votes
1 answer
1k views

Ubuntu server as both a private NAT router and a public router

I am attempting to do something I've never tried before. I have a Dell PowerEdge 540 that I've installed Ubuntu on. I got a Comcast Business line installed, and have the following physical network ...
JimmyP624's user avatar
0 votes
0 answers
573 views

How to mark and separate connections?

I have a issabel Linux (based on Centos 7) with 3 ethernet, and I want this scenario: eth0 with IP 172.16.3.30/16 ----gw(172.16.0.1)----> (I want to use as Default Gateway) eth1 with IP 10.1.5.102/...
erfan mehralizadeh's user avatar
0 votes
1 answer
417 views

How to switch linux interface to trunk-only mode?

I'm trying to configure linux interface into trunk-only mode, that means 'accept only vlan-tagged traffic', and most importantly, ignore all untagged traffic. I'm pretty successful at having tagged ...
George Shuklin's user avatar
0 votes
1 answer
844 views

how to mark connections to route multiple gateways?

hi i am having trouble setting up permanent routes for my network interfaces, i have : os : linux (centos 7) eth0 : IP 172.16.3.6 -- Gateway : 172.16.0.1 eth0:1 : IP 10.1.5.102 -- Gateway : 10.1.5.101 ...
erfan mehralizadeh's user avatar
3 votes
1 answer
2k views

Linux: What causes static ARP entries to flush on link down

This is a question about a difference in networking behavior between Debian Buster (kernel 4.19.0-18) and Debian Bullseye (kernel 5.10.0-9). On Buster, proxy arp entries survive if the link on the ...
roelvanmeer's user avatar
  • 1,794
0 votes
1 answer
776 views

How to add a routing rule that only match "dport"?

In my OpenWrt box, I want to route only a specific protocol(tcp:1888) to a tun interface only for one PC(192.168.28.2), so I do as following: ip rule add from 192.168.28.2 dport 1888 lookup 123 ip ...
Leon's user avatar
  • 179
0 votes
1 answer
114 views

Within a gateway node how to route traffic to the outside world via a specific interface consistently?

I have linux ec2 instances with two nics (eth0 and eth2). Both the nics have public ip's attached to it and are able to get out to the internet. This linux instance is acting as a gateway node for me, ...
Karthik Balasubramanian's user avatar
0 votes
2 answers
2k views

How do i modify route tables in EC2 instance to send traffic via eth1?

I have an ec2 AmazonLinux2 instance. It has a primary nic on eth0. I went ahead and attached another eni (with an associated public ip) eth1. I would like to make sure that I can send traffic via the ...
Karthik Balasubramanian's user avatar
0 votes
0 answers
86 views

Clients couldn't query DNS server listening on router interface's secondary IP

I have a router where its interface has two IPs $ ip addr br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000 link/ether <MA> brd ff:ff:ff:ff:ff:ff ...
hgl's user avatar
  • 177
2 votes
0 answers
237 views

Routes in route6-eth0 don't apply [closed]

I made a file /etc/sysconfig/network-scripts/route6-eth0 with the following contents: default dev eth0 src ****:****::**** metric 50 pref medium However, it doesn't show up when I execute ip -6 route:...
Bas's user avatar
  • 21
1 vote
0 answers
1k views

Two instances of Dante proxy server with two interfaces

I'm running 2 instances of Dante server on my Linux machine, one of them is called danted which is supposed to connect me to the internet through the ethernet cable and the other is sockd which is ...
Shayan's user avatar
  • 85
0 votes
1 answer
337 views

Auditing specific route table operations

Does Linux have a way to audit operations run against a specific route table? I have the following config in my custom route table: default dev tun0 scope link 192.168.100.0/28 dev eth0 scope link ...
Mazzy's user avatar
  • 247
1 vote
0 answers
392 views

IPv6 multipath routing with configurable weight

With Linux kernel 4.14, when I add IPv6 multipath routes with weights (10 & 30), they are getting added with same weight '1'. IPv4 route does not have this issue. I checked with exact same steps ...
m.divya.mohan's user avatar
0 votes
1 answer
1k views

ipsec xfrm esp routing

i need a little help/explanation why the following netsetup is not working: PC1 (192.168.66.1) <-- PLAIN --> (192.168.66.2)PC-GW(192.168.88.2) <-- ESP --> (192.168.88.1) PC2 I can send ...
kita's user avatar
  • 3
2 votes
1 answer
8k views

Change an active slave of Linux network bonding interface without ifenslave command

Linux supports bonding of multiple Ethernet network interfaces for extra reliability or load balancing. Bonding driver used to be configured via ifenslave command, which has been deprecated (...
Mikhail Kupchik's user avatar
0 votes
1 answer
68 views

CentoOS and IP RULE

I don't understand my situation. I have a network lab like on a picture. I can't ping 192.168.5.1 from 192.168.1.2 then the 192.168.5.1 has 192.168.4.2 like a default gateway. Linux# ip route default ...
Paravozik's user avatar
2 votes
1 answer
446 views

How to force `ip route get` to ignore a specific device?

How can I do ip route get, but force it to ignore a specific device? When I start my VPN, I run ip route get <vpn_server_ip> to determine what interface to use to connect to the VPN. Then I add ...
Vinicius Fortuna's user avatar
3 votes
0 answers
278 views

WireGuard Failover for MySQL Galera Cluster

I'm setting up four servers across four locations in an attempt to create a geo-redundant MySQL Galera cluster. Two of the servers are behind NAT, and I'm currently attempting to use WireGuard to ...
TecumTechCEO's user avatar
0 votes
1 answer
4k views

How to bridge an internal network interface to an OpenVPN tun/tap device

I'm using a two-VM setup wherein the first VM, machine A, has a closed, private LAN shared with the second VM, machine B, which has a second network interface that is configured to hit the internet. ...
Qix - MONICA WAS MISTREATED's user avatar
1 vote
1 answer
202 views

ss --events no output on CentOS 7

I try to monitor continously TCP connections on a CentOS 7 box with the ss utility. If I start ss --events I recieve no events. Is there any trick to enable this? Or is the kernel (3.10) in CentOS 7 ...
krisek's user avatar
  • 13

1
2 3 4 5