What are the ways I can regain control over my computer when I have terminal in full screen mode and type:
cat /dev/random
Ask Different is a question and answer site for power users of Apple hardware and software. It only takes a minute to sign up.
Sign up to join this communityIf you have Terminal.app open anyway (doesn't matter whether it's in fullscreen mode or not):
ps aux | fgrep /dev/random
to find the running cat
(you can grep for cat
as well but there might be more than one matching line)kill <PID from above>
(or kill -9 <PID>
)Just be patient, the system may be really slow (even on a multicore system as I've just found out).
man kill
, -9 is the signal to send. By default, kill sends a "soft" termination (letting the application/command handle the termination itself). This may not work if the application is stuck in some loop and never gets to handle the signal. -9 terminates on OS level.
kill -TERM
or kill -INT
(which is the same as ^C
) first; jumping straight to SIGKILL
is often a bad idea.
Nov 22, 2012 at 1:11
Just tested this, type control-c
in terminal, it should stop any running command.
cat /dev/random
?