VB and VBA Users Source Code: Using a batch file to restart IIS
[
Home
|
Contents
|
Search
|
Reply
| Previous | Next ]
VB/VBA Source Code
Using a batch file to restart IIS
By:
Andrew Baker
Email (spam proof):
Email the originator of this post
Date:
Thursday, May 13, 2004
Hits:
1263
Category:
Internet/Remote Comms
Article:
It is useful to have a scheduled job which runs once a week to bring down IIS. To do this using a batch file, save the following to a file called "C:\IISRestart.bat" @echo off REM * Restart's Web, FTP and SMTP services REM * by Andrew Baker echo Restarting IIS... net stop "World Wide Web Publishing Service" net start "World Wide Web Publishing Service" echo Restarting IIS Admin... net stop "IIS Admin" net start "IIS Admin" echo Restarting FTP... net stop "FTP Publishing Service" net start "FTP Publishing Service" echo Restarting SMTP... net stop "Simple Mail Transport Protocol (SMTP)" net start "Simple Mail Transport Protocol (SMTP)" echo IIS Restart Finished!
Terms and Conditions
Support this site
Download a trial version of the Excel Workbook Rebuilder