CPU usage over 100% on amazon-ssm-agent

0

Hi,
Hi, we have an ec2 instance with amazon-ssm-agent installed on it.. it's topping out with over 100% CPU just a few minutes after restart, causing all other ECS services on the machine to get killed due to lack of CPU.

We've tried two versions - latest = 2.3.701.1
and a downgraded version = 2.3.662.0

Both versions exhibit this behavior...

JonasL
已提問 5 年前檢視次數 4615 次
4 個答案
0

Hi JonasL,

Thank you for posting here. Could you please provide the following information to help us investigate this issue?

  1. Instance type
  2. AMI id
  3. Region
  4. Logs about amazon-ssm-agent
已回答 5 年前
0

Sure:
AMI id - amzn-ami-2017.09.f-amazon-ecs-optimized (ami-acb020d5)
Instance type - m5.xlarge
Region - eu-west-1

Logs attached

JonasL
已回答 5 年前
0

Turns out there was a bug in the executable that the ssm-agent tried to restart. This caused the ssm-agent to re-try to execute the script even though it was failing - causing the 100% cpu.

JonasL
已回答 5 年前
0

Hi JonasL,
Base on the log, there are over 180 command executions within 2 mintues. All the commands have the same content, all excutions completed with failed status (no retry).

The high CPU usage was related to the nubmer of the commands have been executed.

Do you have configuration (StateManager, CloudWatch) that sends commands to the instance after restart?

Regards,
Shihua

已回答 5 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南