TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
PowerShell: Perform IISRESET on Multiple Server in One Go
Ketak Bhalsing
Dec 04
2014
Code
11.9
k
0
0
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
expand
A quick script to do an IISRESET on Multiple server.
[array]$servers =
"MyServer1"
,
"MyServer2"
,
"MyServer3"
,
"MyServer4"
foreach ($server
in
$servers)
{
Write-Host
"Restarting IIS on server $server..."
IISRESET $server /noforce
Write-Host
"IIS status for server $server"
IISRESET $server /status
}
Write-Host IIS has been restarted on all servers.
IISRESET
Powershell
SharePoint