Managing the Container Disk's Read and Write Resources
The CPU and memory consumed by a running container are usually the biggest culprits for an environment running poorly, but there could also be an issue with your running containers trying to read or write too much to the host's disk drive. This would most likely have less impact than CPU or memory issues, but if there was a large amount of data being transferred to the host system's drives, it could still cause contention and slow your services down.
Fortunately, Docker also provides us with a way to control the amount of reading and writing that our running containers can perform. Just as we've seen previously, we can use a number of options with our docker run
command to limit the amount of data we are either reading or writing to our device disks.
The docker stats
command also allows us to see the data being transferred to and from our running container. It has a dedicated column that can be added to...