Agent Commands

このページは日本語には対応しておりません。随時翻訳に取り組んでいます。
翻訳に関してご質問やご意見ございましたら、お気軽にご連絡ください
For Linux based systems where the service wrapper command is not available, consult the list of alternatives.

Start, stop, and restart the Agent

Start the Agent

List of commands to start the Datadog Agent:

PlatformCommand
AIXstartsrc -s datadog-agent
LinuxSee the Agent documentation for your OS.
DockerUse the installation command.
Kuberneteskubectl create -f datadog-agent.yaml
macOSlaunchctl start com.datadoghq.agent or through the systray app
Sourcesudo service datadog-agent start
WindowsSee the Windows Agent documentation.

Stop the Agent

List of commands to stop the Datadog Agent:

PlatformCommand
AIXstopsrc -s datadog-agent
LinuxSee the Agent documentation for your OS.
Dockerdocker exec -it <CONTAINER_NAME> agent stop
Kuberneteskubectl delete pod <AGENT POD NAME>—note: the pod is automatically rescheduled
macOSlaunchctl stop com.datadoghq.agent or through the systray app
Sourcesudo service datadog-agent stop
WindowsSee the Windows Agent documentation.

Restart the Agent

List of commands to restart the Datadog Agent:

PlatformCommand
LinuxSee the Agent documentation for your OS.
DockerUse the installation command.
Kuberneteskubectl delete pod <AGENT POD NAME>—note: the pod is automatically rescheduled
macOSStop and then start the Agent with:
launchctl stop com.datadoghq.agent
launchctl start com.datadoghq.agent
Or use the systray app
Sourceunsupported Platform
WindowsSee the Windows Agent documentation.

Agent status and information

Service status

List of commands to display the status of the Datadog Agent:

PlatformCommand
AIXlssrc -s datadog-agent
LinuxSee the Agent documentation for your OS.
Docker (Debian)sudo docker exec -it <CONTAINER_NAME> s6-svstat /var/run/s6/services/agent/
Kuberneteskubectl exec -it <POD_NAME> -- s6-svstat /var/run/s6/services/agent/
macOSlaunchctl list com.datadoghq.agent or through the systray app
Sourcesudo service datadog-agent status
WindowsSee the Windows Agent documentation.
Cluster Agent (Kubernetes)datadog-cluster-agent status

Agent information

List of commands to display the status of your Datadog Agent and enabled integrations.

PlatformCommand
AIXdatadog-agent status
Linuxsudo datadog-agent status
Dockersudo docker exec -it <CONTAINER_NAME> agent status
Kuberneteskubectl exec -it <POD_NAME> -- agent status
macOSdatadog-agent status or through the web GUI
Sourcesudo datadog-agent status
WindowsSee the Windows Agent documentation.
Cluster Agent (Kubernetes)datadog-cluster-agent status

A properly configured integration is displayed under Running Checks with no warnings or errors, as seen below:

Running Checks
==============
  network (1.6.0)
  ---------------
    Total Runs: 5
    Metric Samples: 26, Total: 130
    Events: 0, Total: 0
    Service Checks: 0, Total: 0
    Average Execution Time : 0ms

Other commands

The Agent command-line interface is sub-command based. To see the list of available sub-commands, run:

<AGENT_BINARY> --help

To run a sub-command, the Agent binary must be invoked:

<AGENT_BINARY> <SUB_COMMAND> <OPTIONS>

Some options have flags and options detailed under --help. For example, use help with the check sub-command:

<AGENT_BINARY> check --help
SubcommandNotes
checkRun the specified check.
configRuntime configuration management.
configcheckPrint all configurations loaded & resolved of a running Agent.
diagnoseExecute connectivity diagnosis on your system.
flareCollect a flare and send it to Datadog.
healthPrint the current Agent health.
helpHelp about any command.
hostnamePrint the hostname used by the Agent.
importImport and convert configuration files from previous versions of the Agent.
jmxJMX troubleshooting.
launch-guiStart the Datadog Agent GUI.
restart-serviceRestart the Agent within the service control manager. Windows only.
start-serviceStart the Agent within the service control manager. Windows only.
stream-logsStream the logs being processed by a running agent.
stopserviceStop the Agent within the service control manager. Windows only.
versionPrint version info.

Further Reading

お役に立つドキュメント、リンクや記事: