Questions tagged [aws-ec2-instance-connect]

Amazon EC2 Instance Connect provides a secure way to connect to instances using Secure Shell (SSH). You use AWS Identity and Access Management (IAM) policies and principals to control SSH access to instances, removing the need to share and manage SSH keys. All connection requests using EC2 Instance Connect are logged to AWS CloudTrail to enable auditing of connection requests.

See: Connecting to Your Linux Instance Using EC2 Instance Connect

61 questions
8
votes
2 answers

Creating a user and adding public key on aws ec2 instance

I've created a user and copied the public key to .ssh/authorized_key for that new user and also I've set the pubkeyauthentication to yes on /etc/ssh/sshd_config after saving the file restarted the sshd service. When I try to ssh from the new user I…
7
votes
1 answer

Amazon EC2 Instance Connect for SSH - security group?

I'm using the new (june 2019) EC2 browser SSH connect feature to shell into a EC2. This is very convenient, since I'm on Windows and it's annoying to configure PuTTy with AWS auth and the legacy browser SSH offering never worked right for me. I can…
Adam Hughes
  • 14,601
  • 12
  • 83
  • 122
4
votes
1 answer

EC2 Instance Connect - Which AWS IPs For Inbound For Browser Console Access?

I have instance connect working fine from the CLI on my local machine as I have my ip added to the security group for the ec2 instance for inbound ssh access. However, the browser-based version in the EC2 Console seems to need me to add all internet…
3
votes
1 answer

Getting Error - allocation failure scavenge might not succeed & Allocation failed - JavaScript heap out of memory

React Version: 18.2.0 Node.js version: v16.18.0 Npm version: 8.19.2 **Problem ** I am getting error in my AWS EC2 t2.micro Ubuntu OS while building my react-app. Whenever I try to use npm run build I get following error <--- Last few GCs…
3
votes
1 answer

AWS CF Template for provisioning new EC2 instance with Existing Targetgroup

I'm trying to provision a new EC2 instance and attaching it to the existing targetGroup which I created earlier. I do have the targetGroupArn, and the new instance details. In all the documents, I could see the sample templates of creating a new…
Sonu
  • 179
  • 1
  • 11
3
votes
1 answer

Connection failure using EC2 Instance Connect (browser-based SSH connection)

Launching an AWS EC2 instance seems quite straightforward although when it comes to connecting to the newly launched instance things get sticky. The process for connecting to an instance proposed by such a tech giant is very counter-intuitive. As a…
Dude
  • 191
  • 3
  • 12
2
votes
1 answer

How to create a new SSH Key pair and assign it to an EC2 instance which currently does not have one?

I am trying to connect to an AWS RDS MySQL instance (private subnet) via MySQL Workbench. My VPC contains: EC2 instance (public subnet) RDS instance (private subnet) I can access the RDS via EC2 but cannot connect to the RDS instance via my local…
2
votes
1 answer

ec2 instance connect endpoint: kex_exchange_identification: Connection closed by remote host

I am following this documentation and I try to ssh to the private ec2. I have created the ec2 connect endpoint and I am able to use to connect from the console. When using ssh from my mac terminal, I have below message: ssh -i .pem…
2
votes
3 answers

Failed to connect to your instance in aws

Hi I am trying to connect my EC2 instance for opening CLI but unfortunately I am getting error: Failed to connect to your instance and my IP address is also not working http://54.179.118.182/ Please help me how can I can resolve this. Failed to…
2
votes
1 answer

ssh: connect to host 18.116.70.233 port 22: Connection timed out

When I try to connect ec2 instance using this command from Ubuntu terminal: ssh -i "private_key.pem" ubuntu@ip_address after taking some times it shows: ssh: connect to host 18.116.70.233 port 22: Connection timed out Note that: 1.firewall is…
2
votes
1 answer

EC2 Window Instances - Paste Files

We have two EC2 Window instances. We had no issues copy a file from our local PC to the first EC2 instance. For some reason, we cannot complete the same function in the second EC2 instance. The paste option is grayed out when we attempt. Both…
2
votes
2 answers

How to connect to an existing EC2 Instance and execute a shell file using CloudFormation Template

I know that it's possible to use a CloudFormation template to launch a new EC2 instance in AWS and install any packages using user data. But is there any way to connect to an existing instance and execute a shell file using the CloudFormation…
2
votes
2 answers

parameters needed for connecting to aws rds instance via ssh

Does anyone know where to find the values needed for the parameters required for an ssh connection involving a bastion host and an AWS RDS instance? I have listed what I have been able to find so far below: SSH Hostname - Endpoint given for RDS…
1
vote
0 answers

SELENIUM: XPATH of the element works in window not in linux machine (ec2-**-**-\*\*.us-east-2.compute.amazonaws.com)

driver.find_element(By.XPATH,'//body/div/div/div/div/div/div/div/div/div[2]/div/div/div/div/div/div/div/div[2]/div/div/input').send_keys(country) This is the xpath for sending text in the dropdown of the facebook ad library report. It works well in…
1
vote
0 answers

Getting SSH authentication error while connecting to EC2

As a newbie, I'm trying to upload and run a Dockerfile on EC2 through GitHub Actions but I am getting this error: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain. I configured…
1
2 3 4 5