Questions tagged [amazon-ec2]

For questions about using Amazon Elastic Compute Cloud in DevOps, including deploying, monitoring and scaling applications in EC2. For questions specifically about monitoring EC2 with [aws-cloudwatch] use that tag. For the EC2 container service use the [amazon-ecs] tag.

Filter by
Sorted by
Tagged with
0
votes
1answer
9 views

private subnets in an Auto Scaling Group on aws?

I watched a video series wherein the author used 3 private subnets for his Auto Scaling Group, and I also read the premium answer on this forum wherein the author says that you can use both public and ...
0
votes
1answer
9 views

Where is Puppet's enviroments directory on Amazon Linux2?

I am using Puppet version 3.8.7 on Amazon Linux2, trying to find the directory containing the Puppet environments. I tried to find it with the find command looking for files named "production" or ...
1
vote
1answer
21 views

Is there a way to clone an ec2 from inside the ec2 terminal?

I want to be able to back up my linux accadamy lab servers but they don't provide a way to to this. I'm wondering if it's posible to clone my EC2 lab server from inside the EC2 to get round this?
1
vote
0answers
19 views

Hasicorp Packer: InvalidSnapshot.NotFound: Snapshot does not exist

When I'm running sudo packer2 build -debug template.json with this code: { "variables": { "profile": "aws", "region": "eu-west-1" }, "builders": [{ "type": "amazon-chroot", "profile": "{{...
1
vote
1answer
19 views

How to ensure EC2's OS/application is loaded?

Recently I was playing around a bit with AWS as a part of a course that I am doing. I came across a situation that to be honest is keeping be in vilo. I made a web application which connects to a ...
1
vote
1answer
22 views

Kubernetes api service unit file

i was going through the kubernetes the hard way(kelsey), i see in the API server unit file with a cluster ip range as --service-cluster-ip-range=10.32.0.0/24 \ is it a default ip range ? my VPC ...
0
votes
0answers
37 views

Why am I experiencing delays in RDS vs EC2 local MySQL

I am trying to test a single tier software separated into 2 tiers on AWS. Before, the MySQl was local, now I am trying remote on RDS. The problem is I am seeing execution time differences on large ...
1
vote
1answer
26 views

What is the difference between EKS and EC2 installed kubernets?

I'm newbie in AWS usage. I don't understand the difference between EKS and EC2 installed kubernets? Amazon EKS makes it easy for you to run Kubernetes on AWS without needing to install and ...
0
votes
0answers
16 views

How do I detach an existing volume and attach a new volume using Terraform?

Is there a way to detach EBS volume from existing EC2 instance and attach a new EBS volume using Terraform ? I prefer to replace the volume rather than trying to destroy the instance and create a new ...
0
votes
1answer
18 views

How to setup a permanent storage volume for EC2 instance?

I created an EC2 instance of r5ad.xlarge and installed Jenkins on it. However, after a few jobs I configured and ran I saw a warning about no space left. Then realised Jenkins was installed on 8 GB ...
1
vote
1answer
25 views

can't access my instances by public IP in a VPC (aka: what is wrong with my terraform)?

As stated in the title of the question, I have a Terraform file (attached below), but the infrastructure it builds doesn't allow me to connect by SSH (I get "Connection timed out"). So either the ...
1
vote
1answer
25 views

When should an application be copied to a new region?

I'm taking my first course For AWS cloud practitioner and I am curious: The case: I have a single, client-facing application hosted on an EC2 instance. Let's keep it simple and say it's brochureware, ...
3
votes
1answer
38 views

How does the creation of an AMI on AWS work and why is the creation time unpredictable?

Creation date: September 23, 2019 at 9:22:06 PM UTC+2 21:48: still waiting for completion 21:53: completed Sometimes it takes 15 minutes and sometimes longer. How does a creation of an AMI work and ...
1
vote
0answers
24 views

What is the Young's Modulus for EC2?

Young's Modulus is defined as follows: Young's modulus or Young modulus is a mechanical property that measures the stiffness of a solid material In the case of AWS Elastic Compute Cloud (EC2), the ...
0
votes
0answers
9 views

DNS name creation with VPC and Route 53 DNS name difference?

I have created VPC with two subnets on ec2 instance. In the documents, it is mentioned that if I enable enableDnsHostnames and enableDnsSupport parameter in AWS template in VPC, it will create ec2-...
0
votes
1answer
24 views

