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
New-EdgeSubscription -FileName C:\AdminEdge.xml | |
New-EdgeSubscription -FileData ([byte[]]$(Get-Content -Path "C:\AdminEdge.xml" -Encoding Byte -ReadCount 0)) -Site "Default-First-Site-Name" | |
alternative: New-EdgeSubscription -FileData ([byte[]]$(Get-Content -Path "C:\AdminEdge.xml" -Encoding Byte -ReadCount 0)) -Site (Get-ADSite) | |
Get-SendConnector | |
Remove-SendConnector "Internet Email" | |
Start-EdgeSynchronization | |
Next: http://msexchangeguru.com/2017/08/08/exchange-2016-anti-spam-configuration/ |
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-MessageTrackingLog -Start (Get-Date).AddHours(-1) | Where-Object {$_.recipients -like "*@gmail.com"} |
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 Disable-Indexing { | |
Param($Drive) | |
$obj = Get-WmiObject -Class Win32_Volume -Filter "DriveLetter='$Drive'" | |
$indexing = $obj.IndexingEnabled | |
if("$indexing" -eq $True){ | |
write-host "Disabling indexing of drive $Drive" | |
$obj | Set-WmiInstance -Arguments @{IndexingEnabled=$False} | Out-Null | |
} | |
} |
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-VMProcessor -VMName <VMName> -ExposeVirtualizationExtensions $true | |
Get-VMNetworkAdapter -VMName <VMName> | Set-VMNetworkAdapter -MacAddressSpoofing On | |
Format-Volume -DriveLetter $driveletter -NewFileSystemLabel $drivelabel -FileSystem NTFS -AllocationUnitSize 65536 –Force -Confirm:$false -UseLargeFRS | |
fsutil fsinfo ntfsinfo d: | |
Enable-VMIntegrationService - Name 'Guest Service Interface" -VMName VMName | |
Copy-VMFile -Name DEMO01 -SourcePath C:\Inst\some.iso -DestinationPath 'C:\VMCopyFiles\some.iso' -FileSource Host -CreateFullPath | |
PS C:\> Copy-VMFile "Test VM" -SourcePath "D:\Test.txt" -DestinationPath "C:\Temp\Test.txt" -CreateFullPath -FileSource Host | |
Get-VM * | Set-VMMemory -DynamicMemoryEnabled $True -MaximumBytes 8GB -MinimumBytes 256MB -StartupBytes 512MB |
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
Install-WindowsFeature -Name Storage-Replica,FS-FileServer -IncludeManagementTools -Restart | |
$mySourceReplServer = "NE-SVR1" | |
$myDestinationReplServer = "NE-SVR2" | |
$mySourceReplGroupName = "SyncReplSiteA" | |
$myDestinationReplGroupName = "SyncReplSiteB" | |
New-SRPartnership -ReplicationMode Synchronous -SourceComputerName $mySourceReplServer -SourceRGName $mySourceReplGroupName -SourceVolumeName E: -SourceLogVolumeName F: -DestinationComputerName $myDestinationReplServer -DestinationRGName $myDestinationReplGroupName -DestinationVolumeName E: -DestinationLogVolumeName F: -LogSizeInBytes 8GB | |
Install-WindowsFeature –ComputerName localhost –Name Storage-Replica,FS-FileServer -IncludeManagementTools -restart |
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-ClusterNode | select name, nodeweight, ID, state | |
Get-ClusterQuorum | Select Cluster, QuorumResource, QuorumType | |
Get-ClusterNode | select name, nodeweight, ID, state |
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
# source https://www.n0r1sk.com/index.php/2017/04/20/wordpress-ssl-https-and-reverse-proxy-nginx-apache-httpd/ | |
# | |
<VirtualHost ${IP}:443> | |
worker_processes auto; | |
events { | |
worker_connections 4096; | |
} | |
http { |
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
upstream transmission { | |
server 127.0.0.1:9091; #Transmission | |
} | |
server { | |
listen 443 ssl http2; | |
server_name example.com; | |
auth_basic "Server Restricted"; | |
auth_basic_user_file /var/www/myWebSite/web/.htpasswd; | |
# Path to the root of your installation |
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
$crllist = Get-CACrlDistributionPoint; foreach ($crl in $crllist) {Remove-CACrlDistributionPoint $crl.uri -Force}; | |
Add-CACRLDistributionPoint -Uri C:\Windows\System32\CertSrv\CertEnroll\BEDROCK-ECA%8%9.crl -PublishToServer -PublishDeltaToServer -Force | |
Add-CACRLDistributionPoint -Uri file://\\webserv1.bedrock.domain\pki\BEDROCK-ECA%8%9.crl -PublishToServer -PublishDeltaToServer -Force | |
Add-CACRLDistributionPoint -Uri http://pki.bedrock.domain/pki/BEDROCK-ECA%8%9.crl -AddToCertificateCDP -AddToFreshestCrl -Force | |
Get-CAAuthorityInformationAccess | where {$_.Uri -like '*ldap*' -or $_.Uri -like '*http*' -or $_.Uri -like '*file*'} | Remove-CAAuthorityInformationAccess -Force | |
Add-CAAuthorityInformationAccess -AddToCertificateAia http://pki.bedrock.domain/pki/BEDROCK-ECA%3%4.crt -Force | |
certutil.exe -setreg CA\CRLPeriodUnits 2 | |
certutil.exe -setreg CA\CRLPeriod "Weeks" | |
certutil.exe -setreg CA\CRLDeltaPeriodUnits 1 | |
certutil.exe -setreg CA\CRLDeltaPeriod "Days" |
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
[Version] | |
Signature=”$Windows NT$” | |
[PolicyStatementExtension] | |
Policies=InternalPolicy | |
[InternalPolicy] | |
OID= 1.2.3.4.1455.67.89.5 | |
URL=http://pki.adatum.com/pki/cps.html | |
[Certsrv_Server] | |
RenewalKeyLength=4096 | |
RenewalValidityPeriod=Years |