CentOS 7.xファイアウォールの問題

785 ワード

システムctlによるサービスとプログラムの管理
  • ファイアウォールステータスの表示systemctl status firewalld
  • ファイアウォールsystemctl start firewalld
  • を開く.
  • ファイアウォールsystemctl restart firewalld
  • を再起動
  • ファイアウォールsystemctl stop firewalld
  • を閉じる.
  • ファイアウォール起動禁止systemctl disable firewalld
  • firewall-cmdによる管理
  • ファイアウォールのステータスを確認するfirewall-cmd --state
  • オープンポートfirewall-cmd --list-ports
  • を表示
  • オープンポートfirewall-cmd --zone=public --add-port=80/tcp --permanent
  • firewall-cmd --reload-ポートを閉じるfirewall-cmd --zone=public --remove-port=80/tcp --permanent
  • を再読み込みします.
    zone #   
    add-port=80/tcp #    ,   :  /    
    permanent #    ,