我在一所学校工作,单位使用Active Directory来管理基础结构。
@ECHO OFF REM =================================== REM Name:shutdownNetWorkComputers.bat REM Author:PopZslam REM Description:Shutdown Computers REM Date:03/25/2009 REM Version:0.0.1 REM ===================================
set tmpFile=klsdfi3k3dklsfj83565%random%
net view|find /v /i "server"|find /i "\\" > %tmpFile%
for /f %%f in ('type %tmpFile%') do ( shutdown /s /f /t 600 /m %%f /c "网络管理员提醒您,根据策略,计算机将于10分钟后关闭,请保存您的工作。" )
del %tmpFile% @ECHO ON
|
阅读(614) | 评论(0) | 转发(0) |