PSEXEC可以做你想做
http://technet.microsoft.com/en-us/sysinternals/bb897553
usage: psexec \\computer [-u username [-p password]] [-s] [-c [-f]] [-d] program [arguments]
-u Specifies optional user name for login to remote computer.
-p Specifies optional password for user name. If you omit this you will be prompted to enter a hidden password.
-s Run remote process in the System account .
-c Copy the specified program to the remote system for execution. If you omit this option then the application must be in the system's path on the remote system.
-f Copy the specified program to the remote system even if the file already exists on the remote system.
-d Don't wait for application to terminate. Only use this option for non-interactive applications.
Examples
The following command launches an interactive command prompt on \\marklap:
psexec \\marklap cmd
This command executes IpConfig on the remote system with the /all switch, and displays the resulting output locally:
psexec \\marklap ipconfig /all
This command copies the program test.exe to the remote system and executes it interactively:
psexec \\marklap -c test.exe
Specify the full path to a program that is already installed on a remote system if its not on the system's path:
psexec \\marklap c:\bin\test.exe
src: http://www.governmentsecurity.org/forum/index.php?showtopic=1030
我在Linux所以我現在不能對此進行測試的。
for /l %%c in (1,1,254) do start psexec \\192.168.1.%%c -d -u administrator -p pass "net use Z: \\yourserver\user$ && Z:\update.exe && net use Z: /delete"
非常好的信息。我不確定那是我在找什麼。我可以肯定地將它用於onesies和twosies,但70多臺機器會讓我的系統停滯不前,並使修補過程非常漫長。我想到的基本上是在遠程機器上執行一個腳本,指向他們從共享服務器(而不是我的盒子)安裝補丁。這樣我所要做的就是執行腳本並讓它運行。 基本上,我是A點,我希望B點在C點執行該文件。我該怎麼做? – Morgan
我添加了一個可能有幫助的班輪 –