1podman-pod-logs(1)          General Commands Manual         podman-pod-logs(1)
2
3
4

NAME

6       podman-pod-logs - Displays logs for pod with one or more containers
7
8

SYNOPSIS

10       podman pod logs [options] pod
11
12

DESCRIPTION

14       The  podman  pod logs command batch-retrieves whatever logs are present
15       with all the containers of a pod. Pod logs can be filtered by container
16       name or id using flag -c or --container if needed.
17
18
19       Note:  Long  running  command  of  podman pod log with a -f or --follow
20       needs to be reinvoked if new container is added to the pod  dynamically
21       otherwise  logs  of  newly added containers would not be visible in log
22       stream.
23
24

OPTIONS

26   --color
27       Output the containers with different colors in the log.
28
29
30   --container, -c
31       By default podman pod logs retrieves logs for all the containers avail‐
32       able within the pod differentiate by field container. However there are
33       use-cases where user would want to limit the log stream only to a  par‐
34       ticular  container  of  a pod for such cases -c can be used like podman
35       pod logs -c ctrNameorID podname.
36
37
38   --follow, -f
39       Follow log output.  Default is false.
40
41
42       Note: If you are following a pod which is removed by podman pod  rm  or
43       removed  on exit (podman run --rm ...), then there is a chance that the
44       log file will be removed before podman pod logs reads  the  final  con‐
45       tent.
46
47
48   --latest, -l
49       Instead  of  providing the pod name or id, get logs of the last created
50       pod. (This option is not available with the remote Podman  client,  in‐
51       cluding Mac and Windows (excluding WSL2) machines)
52
53
54   --names, -n
55       Output the container names instead of the container IDs in the log.
56
57
58   --since=TIMESTAMP
59       Show  logs  since TIMESTAMP. The --since option can be Unix timestamps,
60       date formatted timestamps, or Go duration  strings  (e.g.  10m,  1h30m)
61       computed  relative  to the client machine's time. Supported formats for
62       date   formatted   time   stamps    include    RFC3339Nano,    RFC3339,
63       2006-01-02T15:04:05,  2006-01-02T15:04:05.999999999,  2006-01-02Z07:00,
64       and 2006-01-02.
65
66
67   --tail=LINES
68       Output the specified number of LINES at the end  of  the  logs.   LINES
69       must be an integer.  Defaults to -1, which prints all lines
70
71
72   --timestamps, -t
73       Show timestamps in the log outputs.  The default is false
74
75
76   --until=TIMESTAMP
77       Show  logs  until TIMESTAMP. The --until option can be Unix timestamps,
78       date formatted timestamps, or Go duration  strings  (e.g.  10m,  1h30m)
79       computed  relative  to the client machine's time. Supported formats for
80       date   formatted   time   stamps    include    RFC3339Nano,    RFC3339,
81       2006-01-02T15:04:05,  2006-01-02T15:04:05.999999999,  2006-01-02Z07:00,
82       and 2006-01-02.
83
84

EXAMPLE

86       To view a pod's logs:
87
88
89              podman pod logs -t podIdorName
90
91
92
93       To view logs of a specific container on the pod
94
95
96              podman pod logs -c ctrIdOrName podIdOrName
97
98
99
100       To view all pod logs:
101
102
103              podman pod logs -t --since 0 myserver-pod-1
104
105
106
107       To view a pod's logs since a certain time:
108
109
110              podman pod logs -t --since 2017-08-07T10:10:09.055837383-04:00 myserver-pod-1
111
112
113
114       To view a pod's logs generated in the last 10 minutes:
115
116
117              podman pod logs --since 10m myserver-pod-1
118
119
120
121       To view a pod's logs until 30 minutes ago:
122
123
124              podman pod logs --until 30m myserver-pod-1
125
126
127

SEE ALSO

129       podman(1), podman-pod(1), podman-pod-rm(1), podman-logs(1)
130
131
132
133                                                            podman-pod-logs(1)
Impressum