Issue Running Commands on Amazon Linux 2023 t3.small EC2 Instance

0

I've recently launched an Amazon Linux 2023 EC2 instance of type t3.small. However, when I attempt to run any command, I encounter the message "Waiting for process with pid to finish," and the command never completes.

Strangely, I only face this issue on the t3.small instance. I also created a t2 instance, and everything runs smoothly; I can install packages and execute jobs without any problems.

Has anyone else experienced a similar issue with t3.small instances on Amazon Linux 2023? Any insights or suggestions on what might be causing this problem would be greatly appreciated. I am certain it is from AWS itself.

Thanks in advance for your help!

Vahid
질문됨 4달 전346회 조회
2개 답변
0

Hello.

It may depend on the command you executed, but does the answer at the URL below solve the problem?
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org/thread/XQLTADPT4TLNCL2GZUAOLMBEACOGOKYP/

Check for lock files.
ls /var/cache/dnf/*pid
If you have any remove them and try running dnf again.

profile picture
전문가
답변함 4달 전
  • Thank you. When I run ls /var/cahes/dnf/*pid I got this error: No such file or directory.

  • However to get around this 1- I used the EC2 t2.small and installed every thing on it. 2- created AMI of the t2 and finally 3- Lunched a t3.small with the AMI. Everything seems to be working fine now.

0

when I attempt to run any command, I encounter the message "Waiting for process with pid to finish,"

Any command? So if you run date or whoami or echo Hello you get this error?

As @Riku_Kobayashi also identified in his answer, the error message is consistent with dnf (or yum in the old days) trying to be run while there's a dnf/yum process already running. But it can also happen if a previous dnf/yum process doesn't exit cleanly and leaves a lock file.

In your three-stage solution that you outline, when you have a t2.small and installed every thing on it do you do a dnf update -y as part of step 1? This would mean the RPMs are already at their latest versions, so in step 3 when you deply the new AMI on the t3.small, a dnf update -y will complete more-or-less immediately because there's nothing to do. And once dnf has completed you will not get Waiting for process with pid 12345 to finish.

profile picture
전문가
Steve_M
답변함 4달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