構成

インターネット — eth0-ゲートウェイサーバ-eth1 — なんかのサーバ

 

ゾーンを確認

# firewall-cmd --get-active-zone
public
  interfaces: eth0 eth1

 

ゾーンを変更

# nmcli connection modify eth1 connection.zone internal
# nmcli connection modify eth0 connection.zone external

 

設定確認

#  firewall-cmd --zone=external --query-masquerade
yes

#  firewall-cmd --zone=internal --query-masquerade
no

 

ゾーンを確認

# firewall-cmd --get-active-zone
external
  interfaces: eth0
internal
  interfaces: eth1

 

ちなみに、こちらは自動的に有効化される

  • iptablesだと変更はしてくれなかったかな
#  cat /proc/sys/net/ipv4/ip_forward
1

 

 

<スポンサーリンク>

コメントを残す

メールアドレスが公開されることはありません。 が付いている欄は必須項目です

*

日本語が含まれない投稿は無視されますのでご注意ください。(スパム対策)