Questions tagged with Amazon EC2
Content language: English
Sort by most recent
Connection to my windows instance locate at Frankfurt, Zone A (eu-central-1a) is extremely slow recently. I tried, RDC and ping from using different ISP and also VPN but no luck. My internet connection is good, but RDC connection is either not established or freezes after a brief connection. My hosted website has also become also very slow. What could be the reason?
I'm using,
512 MB RAM, 1 vCPU, 30 GB SSD
Windows Server 2019
Frankfurt, Zone A (eu-central-1a)
When I was trying to connect to instances i can't able to connect to it ,it shows me an error network error : connection timed out
Hello,
I would like to ask if tomcat10 available in the official repo of Amazon Linux 2023, or at least is there any way to install tomcat10 using yum?
Thanks
DISCLAIMER: I am still a noob in this area so forgive me in advance for any wrong concept I may have.
A little bit of context of what I am trying to do...right now, we have an in-house big server with VMWare Workstation Pro and many VMs. Aside from that we have a hardware VPN. The VMWare VMs are all for internal usage (they are not accesses from outside) and the only way we connect to them is via the VPN and
local IPs.
We are now trying to move to AWS. For example, each VMWare VM will be replaced by a EC2 instance, etc. So far, I have a VPN setup following this [guide](https://docs.aws.amazon.com/vpn/latest/clientvpn-admin/cvpn-getting-started.html#cvpn-getting-started-routes). I can connect to the VPN from my Mac and everything works perfectly (I can access each EC2 instance with their private IPs etc). Additionally, I can confirm also that both, my Mac as well as EC2 instances do have access to internet while connected to the VPN.
However, for this to work, all my EC2 instances need to have a public v4 IP. And I don't really want them to have a public IP for these EC2 instances because of security reasons. I don't want these machines to be "seen" from outside as they are completely for internal usage and only accessed from the VPN. For example, as for right now, with the public IP I can still SSH/ping/whatever them. That's what I don't want.
My first experiment was to remove the public IPs from the EC2 instance. This bring the security aspect I want and I can access the machine with the private IP and the VPN. However.... the EC2 instance cannot connect to Internet when I do this.
From what I have been reading, I need a NAT Gateway. The problem is that I am not sure how to setup this in combination with the VPN setup I have.
Currently, this is what I have:
* I have a VPC with IPv4 CIDR 172.31.0.0/16 and 3 public subnets, one for each AZ (Availability Zone). That is, us-east-2a (172.31.0.0/20), us-east-2b (172.31.16.0/20) and us-east-2c (172.31.32.0/20).
* All EC2 instances are created within the us-east-2a (172.31.0.0/20) subnet.
* The VPC has an internet gateway attached.
* I have a Client VPN endpoints with Client CIDR 10.0.0.0/22 and it has one of the subnets associated as "Target network associations". The one with us-east-2a (172.31.0.0/20).
* The endpoint has a security group which does have a Outbound rules to allow all traffic.
* The endpoint has a "Authorization rules" to allow all the VPC and Destination CIDR 172.31.0.0/16 and another rule for destination 0.0.0.0/0.
* The endpoint has a "Route table" to allow all traffic for the selected subnet (172.31.0.0/20)
Any help would be appreciated.
In AWS EC2 when Launching an Instance from Template the search of the images does not find the image I want as well as the search in the Images page, I have to delete a chunk of the image name for it to find it, which takes up more time than it should and triggers me deeply.
Have the AWS naughty devs caused this pain to somebody else?
Any leads on how to fix it, who else we can ask or who else's communication platforms we can slap?
Thanks!
Hello gurus!
I have two private subnets A and B in the same AZ. I have also created an EBS volume in the same AZ. When I create an EC2 instance in subnet A I am able to use aws-cli to attach the volume. However, when creating an instance in subnet B, the "aws ec2 attach-volume..." results in a "Connect timeout..." error message. Note: The EBS volume is not attached to the instance in A when trying to attach it to the instance in B.
I am using Terraform for provisioning of the EC2 instance, including security group creation and instance profile. The only thing I am altering when trying subnet A vs B is the subnet. Nothing else is different.
When looking at the two subnets in AWS Console, they are identical, except for the CIDR, They are connected to separate NAT GWs and routing tables "of their own"
What am I missing?
Best regards
Vidar Evenrud Seeberg
Hello there,
i have currently** t3a.xlarge** instance running Ubuntu and would like to migrate to a **t4g.xlarge **to take advantage of performance of Graviton.
I am running Java and MySQL db.
How can I migrate it with minimal change?
Thanks
I have installed the reverse proxy with this config file in /etc/nginx/sites-available:
server {
listen 80;
listen [::]:80;
server_name example.com;
location /drivers {
proxy_pass http://127.0.0.1:5000;
proxy_redirect http://127.0.0.1:5000/ http://example.com/drivers/ ;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade" ;
proxy_read_timeout 20d ;
proxy_buffering off ;
}
}
When accessing http://127.0.0.1:5000, everything is working fine. But http://example.com/drivers leads to 502 error
Thanks a lot for your help
I have the following Cloudwatch alarm set on my instances:
```
aws cloudwatch put-metric-alarm \
--alarm-name stop-when-idle \
--namespace AWS/EC2 \
--metric-name CPUUtilization \
--statistic Maximum \
--period 300 \
--evaluation-periods 3 \
--threshold 10 \
--comparison-operator LessThanThreshold \
--unit Percent \
--dimensions "Name=InstanceId,Value=$INSTANCE_ID" \
--alarm-actions arn:aws:automate:$AWS_REGION:ec2:stop
```
However, it recently failed to run; it triggered successfully, and two seconds later attempted to run the stop action, but it says:
```
Failed to execute action arn:aws:automate:us-east-1:ec2:stop. Received error: ""
```
Looking at the full details, I see:
```
{
"alarmName": "stop-when-idle",
"alarmType": "MetricAlarm",
"timestamp": "2023-03-16T07:01:07.187Z",
"historyItemType": "Action",
"historySummary": "Stop EC2 Instance 'i-REDACTED' failed",
"historyData": {
"actionState": "Failed",
"stateUpdateTimestamp": 1678950065929,
"notificationResource": "arn:aws:automate:us-east-1:ec2:stop",
"publishedMessage": null,
"error": null
}
}
```
With no error listed. What can I do to figure out why this didn't work?
if my instance is running! can i change instance type or is there is any way for auto scaling and if there is a way how to do that?
I am attempting to setup Patch Manager for all my AWS instances but all my Ubuntu servers are failing on scan.
I've checked the servers to ensure the SSM agent is installed and the service is running.
Servers are running Ubuntu 22.04.2.
When I run a scan I receive the below output error:
/var/log/amazon/ssm/patch-baseline-operations/jmespath/visitor.py:32: SyntaxWarning: "is" with a literal. Did you mean "=="?
if x is 0 or x is 1:
/var/log/amazon/ssm/patch-baseline-operations/jmespath/visitor.py:32: SyntaxWarning: "is" with a literal. Did you mean "=="?
if x is 0 or x is 1:
/var/log/amazon/ssm/patch-baseline-operations/jmespath/visitor.py:34: SyntaxWarning: "is" with a literal. Did you mean "=="?
elif y is 0 or y is 1:
/var/log/amazon/ssm/patch-baseline-operations/jmespath/visitor.py:34: SyntaxWarning: "is" with a literal. Did you mean "=="?
elif y is 0 or y is 1:
/var/log/amazon/ssm/patch-baseline-operations/jmespath/visitor.py:260: SyntaxWarning: "is" with a literal. Did you mean "=="?
if original_result is 0:
No IMDS credentials found on instance.failed to run commands: exit status 156
So, have some DMP files that was exported from a oracle on premise, using expdp.
And now from the linux EC2 instance i need import those dumps that is already there if is possible using the impdp but since there is no access to directory in the RDS instance how to do that?
On linux i hace oracle installed and i can connect by sqlplus in the target db.