Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #53555

Re: How to execute command on remote windows machine

From alex23 <wuwei23@gmail.com>
Newsgroups comp.lang.python
Subject Re: How to execute command on remote windows machine
Date 2013-09-03 15:33 +1000
Organization A noiseless patient Spider
Message-ID <l03sav$ufd$1@dont-email.me> (permalink)
References <33a44ace-33d1-493f-85cb-4f0a093368af@googlegroups.com>

Show all headers | View raw


On 3/09/2013 2:45 PM, gaurangnshah@gmail.com wrote:
> I have a requirement where i need to kill one process on remote windows machine.
> Following command just works fine if i have to kill process on local machine
>
> os.system('taskkill /f /im processName.exe')
>
> However I am not able to figure out how to execute this command on remote windows machine.

The simplest way is from your local machine. taskkill accepts a /s 
parameter which can specify a remote machine by IP or name.

http://technet.microsoft.com/en-us/library/bb491009.aspx

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

How to execute command on remote windows machine gaurangnshah@gmail.com - 2013-09-02 21:45 -0700
  Re: How to execute command on remote windows machine Steven D'Aprano <steve@pearwood.info> - 2013-09-03 05:19 +0000
  Re: How to execute command on remote windows machine alex23 <wuwei23@gmail.com> - 2013-09-03 15:33 +1000
    Re: How to execute command on remote windows machine gaurangnshah@gmail.com - 2013-09-02 23:45 -0700
      Re: How to execute command on remote windows machine Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-09-03 22:54 -0400
  Re: How to execute command on remote windows machine random832@fastmail.us - 2013-09-03 08:39 -0400
  Re: How to execute command on remote windows machine 88888 Dihedral <dihedral88888@gmail.com> - 2013-09-03 07:21 -0700

csiph-web