Questions tagged [amazon-linux-2]
55 questions
0
votes
1 answer
Amazon Linux 2 - EC2 PostgreSQL
I've the following:
Amazon Linux 2
Postgres 12 installed a user created
I'm using ssh to connect to my instance.
The issue is that it doesn't let me to connect to my postgres database. I've created a user using something like:
create user myuser…

Pablo Pantaleon
- 103
- 4
0
votes
1 answer
How to upgrade from Python 2 to python 3 on Amazon Linux 2?
I created a new AL2 EC2. I see Python 2 is already installed.
How can I upgrade this to Python 3 WITHOUT using virtualenv? I would like to maintain ONLY ONE version of Python.

Biju
- 125
- 1
- 4
0
votes
1 answer
Using EC2 imagebuilder to populate authorized_keys from s3 does not work
I'm struggling to setup imagebuilder to populate authorized_keys file from S3 file on a Amazon Linux 2 instance.
IAM role is functionnal and pipeline runs fine (no error, nor output)
Here is the recipe i'm using
description: This is hello world…

vfrans
- 43
- 1
- 7
0
votes
1 answer
Trying to send mail through mailx and postfix, but receiving nothing in inbox
I'm trying to set up a type of notification system that will alert me when my website is down using crontab and mailx. I went ahead and installed mailx on my server and then tried to send a simple test email by doing: mail -s "Testing" myemail.com…

Michael
- 101
- 1
0
votes
0 answers
(AWS) ALB with ec2 instances Amazon Linux and Nginx
I want to use Nginx in Amazon Linux intances. If I use a single instance with a public IP granted by Amazon, the configuration works. Then when I add an ALB and later add the target group the app fails. The same configuration with apache works…

user_af
- 23
- 4
0
votes
2 answers
how to install certbot on Amazon Linux 2
I have an EC2 VM running Amazon Linux release 2 (Karoo)
How can I get certbot?
It comes with the awscli tools installed, which seem to be incompatible with the certbot in epel:
$ sudo bash
# yum install -y epel-release
# yum-config-manager --enable…

Rich
- 704
- 14
- 30
0
votes
2 answers
Open SSL throwing unknown option '-n' in Amazon Linux2 instance
My code throws error when it reaches this line:
{% set encrypted_password = salt['cmd.run']('openssl enc -aes-128-cbc -a -salt -md md5 -in <(echo -n "' + ssm_plaintext_password +'") -pass pass:'+random_password) %}
Error:
[ERROR ] Command…

Reshma
- 1
0
votes
1 answer
Unable to access console or SSH on Amazon Linux 2 KVM image
I am trying to create a KVM guest instance running Amazon Linux 2 in an on-premises environment, on a CentOS 7 host. I am doing this over SSH (e.g. my local machine -> SSH to the CentOS host).
I know my hypervisor setup works, as using the following…

turbonerd
- 76
- 5
- 19
0
votes
0 answers
Locked of Server, how to run sudo passwordless
Here is the issue
Created a new server with Amazon Linux 2
Removed ssh-key from default root user (ec2-user)
Created two new accounts with sudo access without a password
Now I got locked out of the root access in this server, anytime I run a…

asosnovsky
- 101
- 1
-1
votes
1 answer
Why are some of my Secondary IPs missing after a YUM update on Amazon Liunx 2
On Sunday, I did a Yum Update on my Amazon Linux 2 instance (a T2.Medium) and after the update only 2 IP addresses per interface were working. Before the update I had 6 IPs per interface. It looks like either the kernel update or the ec2-net-utils…

iewebguy
- 213
- 1
- 3
- 7