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
function Get-CertificateExpiration { | |
<# | |
.SYNOPSIS | |
Displays a list of certificates that will expire soon. | |
#> | |
param( | |
$Threshold = 30, #Number of days to look for expiring certificates | |
[string[]]$ComputerName |
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
Function ProcessMonitor { | |
<# | |
.SYNOPSIS | |
Displays changes in the process list on this or a remote PC. | |
.DESCRIPTION | |
Great for monitoring logon/startup scripts, batch jobs, software installations, etc... Especially on terminal servers. | |
.EXAMPLE | |
ProcessMonitor | |
Compares changes in the process list every second on the local computer. | |
.EXAMPLE |
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
Function MultiPing { | |
<# | |
.SYNOPSIS | |
Sends a ping to a specified host. Colors the output to indicate latency. | |
.DESCRIPTION | |
Version 1.1. Provides a simple network monitoring solution, without the need to install any software. | |
.EXAMPLE | |
MultiPing ServerX | |
Sends a ping to ServerX every second. Repeats forever. | |
.EXAMPLE |
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-Content pcs.txt | foreach { Write-Host $_ -f Green; $pc=$_; Get-Content wmi.txt | foreach { Get-WmiObject $_ -ComputerName $pc } } |
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
function Get-MessageOfTheDay { | |
<# | |
.SYNOPSIS | |
Displays a message of the dag. | |
#> | |
$msg = | |
'Knowledge is power -- Sir Francis Bacon', | |
'Power is the ultimate aphrodisiac -- Henry Alfred Kissinger', | |
'With great power comes great responsibility -- Uncle Ben', |
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
function Get-VMMNetworkControllerInstallationStatus { | |
<# | |
.SYNOPSIS | |
This function summarizes several important configuration settings during deployment of a Network Controller VM from System Center Virtual Machine Manager (VMM). | |
.NOTES | |
Info from Network Controller deployment scripts | |
PrepareNodeForNetworkController.ps1 configures: | |
Installation directory |
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
$BpaModel = 'Microsoft/Windows/WebServer' | |
$BaselineFile = 'baseline.xml' | |
Import-Module BestPractices | |
Invoke-BpaModel $BpaModel | |
Get-BpaResult $BpaModel | Export-CliXML $BaselineFile |
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
$BpaModel = 'Microsoft/Windows/WebServer' | |
$BaselineFile = 'baseline.xml' | |
Import-Module BestPractices | |
Invoke-BpaModel $BpaModel | |
$Bpa = Get-BpaResult $BpaModel | |
$BpaBaseline = Import-CliXML $BaselineFile | |
Compare-Object $BpaBaseline $Bpa -property Severity, Title, Resolution | | |
Where-Object SideIndicator -eq '=>' |
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
function Verb-Noun { | |
<# | |
.SYNOPSIS | |
Short description | |
.DESCRIPTION | |
Long description | |
.EXAMPLE | |
Verb-Noun | |
Example of how to use this cmdlet |
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
function Verb-Noun { | |
<# | |
.SYNOPSIS | |
Short description | |
.DESCRIPTION | |
Long description | |
.EXAMPLE | |
Verb-Noun | |
Example of how to use this cmdlet |