R
RunPod3w ago
Yasmin

Terminate POD with SSH

Hello! I use the following command to stop and then terminate the pod using ssh. It stops, but it is just marked as "Exited" in the interface; so it seems that the second command does not work. ` nohup bash -c "sleep 1h; runpodctl stop pod $RUNPOD_POD_ID && runpodctl remove pod $RUNPOD_POD_ID" & I would like to fully terminate it from ssh, so that it does not incur charges while I do not need the POD anymore as the task is already finished. So, how can adjust the command to fully terminate the POD? Thanks!
6 Replies
Madiator2011 (Work)
Its cause your command stops first so it wont let you remove it
Yasmin
Yasmin3w ago
So, should I remove the stop command?
digigoblin
digigoblin3w ago
Pod probably gets stopped before the remove command gets a chance to be executed, I think you should just be able to remove it without stopping it.
nerdylive
nerdylive3w ago
Yes
digigoblin
digigoblin3w ago
Oh sorry my messages didnt update, only saw Madiator's message now for some reason, but yeah, don't stop just terminate/remove it.
Yasmin
Yasmin3w ago
Thanks to all of you! @Madiator2011 (Work) @nerdylive @digigoblin