Questions tagged [amazon-ec2]

Amazon Elastic Compute Cloud (EC2), which allows users to rent virtual computer systems, is part of Amazon Web Services.

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

Failed to get D-Bus connection: Connection refused

A sudo user named my-host is getting the following error message when trying to reload systemctl on an Amazon Linux 2 EC2 image. [my-host@ip-12-3-4-56 ~]$ systemctl --user daemon-reload Failed to get ...
1
vote
0answers
33 views

Start systemd service from Ansible Playbook

What specific syntax must be used to get an Ansible playbook to successfully start a systemd service and make sure that the systemd service is running on an Amazon EC2 instance? CURRENT SYNTAX: The ...
0
votes
2answers
24 views

How to store usage and memory percentage that are shown after login in AWS EC2

ec2 stats when we ssh into our instance we can see these stats displaying. Is there any way to get the same percentage stats with a terminal command?
0
votes
0answers
17 views

Investigating runaway traffic

On RHEL I have a server that every few days for few minutes sends 50x connection requests to the db. I couldn't find a lead in: crontab history of the users /var/log/messages nor secure How can I ...
0
votes
1answer
20 views

SSH pem/private-key based login error?

I just created an ec2-instance with Amazon Linux 2 OS, then logged in to the system using login: ec2-user and an associated privatekey. Next, I created a new user x and copied the .ssh/authorized_keys ...
1
vote
1answer
26 views

Reset Linux EC2 Server Password

Unable to login to EC2 ubuntu server due to permission issue. Issue: My EC2 ubuntu server has (root & ubuntu) user and I use to login to ubuntu using ssh. By mistake I have changed the ownership ...
0
votes
0answers
42 views

Access mounted directory in Linux

I have mounted 2 directories in my Linux system. $ df -h Filesystem Size Used Avail Use% Mounted on devtmpfs 7.7G 0 7.7G 0% /dev tmpfs 7.7G 0 7.7G 0% /dev/shm ...
0
votes
0answers
127 views

sudo service sshd restart failed on AWS EC2 instance

I have created AWS EC2 instance and deployed Asp.Net Core Web API application. It works when deploying into server. After an hour, I was not able to connect my server using PUTTY or WinSCP. When i am ...
2
votes
1answer
198 views

No package systemd available on Amazon linux EC2

I am using AWS Linux machine to host Web API application. I need to make my application keep on run, so that i need systemd has to be installed on my linux machine.I tried sudo yum install systemd but ...
0
votes
0answers
50 views

aws ec2 describe-security-groups + awk sed

I am sure this is not the most efficient method, but I need help formatting the results of this aws command: aws ec2 describe-security-groups --group-ids sg-xxxxxxxxxxxxx --region=us-east-1 --profile=...
1
vote
2answers
156 views

Why does `pip` throw `ModuleNotFoundError` even though `setuptools` appears to be installed?

On an EC2 instance, I am attempting to install a Python package using pip, but receive an exception that states ModuleNotFoundError: No module named 'setuptools'. For context, the command I run is pip ...
0
votes
1answer
760 views

DISPLAY environment variable not set

I am using a Amazon Linux 2 (a Fedora/Cent OS like distro) EC2 machine with the Deep Learning AMI (Amazon Linux 2) Version 30.1 AMI. I want to use xclip and gedit in the remote instance. But if I type ...
0
votes
0answers
23 views

Xubuntu GUI not loading?

I just installed xubuntu-core on my amazon-ec2 server, but I can't get it to load into a UI. When I try to use sudo startx it throws an error, while sudo service lightdm start doesn't seem to do ...
1
vote
1answer
19 views

how to add password to an account that was created using --disabled-password?

I am following the guide add new user accounts with SSH access to my Amazon EC2 the point 2 has this note If you add the new_user to an Ubuntu instance, include the --disabled-password option to ...
0
votes
0answers
13 views

SUSE HA Cluster OverlayIP removal after reboot - SLES 12 SP4 (AWS EC2)

We are facing an issue with SUSE HA cluster nodes, Whenever a reboot happens on any of these HA nodes, Overlay IP is getting removed. Can someone help resolve this issue? Here is the configuration ...
5
votes
2answers
151 views

Setting ownership when copying or syncing files

When moving or copying files as root I often want to set the ownership for those files based on the owner of the directory I am moving the files to. Before I go off and write a script that parses the ...
0
votes
2answers
37 views

How to run an app automatically on reboot for different user?

