Home > Operation and Maintenance > Docker > How to view docker container logs in real time

How to view docker container logs in real time

王林
Release: 2020-09-15 17:52:13
forward
3205 people have browsed it

How to view docker container logs in real time

View docker container logs in real time

(Recommended tutorial: docker tutorial)

$ sudo docker logs -f -t --tail 行数 容器名
Copy after login

Example: View docker container name in real time Log for the last 10 lines of s12

$ sudo docker logs -f -t --tail 10 s12
Copy after login

The above is the detailed content of How to view docker container logs in real time. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:csdn.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template