This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
сервис_nat [2024/04/08 16:06] val |
сервис_nat [2024/04/08 16:36] val [nftables] |
||
---|---|---|---|
Line 69: | Line 69: | ||
<code> | <code> | ||
- | nft add rule nat postrouting ip saddr 192.168.22.0/24 oif eth1 snat to 10.5.7.122 | + | # apt install nftables |
- | nft list ruleset | + | ... |
+ | # nft add rule nat postrouting ip saddr 192.168.22.0/24 oif eth1 snat to 10.5.7.122 | ||
+ | |||
+ | # nft list ruleset | ||
+ | |||
+ | # file /etc/nftables.conf | ||
+ | |||
+ | # systemctl enable nftables.service | ||
</code> | </code> | ||