Question

Firewall prevents do-agent from pushing monitoring data

Posted February 3, 2018 2.8k views
SecurityFirewallMonitoringUbuntu 16.04

I blocked outgoing TCP connections from the web interface (Networking -> Firewall). Only allowed external 3rd party API ip addresses and DNS.

The problem is that do-agent stopped reporting performance metrics. If I allow all IPv4 outgoing connections everything works fine. But I would like to only premit certain IP addresses for security reasons.

Do you know which IP address do I need to whitelist for do-agent to resume working?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
1 answer

The DigitalOcean Monitoring agent requires outbound TCP access on ports 80 and 443 to authenticate to the Monitoring service and to send metrics.

The agent need to be able to access the DigitalOcean metadata API at: http://169.254.169.254/metadata/v1/ as well as the metrics service itself at https://sonar.digitalocean.com. Additionally, in order to allow the agent to update its self https://repos.sonar.digitalocean.com

Unfortunately, the IP addresses behind those domains are not guaranteed to be stable. In particular, the repo for automatic updates is backed by an external CDN.

You can find their current IP addresses using: dig +short sonar.digitalocean.com and dig +short repo.sonar.digitalocean.com on the command line.

Here is a currently working example:

Example firewall

Submit an Answer