Convert vhd to vhdx

Downloaded a vhd from azure added it to gen1 vm however only showed blinking cursor Created gen 2 vm however could not add the vhd issue reading it Converted vhd to vhdx and was able to boot On VM setting go to disk Edit Choose action Convert select VHDX set type fixed or dynamic set […]

Posted in KB - Windows Server, KB-HyperV, KB-Windows, Knowledge Base | Comments Off on Convert vhd to vhdx

Reset password on activate directory via powershell

Single user Set-ADAccountPassword –Identity useralias–Reset –NewPassword (ConvertTo-SecureString -AsPlainText “[email protected]” -Force)   Multiple Users csv with heading SamaccountName and the new password $UserFile = “C:\Temp\MultiUser.CSV” Foreach ($User in $UserFile) { $SamAccountName = $User .SamAccountName $ThisPassword = $User .Password Set-ADAccountPassword –Identity $SamAccountName –Reset –NewPassword (ConvertTo-SecureString -AsPlainText “$Password” -Force) }

Posted in KB - Windows Server, KB-Powershell/CMD, KB-Windows, Knowledge Base | Comments Off on Reset password on activate directory via powershell

Using Certify the web for lets encrypt certificates

Go to cloudflare and login click profile icon select my profile go to api tokens tab create new custom token Give token a name give the following permissions Zone Zone Edit Zone DNS Edit Zone Resources Include all zones IP Address filtering none (unless you wanted to restrict access, I have not as my IP is […]

Posted in KB - Security, KB - Server, KB - Website, KB - Windows Server, KB-CertifytheWeb, KB-Software, Knowledge Base | Comments Off on Using Certify the web for lets encrypt certificates

Bulk update VHD Location on Hyper-V Host

used for is you have already moved the files, for instance I updated from using the computer name \\storage\ to the FQDN   get Excel file get-VMHardDiskDrive -VMName * | select VMName,ControllerType,ControllerNumber,ControllerLocation,Path | Export-Csv -Delimiter “;” -Path “c:\temp\vmvhdloc.csv” In excel file update path to what you want it to be (note this does not move […]

Posted in KB - Windows Server, KB-HyperV, KB-Powershell/CMD, KB-Windows, Knowledge Base | Comments Off on Bulk update VHD Location on Hyper-V Host

Virtual disk does not mount after restarting server

Either when you reinstall OS or add a new drive it seems to of disabled auto mount Confirm you have read/write access on the server you on Server Manager->File and Storage Services->Volumes->Storage Pools Right-click storage pool and choose “Set Read-Write access” and OK on the prompt Set drive to automatically mount in powershell Get-VirtualDisk | […]

Posted in KB - Windows Server, KB-Powershell/CMD, KB-Windows, Knowledge Base | Comments Off on Virtual disk does not mount after restarting server

Windows Server 2019 – shutdown event tracker shows at every login when RDP to server

While I was building a new server in which I was using storage pools I rebooted the system to check that the drives auto mounted, while doing this I found that I kept getting the shutdown event tracker when I logged in and it did not go away (this even occurred when using restart option) […]

Posted in KB - Server, KB - Windows Server, KB-Windows, Knowledge Base | Comments Off on Windows Server 2019 – shutdown event tracker shows at every login when RDP to server

Failover Cluster manager – get list of Vm’s and if a VM has a DVD (iso file)

Powershell Get-ClusterGroup -Cluster 19-hv | ? {$_.GroupType –eq ‘VirtualMachine’ } | Get-VM | Get-VMDvdDrive   19-hv is the cluster name I have created VMName ControllerType ControllerNumber ControllerLocation DvdMediaType Path —— ————– —————- —————— ———— —- 19-RDSH SCSI 0 1 None 2016DC-1 SCSI 0 1 None 2019 SCSI 0 1 None Android IDE 1 0 ISO […]

Posted in KB - Server, KB - Windows Server, KB-HyperV, KB-Powershell/CMD, KB-Software, KB-Windows, Knowledge Base | Comments Off on Failover Cluster manager – get list of Vm’s and if a VM has a DVD (iso file)

Change the certificate used for remote desktop connection

wmic /namespace:\\root\CIMV2\TerminalServices PATH Win32_TSGeneralSetting Set SSLCertificateSHA1Hash=”CertificateSHA1Hash” You can get the Certificate SHA1 Hash by using openssl

Posted in KB - Windows Server, KB-Powershell/CMD, KB-Remote Desktop, Knowledge Base | Comments Off on Change the certificate used for remote desktop connection

Office 365 – Azure backup remove recovery services vault

Within Azure I used the Azure Backup server I unregsitered the server I was using however backup items still displayed which prevent me removing the vault solution was to go to manage > backup infrastructure then under management servers click on Backup mananagement server and remove from there. If it is a single server backup […]

Posted in KB - Server, KB - Windows Server, KB-Office 365, Knowledge Base | Comments Off on Office 365 – Azure backup remove recovery services vault

Hyper-V get VM VHD locations

Run Powershell as admin   get-vm * | select Name,@{L=”Disks”;E={$_.harddrives.path}} | Export-Csv c:\temp\vmdisklocations.csv     Creates CSV which looks like the below Name Disks WACLS1-VM S:\VM\WACLS1-vm.vhdx H:\VMs HDD\WACLS1-VM\WACLS1-backupdisk.vhdx H:\VMs HDD\WACLS1-VM\WACLS!-VMM-Lib.vhdx

Posted in KB - Server, KB - Windows Server, KB-HyperV, KB-Powershell/CMD, Knowledge Base | Comments Off on Hyper-V get VM VHD locations