【问题标题】:mirroring traffic with iptables doesn't work使用 iptables 镜像流量不起作用
【发布时间】:2014-07-09 03:43:58
【问题描述】:

我想将特定流量镜像到 ip 192.168.200.1 我使用以下解决方案:

Mirror Port via iptables

但是,当我输入以下命令时,会出现此错误:

iptables –I PREROUTING -t mangle -j ROUTE --gw 192.168.200.1 --tee

iptables v1.4.12: unknown option "--gw"

当我将“--gw”替换为“-gateway”时,如下所示:

iptables –I PREROUTING -t mangle -j ROUTE -gateway 192.168.200.1 --tee

出现此错误:

iptables v1.4.12:multiple -j flag not allowed

这是为什么?

【问题讨论】:

    标签: iptables mirror


    【解决方案1】:

    试试:

    iptables -t mangle -A PREROUTING -j TEE --gateway 192.168.200.1
    

    对于那个版本的 iptables -j ROUTE 不起作用。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2022-08-17
      • 2014-05-21
      • 2016-12-05
      • 2021-12-14
      • 2015-12-04
      • 1970-01-01
      • 2020-05-24
      • 1970-01-01
      相关资源
      最近更新 更多