- 最新
- 投票最多
- 评论最多
Yes, it's possible to have the SMTP restriction lifted for your EC2 instance, but it requires a specific process:
By default, Amazon EC2 throttles outbound traffic on port 25 (the standard SMTP port) for all instances to prevent potential spam. This restriction applies to all EC2 instances and Lambda functions that aren't on an allow list.
To remove this restriction, you need to submit a request to AWS. Here's what you should do:
- Use the AWS support form specifically designed for this purpose.
- Provide a detailed explanation of why you need port 25 opened and how you plan to prevent spam or abuse.
- Include your EC2 instance ID (i-0dd7cef6cc050a06c) in the request.
- Submit the form and wait for AWS to process your request. This can take up to 48 hours.
- If approved, you'll receive an email notification that the port 25 restriction has been removed.
It's important to note that AWS may deny requests to open port 25, especially for testing purposes. As alternatives, consider using AWS Simple Email Service (SES) or ports 587 or 465 for SMTP connections, which are generally more secure and don't require special permission.
While waiting for a response, ensure that your EC2 security group allows outbound traffic on port 25, and check that your Network ACLs permit this traffic as well. Also, verify that your instance's operating system firewall isn't blocking port 25.
If you don't receive a response within 48 hours, you may want to open a support ticket with AWS for further assistance.
Sources
Not able to send mail from EC2 | AWS re:Post
how to open port 25 in cloudshell | AWS re:Post
Lift Port 25 Outbound restrictions on our EC2's | AWS re:Post
NVM. Someone suggested SES, which I've since implemented. This seems to work well as our volume is low. We just needed a way to email alerts to our techs.
相关内容
- 已提问 6 个月前
- AWS 官方已更新 7 个月前

You can consider using AWS SES service as an alternative. Much easier and highly available by default.