Questions tagged [iproute2]
iproute2 (ip) is a tool used to manipulate network configurations.
241
questions
0
votes
0
answers
53
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,...
0
votes
0
answers
38
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 ...
1
vote
0
answers
161
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 -...
1
vote
1
answer
122
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 ...
0
votes
0
answers
182
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 ...
0
votes
1
answer
305
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 ...
2
votes
1
answer
525
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 ...
2
votes
1
answer
359
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 "...
0
votes
0
answers
210
views
Make WireGuard server accessible via multiple interfaces
I have a Raspberry Pi running WireGuard listening on port 51820. The Pi is connected to the my router via eth0 (192.168.1.51) and wlan0 (192.168.1.50), with the eth0 route having higher priority. My ...
1
vote
0
answers
177
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 ...
0
votes
0
answers
232
views
2 Interfaces with different metric, and a single default gateway - losing connection
I have a weird issue. I have two interfaces:
One is my WiFi,
The other is a 4G USB
I am trying to set up the default GW through the 4G USB (which is NATed by the 4G provider, hence, I can't SSH ...
0
votes
0
answers
179
views
Ubuntu/netplan/iproute: route everything except specific /24 across interface
2 VLANs
10.160.32.0/24 on ens160 -> * (assume multiple non-merging subnets)
10.192.16.0/24 on ens192 -> management
Through ens160 I can hit other networks via routing.
Through ens192 is my ...
0
votes
1
answer
138
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 ...
0
votes
1
answer
810
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 -
[...
0
votes
0
answers
68
views
Port forwarding via vpn connection
I have two RHEL servers, one frontend and one backend. The connection of which is like this:
----eth0---frotnend---eth0 -------- eth0 ----- backend
Also, I've set port forwarding between two servers ...
1
vote
1
answer
3k
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 ...
1
vote
1
answer
364
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 ...
1
vote
0
answers
875
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)
...
4
votes
0
answers
710
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 ...
0
votes
0
answers
233
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 ...
0
votes
1
answer
178
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 ...
0
votes
1
answer
895
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 ...
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 ...
3
votes
2
answers
1k
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 (...
0
votes
1
answer
226
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 [ $? != ...
0
votes
1
answer
372
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 ...
3
votes
1
answer
2k
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 ...
0
votes
1
answer
358
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 ...
0
votes
1
answer
1k
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 ...
0
votes
1
answer
923
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 ...
0
votes
0
answers
462
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/...
0
votes
1
answer
318
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 ...
0
votes
1
answer
788
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
...
3
votes
1
answer
1k
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 ...
0
votes
1
answer
498
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 ...
0
votes
1
answer
92
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, ...
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 ...
0
votes
0
answers
74
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
...
2
votes
0
answers
202
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:...
1
vote
0
answers
990
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 ...
0
votes
1
answer
196
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
...
1
vote
0
answers
287
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 ...
0
votes
1
answer
789
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 ...
2
votes
1
answer
6k
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 (...
0
votes
1
answer
65
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 ...
2
votes
1
answer
352
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 ...
2
votes
0
answers
267
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 ...
0
votes
1
answer
3k
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.
...
1
vote
1
answer
169
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 ...
0
votes
1
answer
552
views
Linux internet default gateway + VPN default gateway
I'm currently using a barracuda vpn client to connect to a vpn, which sets a default gateway for the vpn, routing all traffic through it. I've read about iproute2 and secondary routing tables, but my ...