Hello, i encounter a problem with setting up policy routing with iptables. I need to route traffic to some IPs through VPN from all devices in my LAN.
First of all i'm create ipset of this IPs:
Next i'm tryin to MARK all packet from this IPS:
And get error:
What I doing wrong?
First of all i'm create ipset of this IPs:
Code:
#!bin/bash
ipset x
ipset create vpnset hash:net
for IP in `cat ipslist_collapsed_prefix`; do
ipset add vpnset "$IP"
done
Code:
admin@RT-AC68U-E330:/# iptables -t mangle -A PREROUTING -m set --match-set vpnset src -j MARK --set-mark 100
Code:
iptables: No chain/target/match by that name.
Last edited: