4

What is the equivalent of docker stop [containerID] using ctr? I can't seem to find it via contianer option or I am missing some ctr concepts...

letthefireflieslive
  • 11,493
  • 11
  • 37
  • 61
  • I am not sure if i'm doing this right, so far I can accomplish this by ```ctr --namespace 'k8s.io' t kill [ID] && ctr --namespace 'k8s.io' c rm [ID]``` – letthefireflieslive Apr 20 '21 at 04:51

1 Answers1

6

check the tasks which are running:

ctr task ls

Then you will see something like that

TASK PID STATUS

v0      62166    RUNNING

Do

ctr task kill v0

or

ctr task kill -s SIGKILL v0
KarimH
  • 61
  • 4
  • 1
    For better readability, please avoid using abbreviations and try to format code and command lines by surrounding them with backquote. – XouDo Jun 07 '21 at 14:05