AWS CloudWatch Agent Network Metrics

0

Hi, I'm trying to set up an CloudWatch Agent to see networking details in my AWS server. I have created a role with CloudWatchAgentServerPolicy and attached it to my instance. I have installed the agent on my server and configure with the following settings

{
    "agent": {
        "metrics_collection_interval": 10,
        "logfile": "/opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log"
      },
    "metrics": {
        "namespace": "CWAgent",
        "append_dimensions": {
         "InstanceId": "${aws:InstanceId}"
    },
    "metrics_collected": {
      "ethtool": {
        "interface_include": [
          <InterfaceID>
        ],
        "metrics_include": [
          "rx_packets",
          "tx_packets",
          "bw_in_allowance_exceeded",
          "bw_out_allowance_exceeded",
          "conntrack_allowance_exceeded",
          "linklocal_allowance_exceeded",
          "pps_allowance_exceeded"
         ]
        }
      }
    }
  }

However it does not show any collected data on the web. Also, ethtool -S <interfaceID> Command only returns rx_gso_checksum_fixup not the configured metrics. Is there anything I do incorrectly?

Oguz
질문됨 한 달 전134회 조회
1개 답변
0

Can your verify that cloudwatch agent daemon is running?

sudo /opt/aws/amazon-cloudwatch-agent/bin/amazon-cloudwatch-agent-ctl -m ec2 -a status

You may also want to check log file for any errors.

sudo tail /var/log/amazon/amazon-cloudwatch-agent/amazon-cloudwatch-agent.log

Refer to Troubleshooting the CloudWatch agent for more troubleshooting details.

AWS
전문가
Mike_L
답변함 한 달 전
  • It is running and I've examined the log file there is no errors or warnings either.

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

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

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

관련 콘텐츠