CMD tasklist and Tskill manage Windows system processes _dos/bat

Source: Internet
Author: User
Command: Tasklist

Function: commands are used to display all processes running on a local or remote computer and can monitor the user's actions.

Command format:

Tasklist [/S system [/u username [/p [password]]]] [/M [module] |/svc |/v] [/fi filter] [/fo format] [/NH]

Parameter meaning

/S system Specifies the remote system to which to connect.

/u [domain\]user specifies which user to use to execute this command.

/p [Password] specifies a password for the specified user.

/M [module] lists all processes that invoke the specified DLL module. If you do not specify a module name, all modules loaded by each process are displayed.

/SVC displays the services in each process.

/V displays detailed information.

Example Analysis:

If we just view the local host process information, we can simply run the command. The following example is a remote view of a host's time history information from a client computer.

If we have a server:

Intranet Address: 192.168.0.1,

Admin Account: Administrator

Admin Password: password

We need to enter in the cmd window:

tasklist/s 192.168.0.1/u administrator/p Password

This command allows us to easily view the operation of the remote host, assuming that the RPC service starts properly.


Command: Tskill

Function: To turn off the process

Command format:

TSKILL ProcessID | ProcessName [/server:servername] [/id:sessionid |/a] [v]

Parameter meaning

ProcessID the process ID of the processes to end.

ProcessName the name of the process to end.

/server:servername contains ProcessID servers (the default is the current value).

When using the process name and/server, you must specify

/ID or/A

/id:sessionid ends the process running under the specified session.

/A ends the process running under all sessions.

/V Displays information about the operation being performed.

This tskill usage is very simple, the direct input tskill image name or PID is OK.

Occasionally encountered Tskill can not end the process, but also try NTSD command,

Format is: ntsd-c Q-PN {process name}

Parameter meaning:

-C means to execute the debug command;

Q indicates exit after execution is completed;

-P means the PID that follows the process that you want to end;

-PN said the following is the name of the process you want to end;
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.