June 2016
Beginner
456 pages
9h 31m
English
In this recipe, we will learn to monitor Docker containers.
Docker provides inbuilt monitoring with the docker stats command, which can be used to get a live stream of the resource utilization of Docker containers.
$ docker stats mysql f9617f4b716c

If you need to monitor all running containers, use the following command:
$ docker stats $(dockerps -q)
docker logs, you can fetch logs of your application running inside a container. This can be used similarly to the tail -f command:
$ docker logs -f ubuntu
Read now
Unlock full access