Monitoring and collecting metrics play a very important role in keeping the system healthy and up and running. Consul can be monitored using the consul monitor command. Let's take a look:
- Run the consul monitor command:
$ consul monitor
2019/08/27 02:24:12 [INFO] agent: Synced service "counting-counting-sidecar-proxy"
2019/08/27 02:24:12 [INFO] agent: Synced service "dashboard-dashboard-sidecar-proxy"
2019/08/27 02:25:24 [INFO] agent: Synced service "counting-counting-sidecar-proxy"
2019/08/27 02:25:24 [INFO] agent: Synced service "dashboard-dashboard-sidecar-proxy"
2019/08/27 02:26:29 [INFO] agent: Synced service "counting-counting-sidecar-proxy"
2019/08/27 02:26:29 [INFO] agent: Synced service "dashboard-dashboard-sidecar-proxy"
- Press Ctrl + C to exit from the preceding consul monitor command...