Troubleshooting tips for monitoring Go applications in Docker
If you encounter issues with Go application monitoring in Docker, follow these troubleshooting steps to identify and resolve common problems quickly.
The container fails to start
- Symptom: The APM container terminates immediately after starting.
- Common causes:
- S247_LICENSE_KEY is missing.
- The GO_APPS (Go application) format is invalid.
- privileged: true or pid: host is missing.
- Solution:
- Check the container logs by running the following command:
docker logs site24x7-apm-agent
- Verify the environment variables by running the following command:
docker exec site24x7-apm-agent env | grep -E "S247 | GO_APPS"
The application was not discovered
- Symptom: The APM agent logs show a No applications discovered message.
- Common causes:
- There's a process name mismatch in GO_APPS.
- There's a port mismatch in GO_APPS.
- The shared volume is not mounted correctly.
- Solution: You can use the following commands to check if the application binary is accessible, verify the process name and ports, and review the agent discovery logs:
# Check if the application binary is accessible
docker exec site24x7-apm-agent ls -la /app_runtime/
# Verify the process name and ports
docker exec your-app-container ps aux | grep go
docker exec your-app-container netstat -tulpn
# Check agent discovery logs
docker exec site24x7-apm-agent tail -50 /opt/site24x7/apm-insight-go-agent/logs/agent.txt
eBPF monitoring fails
- Symptom: The application was discovered, but monitoring has not started.
- Common causes:
- Your Linux system is running a kernel older than version 5.8.
- Extended Berkeley Packet Filter (eBPF) capabilities are missing.
- A stripped binary without symbols is an executable file from which all debugging and symbol information has been removed.
- Solution: You can use the following commands to check your kernel version, verify eBPF support, and review the instrumentor logs for any issues:
# Check the kernel version
uname -r
# Verify eBPF support
docker exec site24x7-apm-agent cat /proc/sys/kernel/bpf_stats_enabled
# Check instrumentor logs
docker exec site24x7-apm-agent ls /opt/site24x7/apm-insight-go-agent/instrumentor/logs/
docker exec site24x7-apm-agent tail -100 /opt/site24x7/apm-insight-go agent/instrumentor/ logs/*/ agent.txt
There is no data on the Site24x7 dashboard
- Symptom: Monitoring is successful, but the application metrics are not visible.
- Common causes:
- The license key is invalid.
- There are network connectivity issues.
- S247DataExporter is not running.
- Solution: The following steps help ensure that the APM agent is running correctly by checking the exporter process, reviewing logs, and testing the connectivity to Site24x7.
# Check the exporter process
docker exec site24x7-apm-agent pgrep -f S247DataExporter
# Check exporter logs
docker exec site24x7-apm-agent tail -100 /opt/S247DataExporter/logs/service/service.log
# Test the connectivity to Site24x7
docker exec site24x7-apm-agent curl -I https://apminsight.site24x7.com
Related articles
- Go agent installation
- Go agent compatibility