better error message for nginx communication