How to avoid a high number of requests for avoiding Amazon AWS EC2 instance AutoScalin?

If I set autoscaling for an EC2 instance in Amazon Web Services, how can I set optimized autoscaling for large numbers of connections in order to avoid unusual autoscaling?
0
votes
1answer
16 views

Ansible ec2_vpc_net and ec2_vpc_subnet - where to set subnet default public ip

Since upgrading to these 2 Ansible modules I am having difficulties in setting the subnets to have default public IP when new instances are created by autoscaling? I can't find any setting on the ...
1
vote
0answers
36 views

Multiple VPC with overlapping CIDR

I am part of a large company that is either buying other companies and merging their assets into ours or having rouge development teams getting AWS accounts and then having to bring them under the ...
0
votes
1answer
31 views

How to probe all running aws ec2 instances and their sec groups, etc to generate templates?

Typically I spin up all aws ec2 instances together with all its accompanying security groups, volumes, etc ... by executing a series of aws cli commands. However when I manually use the aws console ...
1
vote
0answers
91 views

Terraform destroys and creates new AWS resources

Terraform destroys and creates new AWS resources when I modify the modules with new resources. I tried with: lifecycle { prevent_destroy = true } Getting the below error : the plan would ...
0
votes
1answer
27 views

Which AMI was my EC2 instance created from? [closed]

Is there any way to tell which AMI my EC2 instance was created from?
1
vote
1answer
23 views

How to manage Hashicorp Vault patching in AWS?

I'm setting up a Hashicorp Vault open source deployment in AWS, but I'm trying to figure out the best approach for keeping the underlying EC2 instances patched. I'm using AWS Systems Manager for ...
1
vote
1answer
17 views

Aws autoscaling group in private subnet, private communication?

I have a scenario - I have configured my frontend application in one autoscaling group and my backend application is in another autoscaling group. I'm using the load balancer also. But I don't want ...
0
votes
1answer
8 views

multiple projects per EC2 with Load Balancers

I have 2 EC2 instances and an Application Load Balancer. The Load is not too high, but I'm keeping both instances working just in case. Plus, it saves the time on deployment with (one at a time) and ...
0
votes
1answer
13 views

Custom metric for a Windows process on a Windows ec2 instance

I have a process (exe) on a Windows ec2 that is using up lots of memory. I would like to create a custom metric that will collect data and send to CloudWatch. I would like to also create an alarm when ...
1
vote
1answer
33 views

How to fail stack when EC2 spot is refused?

I'm using AWS Cloudformation to create EC2 spot instance (with block duration). In order to do this in cloudformation I'm using a Launch Template where spot configuration is set. Then my ...
0
votes
0answers
43 views

kubernetes service's dns not resolved inside cluster

i have setup a Service on my cluster, but can access it from pods only with the ip:port that are specified in the "Endpoints:" of the service. Instead i would like to use my-service.default.svc....
0
votes
1answer
53 views

Can't get P3 spot instance on AWS

I'm new to aws-ec2. I'd like to make spot request for a p3.2xlarge instance in my local region (EU-Ireland) to benchmark V100 Tesla GPUs against my home GPU for deep learning. I have already ...
0
votes
1answer
19 views

Spot block vs reserved instances

Let's say we have a continuous process where each two hours we receive some data which has to be analysed by a fleet of workers on AWS EC2 instances which always complete their job within two hours (...
0
votes
1answer
58 views

AWS Site crashes every few hours

Every few hours, my Laravel website on AWS Elastic Beanstalk crashes and throws the following error: [Sun May 19 13:06:13.436195 2019] [php7:error] [pid 3431] [client] PHP Fatal error: require(): ...
1
vote
1answer
45 views

Why does Docker fail to start on AWS ECS instances. ECS stateful instance fails initialization. ECS stateful instance doesn't join the ECS cluster

The ECS instance fails to join the ECS cluster because it relies on docker to launch its ecs agent. If in this case docker fails to start then the whole process halts. Docker fails to start in AWS ...
1
vote
1answer
35 views

Cross account access from ec2 to other accounts

Is it possible to run aws cli from ec2 to create some resources in another account without using aws_secret_key and aws_access_key?
0
votes
1answer
278 views

How can I access the console of a booting EC2 instance in AWS?

I'm new to AWS and am looking for a way to access my EC2's console so I can triage issues such: boot to single user mode view console output as system boots gain console access to debug GRUB issues
0
votes
1answer
21 views

