Home Linux (Level: Beginner) - Killing a process in Linux
(Level: Beginner) - Killing a process in Linux PDF Print E-mail
Written by Siva   
Thursday, 06 December 2012 19:56

How to kill a process in in Linux?

Find out the process ID using command ps -ef then use kill command, example below.

 

 

ps -ef|grep -i fdisk


kill -9 22456 23311 27052

 


ps -ef|grep -i fdisk

 

 

[root@vm-siva-it-umo-01 ~]#

[root@vm-siva-it-umo-01 ~]# ps -ef|grep -i java

umoadmin 14849 14835  5 16:55 pts/1    00:01:28 /apps/umoadmin/IBM/WebSphere/AppServer/java/bin/java -Dosgi.install.area=/apps/umoadmin/IBM/WebSphere/AppServer -Dosgi.configuration.area=/apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/configuration -Xbootclasspath/p: -Dcom.ibm.CORBA.ConfigURL=file:/apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/properties/sas.client.props -Dcom.ibm.SSL.ConfigURL=file:/apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/properties/ssl.client.props -Dcom.ibm.SOAP.ConfigURL=file:/apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/properties/soap.client.props -Djava.security.auth.login.config=/apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/properties/wsjaas_client.conf -Dws.ext.dirs=/apps/umoadmin/IBM/WebSphere/AppServer/java/lib:/apps/umoadmin/IBM/WebSphere/AppServer/classes:/apps/umoadmin/IBM/WebSphere/AppServer/lib:/apps/umoadmin/IBM/WebSphere/AppServer/installedChannels:/apps/umoadmin/IBM/WebSphere/AppServer/lib/ext:/apps/umoadmin/IBM/WebSphere/AppServer/web/help:/apps/umoadmin/IBM/WebSphere/AppServer/deploytool/itp/plugins/com.ibm.etools.ejbdeploy/runtime -Dwas.install.root=/apps/umoadmin/IBM/WebSphere/AppServer -Djava.util.logging.manager=com.ibm.ws.bootstrap.WsLogManager -Djava.util.logging.configureByServer=true -classpath /apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/properties:/apps/umoadmin/IBM/WebSphere/AppServer/properties:/apps/umoadmin/IBM/WebSphere/AppServer/lib/startup.jar:/apps/umoadmin/IBM/WebSphere/AppServer/lib/bootstrap.jar:/apps/umoadmin/IBM/WebSphere/AppServer/lib/lmproxy.jar:/apps/umoadmin/IBM/WebSphere/AppServer/lib/urlprotocols.jar:/apps/umoadmin/IBM/WebSphere/AppServer/java/lib/tools.jar -Duser.install.root=/apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01 com.ibm.wsspi.bootstrap.WSPreLauncher -nosplash -application com.ibm.ws.bootstrap.WSLauncher com.ibm.ws.admin.services.WsServerStop /apps/umoadmin/IBM/WebSphere/AppServer/profiles/AppSrv01/config vm-siva-it-umo-01-sNode01Cell vm-siva-it-umo-01-sNode01 server1

root     16178 15937  0 17:19 pts/3    00:00:00 grep -i java

[root@vm-siva-it-umo-01 ~]#

[root@vm-siva-it-umo-01 ~]# ps -ef|grep -i fdisk

root     16223 15937  0 17:21 pts/3    00:00:00 grep -i fdisk

[root@vm-siva-it-umo-01 ~]#

[root@vm-siva-it-umo-01 ~]# kill -9 14849 14835

[root@vm-siva-it-umo-01 ~]# ps -ef|grep -i java

root     16248 15937  0 17:21 pts/3    00:00:00 grep -i java

[root@vm-siva-it-umo-01 ~]#

 

Last Updated on Saturday, 17 February 2018 23:17
 
 

Advertisement

Featured Links:
HREmail.com
Looking for job? Try HREmail.com
Want to have CMS based Websites?
Try siliconwebcreators.com to CMS based websites.
VM Solutions Inc
For best VM solutions..
Digital Procedure Inc.
Looking for Oracle /SAP /Weblogic Consulting services? visit digitalprocedure.com