Enable ipv6 multiple route tables in kernel.
Enable ipv6 iptables in kernel and user space.
Enable iproute's ipv6 support.
1. use ip6tables match packet and set the mark at the hook of PREROUTING.
2. add route to route tables. N is route table's index.
#ip -6 route add default via gw dev eth%d table N
3. add rule to map packet to route tables according to skb's mark. M is rule's index.
#ip -6 rule add fwmark X table N prio M
阅读(1628) | 评论(0) | 转发(0) |