nerdctl icon indicating copy to clipboard operation
nerdctl copied to clipboard

-a for stats command is not working when there is an exited container

Open azhouwd opened this issue 1 year ago • 0 comments

Description

When using stats command with -a, no output is generated and the terminal stuck there forever.

~/Desktop ✓ ➭ ./_output/lima/bin/limactl shell default
[user@lima-default default]$
[user@lima-default default]$ nerdctl ps -a
CONTAINER ID    IMAGE                              COMMAND                CREATED         STATUS                     PORTS    NAMES
371ecb033c10    docker.io/library/alpine:latest    "sh -c nc -l -p 80"    34 hours ago    Up                                  alpine-371ec
a091b2be8eb0    docker.io/library/alpine:latest    "/bin/sh"              34 hours ago    Exited (0) 34 hours ago             alpine-a091b

[user@lima-default default]$ nerdctl stats -a

Steps to reproduce the issue

  1. create and shell into lima instance (Fedora).
  2. run nerdctl stats -a.
  3. The terminal stuck there and doesn't generate any output.

Describe the results you received and expected

Received: no output is generated and terminal stuck forever.

Expected: Able to see the usage statistics for all the containers.

What version of nerdctl are you using?

[user@lima-default default]$ nerdctl -v
nerdctl version 0.22.0

Are you using a variant of nerdctl? (e.g., Rancher Desktop)

No response

Host information

~/Desktop ✓ ➭ uname -a
Darwin 21.4.0 Darwin Kernel Version 21.4.0: Fri Mar 18 00:46:32 PDT 2022; root:xnu-8020.101.4~15/RELEASE_ARM64_T6000 arm64

azhouwd avatar Oct 05 '22 17:10 azhouwd