This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Configure win32_event_log | |
echo "init_config: | |
instances: | |
- type: | |
- Information | |
- Critical | |
- Error | |
- Warning | |
- Audit Failure | |
- Audit Success |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Prompt for the Datadog API key | |
read -p "Enter your Datadog API key: " DD_API_KEY | |
# Validate the API key is not empty | |
if [[ -z "$DD_API_KEY" ]]; then | |
echo "Error: Please enter a valid Datadog API key." | |
exit 1 | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
######################################## | |
## Datadog Configuration ## | |
######################################## | |
api_key: <your_api_key> | |
site: datadoghq.com | |
######################################## | |
## Tag collection Configuration ## | |
######################################## | |
# ec2 instances will inherit AWS Tags |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download and install the Datadog agent | |
Set-ExecutionPolicy Bypass -Scope Process -Force; | |
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; | |
$env:DD_API_KEY = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'; | |
$env:DD_SITE = 'datadoghq.com'; | |
$env:DD_REMOTE_UPDATES = 'true'; | |
#$env:DD_AGENT_MAJOR_VERSION = '7'; | |
#$env:DD_AGENT_MINOR_VERSION = '59.0'; | |
iex ((New-Object System.Net.WebClient).DownloadString('https://s3.amazonaws.com/dd-agent-mstesting/Install-Datadog.ps1')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
listeners: | |
- name: snmp | |
snmp_listener: | |
workers: 2 | |
discovery_interval: 3600 | |
discovery_allowed_failures: 3 | |
loader: core | |
min_collection_interval: 15 | |
use_device_id_as_hostname: true | |
configs: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Install the Datadog Agent with the single line install (replace the API key with your API key) | |
2) Configure the Datadog Agent Configuration file at: /etc/datadog/datadog-agent.yaml (replace the API key with your API key) | |
# api key - https://app.datadoghq.com/organization-settings/api-keys | |
api_key: <api_key> | |
# datadog site | |
site: datadoghq.com | |
# logs |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download agent | |
(Invoke-WebRequest https://s3.amazonaws.com/ddagent-windows-stable/datadog-agent-7-latest.amd64.msi -OutFile c:\datadog-agent-7-latest.amd64.msi) | |
# Start the Datadog agent | |
# (Start-Process -Wait msiexec -ArgumentList '/qn /i c:\datadog-agent-7-latest.amd64.msi APIKEY=xxx HOSTNAME="my_hostname" TAGS="mytag1,mytag2"') | |
(Start-Process -Wait msiexec -ArgumentList '/qn /i c:\datadog-agent-7-latest.amd64.msi APIKEY="api_key"') | |
# Enable logs, live process, and agent configuration through the datadog UI | |
(Add-Content C:\ProgramData\Datadog\datadog.yaml "logs_enabled: true`nlogs_config:`n use_compression: true`n compression_level: 6`n batch_wait: 5`n open_files_limit: 500") | |
(Add-Content C:\ProgramData\Datadog\datadog.yaml "`nprocess_config:`n process_collection:`n enabled: `"true`"") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://docs.datadoghq.com/integrations/win32_event_log/?tab=logs#overview | |
init_config: | |
logs: | |
- type: windows_event | |
channel_path: "Application" | |
source: windows.events | |
service: Application_Event | |
- type: windows_event |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# api key - https://app.datadoghq.com/organization-settings/api-keys | |
api_key: <api_key> | |
# datadog site - https://docs.datadoghq.com/getting_started/site/ | |
site: datadoghq.com | |
# logs - needed for windows events - https://docs.datadoghq.com/integrations/win32_event_log | |
logs_enabled: true | |
logs_config: | |
use_compression: true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download agent | |
(Invoke-WebRequest https://s3.amazonaws.com/ddagent-windows-stable/datadog-agent-7-latest.amd64.msi -OutFile c:\datadog-agent-7-latest.amd64.msi) | |
# Download .NET Tracer v2.42x64 .msi | |
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 | |
(Invoke-WebRequest https://github.com/DataDog/dd-trace-dotnet/releases/download/v2.42.0/datadog-dotnet-apm-2.42.0-x64.msi -OutFile c:\datadog-dotnet-apm-2.42.0-x64.msi) | |
# Start the Datadog agent | |
(Start-Process -Wait msiexec -ArgumentList '/qn /i c:\datadog-agent-7-latest.amd64.msi APIKEY=xxx HOSTNAME="my_hostname" TAGS="mytag1,mytag2"') |