On a Linux machine:
1. Make note of the name of the machine you are on.
2. Log into another machine
3. ssh into the machine that is frozen
pkill -9 -u your_username
5. This should log you out and kill all the processes.
The frozen terminal should return to a login screen.
If all else fails,
Contact the Math Help Desk
If it is a Windows machine:
1. Hit CTRL-ALT-DEL
Choose Shutdown, then choose Restart.