Why?
docker ps
- output is not convenient to use. ctop
- is an advanced replacement for this command, which is simple to use and more informative.
Basic concepts, commands, and options:
ctop
- is a free, open-source, cross-platformtop
like command-line tool used for monitoring Docker containers. It is considered as the best replacement fordocker ps
command.- It allows monitoring container metrics in real-time. You can get an overview of metrics concerning the CPU, memory, network, IO for multiple containers. It also supports the inspection of the specific container.
- Official project repository
- To see running and stopped containers run:
ctop
- You can select container by arrow keys and using
Enter
key to show the menu: - To view only active container use
-a
option:ctop -a
- To filter output by container name use
-f
option:ctop -f [container_name]
Advanced usage:
- You can use docker image of
ctop
on remote servers with the following command:docker run --rm -ti \ --name=ctop \ --volume /var/run/docker.sock:/var/run/docker.sock:ro \ quay.io/vektorlab/ctop:latest
NET RX/TX
column in ctop container view shows how much data container sent and received since starting. TX and RX are abbreviations for Transmit and Receive, respectively. Note that these metrics are referenced to the server being monitored; Transmit FROM this server (upload), and Receive TO this server (download). Units are in Bytes (not bits).- Default connector for
ctop
is Docker daemon. Another option is runC