Created
October 28, 2011 21:11
-
-
Save keithbloom/1323578 to your computer and use it in GitHub Desktop.
3ReasonsForUsingPowershell
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set-location \\\\servername\sharename |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
remove-item c:\temp\**\*.bak |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(Get-WmiObject -computer servername Win32_service -Filter "Name='W3SVC'").StartService() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-WmiObject -namespace "root/MicrosoftIISV2" -ComputerName "Server" -Credential "yourname" -Authentication PacketPrivacy -Query "SELECT * FROM IIsWebServerSetting" | select { $_.ServerComment, $_.LogFileDirectory } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment