Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AWS CloudWatch agent shows "cwoc_status": "stopped"

I have installed AWS CloudWatch agent on my EC2 instance and configured with the amazon-cloudwatch-agent-config-wizard. The AWS credentials are stored in .aws/credentials and picked up by the wizard during configuration.

Now I am checking the status of the agent, but I do not understand what "cwoc_status": "stopped" refers to?

Here the output of the agent status:

ubuntu@ip-address:~$ sudo /opt/aws/amazon-cloudwatch-agent/bin/amazon-cloudwatch-agent-ctl -m ec2 -a status
{
  "status": "running",
  "starttime": "2021-02-09T05:37:12+00:00",
  "configstatus": "configured",
  "cwoc_status": "stopped",
  "cwoc_starttime": "",
  "cwoc_configstatus": "not configured",
  "version": "1.247347.3b250378"
}

like image 403
Alessandro Baffa Avatar asked Feb 09 '21 06:02

Alessandro Baffa


Video Answer


2 Answers

I finally discovered that cwoc refers to AWS-OpenTelemetry Collector, which I think has been installed by default by amazon-cloudwatch-agent.deb that I used to install the CWAgent on my EC2. I found it by doing the following grep

ubuntu@ip-address:/opt/aws/amazon-cloudwatch-agent$ grep -r cwoc

which found the string in the file /opt/aws/amazon-cloudwatch-agent/bin/amazon-cloudwatch-agent-ctl where I found that reference to the folder /opt/aws/amazon-cloudwatch-agent/cwagent-otel-collector.

Googling otel-collector I found the OpenTelemetry Collector.

like image 155
Alessandro Baffa Avatar answered Oct 09 '22 20:10

Alessandro Baffa


cwoc is for open telemetry for use by tools like NewRelic and others. But many of those tools now will read from Cloudwatch to avoid the hassle of configuring every server.

like image 1
sknutsonsf Avatar answered Oct 09 '22 21:10

sknutsonsf