virtualcenter


Our IT journal

Install the vSphere client on a Domain Controller

Sometimes, we may be in the need of installing the vSphere Client on a domain controller. You may have received a “vSphere Client cannot be installed on a Domain Controller” error by the installer. To be able to do this, you just need to open up an administrator command prompt and type the following in the same folder than the … Read More


Pressing ALT + F1 on a remote ESXi console doesn’t bring up the console prompt

Rarely when trying to access a server console via ALT + F1, the server may appear nonresponsive, however, sometimes this is just a false alarm. This is more likely happening when using a KVM device as it may send incorrect characters over. Before proceeding with this troubleshooting, please note that you need to enable console access on the host first. … Read More


Use PowerShell to post to a Slack channel with extra args

You need to create an application in Slack with incoming webhooks. Enable the application and confirm your identity. Copy that webhook. Invoke the script with system variables to post extra content for alerts, automation, escalations, etc. $message = “`n” + $args Set-StrictMode -Version Latest $payload = @{ “channel” = “#alerts”; “icon_emoji” = “:inbox_tray:”; “text” = $(Write-output “$message”); “username” = “User”; … Read More


Keep-alive script for Windows VPN connections

$ServerName = “192.168.40.1” ##### Script Starts Here ###### foreach ($Server in $ServerName) { if (test-Connection -ComputerName $Server -Count 2 -Quiet ) { write-Host “$Server is alive and Pinging ” -ForegroundColor Green } else { Write-Host “$Server is down.” Write-Host “Disconnecting…” rasdial.exe “Woodside” /DISCONNECT Write-Host “Connecting…” rasdial.exe “Woodside” user vpnpassword } }  


Changing an IP on a backup object in Altaro Backup

On a client we changed the IP addressing on their network and we already had backups in place from Altaro. Altaro didn’t take DNS changes as the vcenter was hardcoded with its IP address. In order to keep the existing chains we needed to change the VMware vCenter IP. In order to change this, we had to download SQL lite browser. … Read More


L2TP IPSec VPN fails on Windows – Enable UDP encapsulation

Open up regedit and go to the following location HKLM\SYSTEM\CurrentControlSet\Services\PolicyAgent Create a DWORD32 entry, name it AssumeUDPEncapsulationContextOnSendRule and enter a value of 2. Save and Reboot.   You can optionally execute this command on an elevated prompt. Also reboot to apply. REG ADD HKLM\SYSTEM\CurrentControlSet\Services\PolicyAgent /v AssumeUDPEncapsulationContextOnSendRule /t REG_DWORD /d 0x2 /f


Clean up records on Windows Server DNS using PowerShell

Create a script and execute it on your server. Set up a zone, the Windows Server running the DNS server, a date and the record type. Import-mode DNSServer $zone=”ZONE.TLD” $DNSServer=”DNSHOSTNAME” $beforedate=”12/20/2015″ $recordtype=”A” $records=Get-DnsServerResourceRecord -ZoneName “$zone” -ComputerName $DNSServer | Where-Object {$_.RecordType -eq “$recordtype” -and $_.TimeStamp -lt $beforedate} Foreach ($record in $records) { # Remove the DNS record by filtering Try { … Read More


Enable RDP on RDWeb when publishing applications

Sometimes we publish applications on the web front end, but we also want to give clients the option on launching an RDP session directly from the website. For doing that we need to change a registry and reboot the server: HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\CentralPublishedResources\PublishedFarms\<collection>\RemoteDesktops\<collection> Change ShowInPortal from “0” to “1”.  


Set up a dedicated SSL certificate for a RDS Host

Start by installing the certificate on the Local Machine Personal folder. Do an export to a PFX file including the private key. Access the certificate and retrieve its thumbprint from its properties. Download the following script and save it in the destination server. Use your thumbprint to enable the new certificate  


Configuring VPN profiles via CMAK

Sometimes we have to roll out our VPN, and manually creating a profile or asking a user to execute a Powershell script it’s not something we do every day. Instead, Microsoft gave us CMAK – or Connection Manager Administrator Kit, a Windows Feature that can be installed on your Windows Workstation or Server via Windows Features:   Launch cmak, and … Read More