EC2 > Instances > Launch an instance ; for Application and OS Images Firewall necessary? even after setup security group

0

Hi, I set up security group for the instance, as you know I added rules for the ports over there

Do I need to enable ufw ? When I did 'sudo ufw status', it says 'status inactive'

Thanks Sung

已提問 1 年前檢視次數 221 次
1 個回答
0

Security groups and UFW have overlap in what they do for your instance. They both can block traffic based on port, protocol and source addresses, but UFW has many additional features:

  • automatically blocking addresses for incorrect authentication attempts
  • reporting and logging with rsyslog support
  • packet forwarding
  • scripting support for automation
  • integration with web hosting panels (WHM and Plesk for example)

Security groups have a few advantages over software firewalls; API support and IAM integration are just a few examples. In a fleet of hundreds of instances it's often a more simple approach to change 1 security group rule than to change the UFW configuration of each instance individually. Software firewalls also consume resources within the operating system. If you add enough rules eventually the system can slow down as it checks each rule for every connection. Using security groups offloads this work for more efficient filtering.

My recommendation is to start with security groups and then to only add a software firewall if these additional features are needed. Many customers use security groups and network ACLs without any software firewall, but there is certainly nothing wrong with adding one for a specific use case.

https://help.ubuntu.com/community/UFW https://docs.aws.amazon.com/vpc/latest/userguide/vpc-security-best-practices.html

profile pictureAWS
James W
已回答 1 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南