September 02, 2016

The method of killing all processes of the current shell

□ ps -f | grep [using account] | awk '{print $2}' | xargs kill -9

○ ps -f : It minutely prints the running processes(or ps -ef).
○ grep [using account] : It selects the software that login-user executed
○ | awk '{print $2}' : It prints the second column of the result of ps(=pid)
○ | xargs kill -9: It compulsorily kills the processes of the result of the output(=pid)

Test environment
O  S Ubuntu 15.10 (64bit) CPU Intel i7-4710MQ 2.50GHz
RAM 984MiB GPU Gallium 0.4 on SVGA3D
(Intel(R) HD Graphics 4600)