I have a ec2 machine/redhat with Tomcat installed. I want only userX to start this app, not ec2-user. However, ec2 automatically boots with ec2-user after restart. How can I make my userX to execture ...
0
votes
1answer
26 views

ansible show hostnames in play recap summary instead of IPs when using ec2 dynamic inventory?

how to make ansible show host names from ec2 dynamic inventory tags or /etc/hosts instead of IPs in PLAY RECAP SUMMARY: Output: PLAY RECAP **************************************************************...
1
vote
1answer
109 views

Disconnected: No supported authentication methods for sudo user who authenticates using password

On an Amazon Linux 2 EC2 instance, password authentication from remote users has been enabled by running the following command during the cloud-init startup script: sed -i 's/PasswordAuthentication no/...
0
votes
2answers
34 views

Missing chrony package in Ubuntu Bionic

I am using HashiCorp Packer to build a new AWS AMI. I want to preinstall the NTP client Chrony (it's popular in our organization and it will get config support from people outside our team). But when ...
0
votes
0answers
57 views

How to encrypt nfs which is mounted on AWS ec2

We have netapp volumes attached to EC2 instance. these are nfs , which are sync with on premise and make sure data in on premise and that of NFS which is mounted on EC2 are in sync. even though ...
0
votes
0answers
15 views

Error in metric filter pattern in CloudWatch

I am trying to create the custom CloudWatch metric from the Log Groups I am trying to create the metric pattern for the status of the email. I just need to monitor the the response in email(success/...
0
votes
0answers
24 views

Rsync performance on on two Linux Machines

I am having two Virtual Machines (VM-source and VM-destination) and each with an NFS filesystem. I want to sync data (1TB) between the two machines and I am worried about the CPU/Memory needed for ...
0
votes
0answers
26 views

How to keep mac prompt customization when sshing into aws ec2 instances whose ip addresses change when I stop and restart the instance?

Summary: my goal is to have a prompt that's got a different color so I can easily distinguish between command line and output at a glance. Details: I have configured my mac terminal to show the ...
1
vote
1answer
46 views

Relationship between AWS EC2 VPC and Xen Networking

Does characteristics of networking configuration on AWS VPC (public IP, private IP, subnets, route and gateway) are derived of Xen networking model?
0
votes
1answer
79 views

How to help AWS EC2 crontab find a package?

I am new to AWS and Linux. I just set up my first AWS EC2 instance, (Amazon Linux 2 AMI (HVM)), transferred a simple Python project to it with scp, connected to the instance with ssh, installed ...
0
votes
1answer
294 views

Failed to authenticate with public key in jenkins

I have two different servers: Jenkins EC2 instance (my vuejs application) So When I am trying to deploy vuejs application using Jenkins SSH Plugin to remote server but it can't connect The log : ...
0
votes
0answers
36 views

RHEL 8.1 Custome Lorax-Composer AMI Image Fails to Start

I'm using Lorax-Composer to try and build a custom RHEL 8.1 image for upload to amazon AWS. For testing I am using a generic image built with Lorax and just a baseos install. I've followed the ...
0
votes
0answers
29 views

AWS: Connections drops after scp to ec2 instance. Have to stop/start ec2 insdtance to reeconnect

New to AWS: I ssh into my ec2 instance without issue until I use scp to copy files from another Linux box. 5 seconds after the transfer the connection is closed and the ec2 instance needs to be ...
2
votes
1answer
686 views

Timeout when connecting RDS using AWS session manager via EC2 instance

I am having trouble accessing AWS RDS instance in a private subnet using session manager through ec2 instance (Ubuntu). Port forwarding using AWS Session manager - aws ssm start-session --target ...
0
votes
0answers
30 views

How to forward path along with port

I'm willing to bet I have a fundamental misunderstanding here, but I am trying to do something akin to port-forwarding AND url-forwarding without using something like nginx. I have a remote linux ...
0
votes
2answers
150 views

What does “status=10/n/a” mean in systemd output?

I am developing a .service file so that systemd can manage an app as a service on Amazon Linux 2. But when I type systemctl start my-new-service, the following error is reported in the logs: Mar ...
-3
votes
1answer
114 views

mkdir permissions needed for script called by systemctl start service

How can I give mkdir permissions to a script that is called by sudo systemctl start <service-name> ?? Here is the error being thrown in the results of sudo journalctl -u jekyll -f when I type ...
-2
votes
1answer
212 views

Ubuntu Cronjob can't execute conda environment

Whenever I login to my ec2 Ubuntu instance my terminal is like this (base) ubuntu@ip-xx-xx-xx When I run my Python script which is converted from a Jupyter notebook with the default conda ...
0
votes
1answer
204 views

SSH into an AWS EC2 instance running a VPN

I want to use a third-party VPN service on a Amazon AWS EC2 instance, and set up NordVPN with OpenVPN. After following the instructions in this answer I'm still not able to SSH into the instance ...
1
vote
1answer
337 views

unable to recognize file. connection refused

On an Amazon Linux 2 instance, the command line is throwing the following connection refused error every time a command is run that references a file path. The same error is thrown when an https url ...
1
vote
2answers
41 views

Ability to halt/reboot server as user

I need to ability to halt an aws EC2 server as user. I found https://www.cyberciti.biz/tips/howto-linux-allow-users-to-shutdown-server.html but due to the fact that I need this feature on an aws EC2 ...
0
votes
0answers
94 views

EC2 SSH connection refused after changing elastic IP and reboot

I've browsed several dozen copies of this question but none of them seem to fix my situation. I have already checked: permissions on pem key (it worked before) checked correct new ip in ssh config ...
0
votes
1answer
54 views

Issue in configuring zpool ZFS in EC2

While executing command in ZFS - sudo zpool create -f alluxio /dev/xvda . Getting below error:/dev/xvda is in use and contains a unknown filesystem. Could you please help me in solving this. Need ...
0
votes
2answers
100 views

aws ec2 ls command is showing the user@ip:directory/folder on the last line - How can I remove this from my ls output?

When I perform an ls command in my aws ec2 server, I am getting the correct list of files which I need, but for some reason the user@ip:directory/folder is showing on the last line of my results? Is ...
0
votes
2answers
132 views

Install additional software in Amazon Linux

I have created Amazon Linux instance on Amazon Lightsail cloud. Now I would like to install Mosquitto buy entering command: sudo yum install mosquitto But system codn't find it. UPD I tried to add ...
0
votes
0answers
14 views

I am trying to redeploy a react application on an AWS ubuntu and the .sh file has permission denied error

I am trying to redeploy a react application in an aws EC2 ubuntu instance, but it says it has no permission for a .log, while running the .sh file. I tried chmod +x file.sh, but it says that the log ...
0
votes
0answers
1k views

Failed to start OpenBSD Secure Shell server

I have an EC2 instance which has been running for about 1 year. We have always been able to connect via SSH without issue until yesterday, when suddenly after a reboot all my connections are refused....
0
votes
0answers
84 views

Apache server at new AWS EC2 instance is not reachable even with “All source” and 0.0.0.0/0

I have installed Apache2 server and I am able to access my EC2 public DNS address from EC2 instance terminal with: curl http://ec2-xx-xxx-xx-xxx.us-east-2.compute.amazonaws.com/ which returns a ...
0
votes
0answers
45 views

EnvironmentFile not read in systemd - AWS EC2 Linux2 [duplicate]

I'm trying to configure environment variables to a service that's setup with systemd. The service is starting fine with systemctl start onboarding.service but somehow the environment file present in ...
0
votes
3answers
3k views

How do I resize this AWS EC2 ubuntu 18 instance from 16GB to 100GB

I need to resize /dev/nvme0n1p1 15G 10G 6G 64% / Filesystem 1G-blocks Used Available Use% Mounted on udev 16G 0G 16G 0% /dev tmpfs 4G ...
1
vote
0answers
189 views

Running cgroups inside EC2 c4.xlarge instances failed - operation not allowed

Problem I'm currently trying to restrict the resource of of a specific user on an AWS EC2 instance. After doing some research online, I thought the following was enough to add a user to a cgroup that ...
2
votes
1answer
94 views

unable to setup gunicorn daemon process

I am unable to set up the gunicorn daemon process in an ec2 instance. Below are sample code and error/log messages. myproject-backend/gunicorn.conf import os import multiprocessing from dotenv ...
3
votes
0answers
38 views

Restrict special user and host of the ftp in the Linux Instance

I am using WinScp for connecting FTP to a Linux Instance and I want to restrict special user and host. I installed plesk on my Linux EC2 instance and I thought it uses proftpd for ftp service and ...
3
votes
1answer
43 views

Restrict special user and host of ftp in the Linux Instance

I am using WinSCP for connecting ftp to Linux Instance and I want to restrict special user and host. I install plesk on my Linux Ec2 instance and I thought it is using proftpd for ftp service and ...

1
2 3 4 5
7