centos 79 安装ufw
To install UFW (Uncomplicated Firewall) on CentOS 7.9, you can follow these steps:
-
Update the system packages:
sudo yum update -
Install UFW:
sudo yum install ufw -
Enable UFW to start on system boot:
sudo systemctl enable ufw -
Start the UFW service:
sudo systemctl start ufw -
Check the UFW status:
sudo ufw statusYou should see the UFW status as "inactive" initially.
-
Configure UFW rules as per your requirements. For example, to allow SSH connections, you can use the following command:
sudo ufw allow sshYou can add other rules based on your needs.
-
Enable UFW:
sudo ufw enableConfirm the operation by typing 'y' and pressing Enter.
-
Check the UFW status again:
sudo ufw statusYou should see the UFW status as "active" with the configured rules.
That's it! You have successfully installed and configured UFW on CentOS 7.9
原文地址: https://www.cveoy.top/t/topic/hKvh 著作权归作者所有。请勿转载和采集!