Print IP address when monitor or unmonitor fails.

(cherry picked from commit e1484039961fcfcb026bdf2a785ac38635c315bf)