ETIMEDOUT, ECONNREFUSED, EHOSTUNREACH: Three Diagnoses

Three socket errors that read as 'the network is broken' are in fact three different answers to three different questions.

ETIMEDOUT, ECONNREFUSED and EHOSTUNREACH Are Three Different Diagnoses. Abstract error autopsy illustration in orange and dark grey on debugly.dev
Error Packet reached peer? Something answered? Where to look
ECONNREFUSED Yes Yes, with RST Listener, port, service down
ETIMEDOUT Maybe No Firewall drop, host down, path
EHOSTUNREACH No ICMP no route Routing, wrong address, VPC peering

Published on debugly.dev by Rohit Bhadani | Founder of Krova Cloud