Datadog-agent: Agent has no way to disable /proc/diskstats check in OpenVZ environments

Created on 25 Mar 2018  路  2Comments  路  Source: DataDog/datadog-agent

Output of the info page (if this is a bug)

2018-03-25 10:53:22,916 | ERROR | dd.collector | utils.dockerutil(dockerutil.py:143) | Failed to initialize the docker client. Docker-related features will fail. Will retry 0 time(s). Error: Error while fetching server API version: ('Connection aborted.', error(2, 'No such file or directory'))

Collector (v 5.22.3)

Status date: 2018-03-25 10:53:15 (6s ago)
Pid: 29903
Platform: Linux-2.6.32-042stab127.2-x86_64-with-centos-6.9-Final
Python Version: 2.7.14, 64bit
Logs: , /var/log/datadog/collector.log, syslog:/dev/log

Clocks
======

NTP offset: -0.002 s
System UTC time: 2018-03-25 14:53:23.143257

Paths
=====

conf.d: /etc/dd-agent/conf.d
checks.d: Not found

Hostnames
=========

socket-hostname: donkey.folden-nissen.com
hostname: donkey.folden-nissen.com
socket-fqdn: donkey.folden-nissen.com

Checks
======

apache (1.1.1)
--------------
  - instance #0 [ERROR]: '403 Client Error: Forbidden for url: https://jira.myfnmc.com/server-status?auto'
  - Collected 0 metrics, 0 events & 1 service check

ntp (1.0.0)
-----------
  - Collected 0 metrics, 0 events & 0 service checks

disk (1.1.0)
------------
  - instance #0 [ERROR]: "[Errno 2] No such file or directory: '/proc/diskstats'"
  - Collected 8 metrics, 0 events & 0 service checks

network (1.4.0)
---------------
  - instance #0 [OK]
  - Collected 18 metrics, 0 events & 0 service checks

jmx (5.22.3)
------------
  - instance #jmx-jira.myfnmc.com-8099 [OK] collected 13 metrics
  - Collected 13 metrics, 0 events & 0 service checks

Emitters
========

- http_emitter [OK]

====================

Dogstatsd (v 5.22.3)

Status date: 2018-03-25 10:53:18 (4s ago)
Pid: 29897
Platform: Linux-2.6.32-042stab127.2-x86_64-with-centos-6.9-Final
Python Version: 2.7.14, 64bit
Logs: , /var/log/datadog/dogstatsd.log, syslog:/dev/log

Flush count: 59
Packet Count: 560
Packets per second: 1.3
Metric count: 14
Event count: 0
Service check count: 1

====================

Forwarder (v 5.22.3)

Status date: 2018-03-25 10:53:23 (1s ago)
Pid: 29896
Platform: Linux-2.6.32-042stab127.2-x86_64-with-centos-6.9-Final
Python Version: 2.7.14, 64bit
Logs: , /var/log/datadog/forwarder.log, syslog:/dev/log

Queue Size: 255 bytes
Queue Length: 1
Flush Count: 197
Transactions received: 198
Transactions flushed: 197
Transactions rejected: 0
API Key Status: API Key is valid

======================

Trace Agent (v 5.22.3)

Pid: 29895
Uptime: 600 seconds
Mem alloc: 2497352 bytes

Hostname: donkey.folden-nissen.com
Receiver: localhost:8126
API Endpoint: https://trace.agent.datadoghq.com

--- Receiver stats (1 min) ---

--- Writer stats (1 min) ---

Traces: 0 payloads, 0 traces, 0 bytes
Stats: 0 payloads, 0 stats buckets, 0 bytes
Services: 0 payloads, 0 services, 0 bytes

Describe what happened:
In OpenVZ environments, /proc/diskstats is not exposed to the guest OS. So, even though I am running a mix of Centos 6 and 7 environments, all my hosted servers are seeing the disk stats fail

Describe what you expected:
Provide some method to disable this check in config. I honestly don't care if this check is enabled by default, just so long as it can be disabled for those of us on OpenVZ environments

Steps to reproduce the issue:
Run dd-agent on any guest linux environment on an OpenVZ server

Additional environment details (Operating System, Cloud provider, etc):
Run on Ramnode as a host: http://www.ramnode.com/
CentOS release 6.9

Most helpful comment

I should note I've searched for several hours a day for a few days with no apparent solution that I can find.

All 2 comments

I should note I've searched for several hours a day for a few days with no apparent solution that I can find.

Hi @LordPsycho202! Sorry for responding this late. You're using v5 of the Agent, the present repo is for Agent v6, as such this issue should be reported on the dd-agent repo instead.

The disk check is enabled by default with a .yaml.default file that's shipped with the agent package. On Agent v5, that file is located at /etc/dd-agent/conf.d/disk.yaml.default, if you want you can remove that file and restart your Agent to disable the disk check completely.

I'll go ahead and close this issue, but feel free to respond here if you're still having issues.

Was this page helpful?
0 / 5 - 0 ratings