Check if Email address exists in Office 365 and if exists, Create a Unique Email address Check if event log source exists for non admins Check if file created today and not 0 KB Check if HyperThreading is enabled Check if IIS running on a remote server check if object is $null Check ...
NAME New-Module SYNOPSIS Creates a new dynamic module that exists only in memory. SYNTAX New-Module [-Name] <System.String> [-ScriptBlock] <System.Management.Automation.ScriptBlock> [-ArgumentList <System.Object[]>] [-AsCustomObject] [-Cmdlet <System.String[]>] [-Function <System.String[...
New-AzKeyVault -VaultName $akvName -ResourceGroupName $resourceGroup -Location $azureLocation # Creates a new key vault - skip if your vault already exists. Set-AzKeyVaultAccessPolicy -VaultName $akvName -ResourceGroupName $resourceGroup -PermissionsToKeys get...
"Transparent Data Encryption (TDE) protects data 'at rest', meaning the data and log files are encrypted when stored on disk.","queryCheck":{"query":"SELE CT CASE\n WHEN EXISTS (\n SELECT *\n FROM sys.databases\n WHERE db_name(database_id) = db_name()\n AND is_encrypted = ...
Server Agent Status'|Out-String $colorTagTable.Keys | foreach { $frag2 = $frag2 -replace ">$_<",($colorTagTable.$_) } write-host $frag2 ##*** ##Database states ##*** $SQLServerDatabaseState = " IF EXISTS (SELECT * FROM tempdb.dbo.sysobjects WHERE ID = OBJECT_ID(N'tempdb....
Before we decide to create a profile, let’s check to see whether we already have one: Test-Path $profile If the profile exists this command will return True; if it doesn’t exist, the command will return False. If this command returns False, you need to create the profile. ...
Ideally, the noun used in cmdlet naming should be very specific; if you've got a generic term, you should use that term as a suffix to your cmdlet. For example, if you create a get-server cmdlet for your SQL database, you should use "New-SQLDatabase" rather than "New-Database"....
In this example, we assume that a blocking firewall rule exists. This example permits any network traffic on any port from any IP address to override the block rule, if the traffic is authenticated as originating from a computer or user account that is a member of the specified computer or...
at System.Management.Automation.Utils.NativeDirectoryExists(String path) at System.Management.Automation.SessionStateInternal.IsItemContainer(CmdletProvider provider Instance, String path, CmdletProviderContext context) TargetObject : CategoryInfo : NotSpecified: (:) [Get-ChildItem], UnauthorizedAccessException...
With this change, PowerShell analyzes the pipeline and determines if the command is safe to run or the command exists on the target system and is able to execute the entire pipeline remotely and only serialize and de-serialize the results back to the client. ...