Skip to main content

MIKRO004 - MikroTik Connection Timed Out

Agent error code #MIKRO004 indicates that the network connection to the MikroTik REST API did not complete within the agent's timeout window.

Common causes include:

  • The router is reachable but overloaded or its CPU is saturated
  • A firewall between the agent and the router is silently dropping packets (no RST, just no response)
  • The agent is connecting through a slow VPN or WAN link
  • The agent dialled the wrong IP and the request is being black-holed

Steps to Resolve

Test the Network Path

  1. From the host running the Knocknoc agent, run: time curl -ku '<user>:<pass>' https://<router-host>/rest/system/resource
  2. If curl also takes 10+ seconds to respond or hangs, the path is slow rather than the router being slow
  3. Run mtr <router-host> or traceroute <router-host> and look for the hop where latency spikes or packets are lost

Confirm the Router is Healthy

  1. In RouterOS, open the System > Resources dashboard
  2. Check CPU and memory. Sustained 100% CPU explains REST timeouts
  3. Look at Tools > Logs for connection errors around the time of the timeout

Adjust Firewall Rules

  1. Confirm no upstream firewall is rate-limiting or dropping connections from the agent host
  2. If you have GeoIP or threat-intel blocking, allowlist the agent's egress IP

Still Having Issues?

We can help you out, contact us at support@knocknoc.io.