-
Open /etc/datadog-agent/datadog.yaml in your editor of choice
-
Set
log_enabled: true
-
Save and close /etc/datadog-agent/datadog.yaml
The dd-agent user will need permissions to read the log files specified in the integrations. Please see this doc for detailed information.
Full instructions on enabling the Apache integration can be found here:
https://docs.datadoghq.com/integrations/apache/
Note that you will need to install mod_status on your Apache servers and enable ExtendedStatus.
-
sudo cp /etc/datadog-agent/conf.d/apache.d/conf.yaml.example /etc/datadog-agent/conf.d/apache.d/conf.yaml
-
Open /etc/datadog-agent/conf.d/apache.d/conf.yaml in your editor of choice
-
Configure the integration to point to your server_status url. Example:
init_config:
instances:
- apache_status_url: http://example.com/server-status?auto
- Configure the logs section with the path to your Apache log files:
logs:
- type: file
path: /data/apps/www/logs/*.log
source: apache
sourcecategory: http_web_access
service: apache
- Save and close /etc/datadog-agent/conf.d/apache.d/conf.yaml
The dd-agent user will need permissions to read the log files specified in the integrations. Please see this doc for detailed information.
-
sudo mkdir /etc/datadog-agent/conf.d/AEM.d
-
sudo touch /etc/datadog-agent/conf.d/AEM.d/conf.yaml
-
Open /etc/datadog-agent/conf.d/AEM.d/conf.yaml in your editor of choice
-
Paste the following (modify to set the service/source/category/tags to meet your needs):
init_config:
instances:
##Log section
logs:
- type: file
path: /data/apps/aem/author/crx-quickstart/logs/*.log
service: AEM
source: AEM
sourcecategory: CMS
tags: env:stage
- type: file
path: /data/apps/aem/publish/crx-quickstart/logs/*.log
service: AEM
source: AEM
sourcecategory: CMS
tags: env:stage
- Save and close /etc/datadog-agent/conf.d/AEM.d/conf.yaml
-
sudo systemctl restart datadog-agent
-
sudo datadog-agent status
Example output:
==========
Logs-agent
==========
cassandra
---------
Type: file
Status: OK
Type: file
Status: OK
nginx
-----
Type: file
Status: OK
Type: file
Status: OK
If there are errors you can find details in /var/log/datadog/agent.log:
tail -f /var/logs/datadog/agent.log | grep logs-agent
Within 5 minutes logs should appear at: https://app.datadoghq.com/logs