0x2d@lemmy.ml to 196@lemmy.blahaj.zone · 10 months agorulelemmy.mlimagemessage-square43fedilinkarrow-up1267arrow-down10
arrow-up1267arrow-down1imagerulelemmy.ml0x2d@lemmy.ml to 196@lemmy.blahaj.zone · 10 months agomessage-square43fedilink
minus-squareI_like_cats@lemmy.onelinkfedilinkarrow-up28·10 months agoIt’s easy. Just open up a terminal and type kill $PID (Replace the $PID with the process id of the process) if you don’t know the process id you can do killall process_name If these don’t work you can add a -9 to banish them and give them no chance to resist
minus-squareSoonaPaana@lemmy.worldlinkfedilinkarrow-up5·10 months agoAlso please refresh my memory on how to find the process ID
minus-squareI_like_cats@lemmy.onelinkfedilinkarrow-up11·10 months agoYou can do ps aux | grep -i <part of process name> and the PID is in the second column of the output. However for this use case I recommend a process manager like htop or btop
minus-squareassaultpotato@sh.itjust.workslinkfedilinkarrow-up5·10 months agoI use ps -aux | grep $EXECUTABLE
minus-squareRefurbished Refurbisher@lemmy.sdf.orglinkfedilinkarrow-up2·10 months agohtop or any process monitor will tell you.
minus-squareKrzd@lemmy.worldlinkfedilinkarrow-up1·10 months agotop for Ubuntu at least will show you the top processes, I think sorted by averaged CPU usage.
minus-squareunalivejoy@lemm.eelinkfedilinkEnglisharrow-up5·10 months agoSimilarly, $$ is the current PID, $PPID is the parent PID. (Bash)
minus-squareHappyFrog@lemmy.blahaj.zonelinkfedilinkarrow-up3·10 months agoSo ‘kill -9 $$’ is just suicide?
minus-squareunalivejoy@lemm.eelinkfedilinkEnglisharrow-up5·10 months agoWith suicide, you have a chance to get your affairs in order. kill -9 $$ is hiring an assassin to kill you and not tell you when it will happen. It happens suddenly without warning.
minus-squareAnUnusualRelic@lemmy.worldlinkfedilinkarrow-up4·10 months agoYou probably want to get on the habit of using pkill instead of killall in case you’re ever on a different system. You could have a surprise.
It’s easy. Just open up a terminal and type
kill $PID
(Replace the $PID with the process id of the process) if you don’t know the process id you can do
If these don’t work you can add a
-9
to banish them and give them no chance to resistAlso please refresh my memory on how to find the process ID
You can do
ps aux | grep -i <part of process name>
and the PID is in the second column of the output. However for this use case I recommend a process manager like htop or btop
I use
ps -aux | grep $EXECUTABLE
htop or any process monitor will tell you.
top for Ubuntu at least will show you the top processes, I think sorted by averaged CPU usage.
Similarly,
$$
is the current PID,$PPID
is the parent PID. (Bash)So ‘kill -9 $$’ is just suicide?
With suicide, you have a chance to get your affairs in order.
kill -9 $$
is hiring an assassin to kill you and not tell you when it will happen. It happens suddenly without warning.You can type
seppuku
for thatYou probably want to get on the habit of using pkill instead of killall in case you’re ever on a different system. You could have a surprise.