compiled opencv copy to another host

Every time I spawn a new host I need to compile OpenCV on Ubuntu following official manual. The problem is that it takes about 20-30 minutes depends on the VM type. Is it somehow possible to store the ...
2
votes
0answers
36 views

How to use ecs service dicovery

I'm trying to use amazon service discovery to register a Redis server in order to be reachable by other ECS services in the same cluster. I'm using EC2 to deploy my services not Fargate, so service ...
0
votes
2answers
304 views

What is the cheapest way to get CI for a Qt project?

To build up my portfolio I'm writing an application to showcase all the best practices I'm aware of, including unit tests and continuous integration. The project was originally started in C++, and I ...
0
votes
1answer
17 views

How to make Load balancer to wait for custom program to finish running?

I have a problem I am trying to solve. When the auto scaling creates a new EC2 instance, the load balancer gets a positive health check result fairly quickly. However, the problem is that we have a ...
3
votes
1answer
60 views

How to securely pass sensitive data to EC2 Spot instances?

Right now, we only use EC2 on-demand instances, and we provision sensitive data (credentials, private keys, etc.) on the instances' EBS which are encrypted with a KMS key. My understanding is that I ...
1
vote
2answers
227 views

ansible aws windows ec2 - Internal Error: this connection module does not support running commands via sudo

I am getting below error when I am trying to run one playbook which connects to Windows machine hosted on AWS EC2. I enabled winrm and win_ping worked fine but when I am invoking ansible-playbook I am ...
1
vote
1answer
385 views

How to pass HashiCorp Vault secrets(k/v passwords) to Terraform EC2 instance

How can we pass HashiCorp Vault secrets, k/v username/password and feed Terraform while its creating Ec2 instance. For example, i don't want to use in plain text variable "myvariable" { default = "...
1
vote
1answer
399 views

How to re-enable RDP on AWS-EC2 instance

Accidentally i disabled RDP on EC2 windows machine and now I am not able to access it via RDP, Is there any way to re-enable RDP service on EC2 instance?
1
vote
0answers
667 views

How to override the user for ECS task via CLI?

I've got a Task Definition with parameters which executes a script using a regular user. I'd like to test the script without changing the Task Definition by overriding the default user which script ...
4
votes
2answers
306 views

Is containerized deployment of jenkins on ECS better than running jenkins inside EC2 instance to secure pipeline information?

I am new to AWS, docker and jenkins. I want to run a jenkins build pipeline and I have tried using following two ways on AWS: Running jenkins inside the EC2 instance following the steps at this AWS ...
1
vote
1answer
46 views

Can I check whether ansible is on last batch of rolling update (serial: 25%)?

I'm using Ansible to update a pool of EC2 servers with a rolling update, in batches of 25%. In between batches, I'm pausing long enough for the server health checks to start to pass again (since they'...
0
votes
2answers
1k views

Transfer files and execute commands from jenkins scripted pipeline to AWS instance

I want to transfer files and execute a few commands on remote AWS instance from Jenkins. I have the following methods in mind to do the same. Note that my Jenkins server is running in the local server,...
1
vote
1answer
40 views

How do Django deployments happen on Servers?

I am new to Django six months ago and I learned how to deploy the Django projects to EC2 instances. Basically 1st time when the Django project is deployed to EC2, the instance will be configured ...
3
votes
4answers
180 views

Digital Ocean vs AWS EC2 for Laravel based application

I'm working on a project based on Microservice architecture in Laravel, which means I'll have many small apps and Databases, I'm confused weather I should buy AWS EC2 or Digital Ocean's hosting. My ...
1
vote
1answer
92 views

Rancher, Load Balancing and own domain

I have a question about rancher. I'm running my rancher on aws. I have created a new cluster with two nodes (workers) and I have deployed my docker images. Now I wanted to add Load Balancer, but I don'...
7
votes
2answers
172 views

Best way to launch 100 identical Docker machines on AWS?

I need to do some large scale testing on a system. The system consists of 2 main parts: Manager and Nodes. There will be only one manager server, but 100 nodes. Both the manager and nodes are Docker ...
6
votes
1answer
512 views

AWS ECS/EKS: EC2 vs Fargate mode

Amazon offers the option of launching their container management services ECS and EKS in two modes: EC2 and Fargate. In the former, normal VMs (EC2 instances) are used and ECS or EKS (depending on ...