- 论坛徽章:
- 0
|
配置了PPTP,有位朋友写了一下给我,运行也没错,发现不知如何才能找到这记录,想把它删除
[mw_shl_code=html,true]firewall-cmd --permanent --direct --passthrough ipv4 -t nat -A POSTROUTING -s 192.168.10.0/24 -j SNAT --to-source 你的公网ip
firewall-cmd --permanent --direct --passthrough ipv4 -t nat -A POSTROUTING -s 192.168.10.0/24 -o eth0 -j MASQUERADE[/mw_shl_code]
下面是自己找的命令,倒时可以把add 换成 query 可以查询到是否有记录,换成remove就能删除。上面就不知如何查了
[mw_shl_code=sql,true]firewall-cmd --permanent --direct --passthrough ipv4 -t nat -A POSTROUTING -s 192.168.10.0/24 -j SNAT --to-source 你的公网ip
firewall-cmd --permanent --direct --passthrough ipv4 -t nat -A POSTROUTING -s 192.168.10.0/24 -o eth0 -j MASQUERADE[/mw_shl_code]
同时NAT转发,上面两段,各有什么区别 |
|