This is an example for downgrading from MongoDB version 3.6 to version 3.4 in Ubuntu 18.04 LTS, but it can be adapted for any combination of versions.
Remove old versions. Since this was done for a compatibility issue with UniFI Controller, the first step is optional
sudo apt-get remove unifi
sudo apt-get remove mongo*
sudo apt-get autoremove
Install MongoDB v3.4 Community Edition using the guide below. They also provide guides specific to other versions that you may need.
If you are doing this for UniFi Controller (optional), download latest controller package for Ubuntu
Install it (optional)
sudo dpkg -i unifi_sysvinit_all.deb
Fix any broken packages
This guide details how to change the certificate deployment level of a Windows Server 2012 R2 RD system from “Trusted” back to the default configuration of “Not Configured.” The main problem is that the Windows GUI does not allow you to simply delete the trusted certificate and reset it back to the default “Not Configured” state for the deployment certificate level. Instead the GUI will only let you choose a different certificate (whether trusted or self signed). The steps below will get around this limitation and allow you to reset the deployment level.
First set of steps are to delete any existing Remote Desktop certificates and have Windows generate a new one automatically:
- Launch mmc.exe on the 2012 R2 server
- Choose File-Add/Remove Snap in
- Add Certificates -> choose Computer account -> then Local computer. Click OK.
- On left hand side browse to Remote Desktop folder -> Certificates folder
- Delete all certificates
- Launch services.msc
- Restart Remote Desktop Configuration service
- In Event Viewer – System, you should see a notification that a new self signed certificate was created
- Go back to mmc.exe and at the top choose Action-Refresh.
- Confirm new certificate is shown in Remote Desktop folder -> Certificates folder
- Close mmc.exe. Choose No if it prompts to save.
The next set of steps are to change the deployment level:
There is one registry key that needs to be modified:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\CentralPublishedResources\PublishedFarms\[NAME_OF_YOUR_FARM]\DeploymentSettings]
fHasCertificate – REG_DWORD set to a value of 0
Under this same key there is also a CertificateHash – REG_BINARY that contains thumbprint of the old certificate. It can probably be deleted but I have left it in place until it causes a problem.
There is a second key at the following location
with a key titled CertExpiryTracking and under it a key with a title equal to the old certificate thumbprint with a LastPeriodLogged REG_DWORD decimal value of 15. The entire CertExpiryTracking key can probably be deleted but I have left it in place until it causes a problem.
Now you will need to connect to the Windows Internal Database:
- Download and install Microsoft SQL Server Management Studio (SSMS) v17 or higher
- Launch SSMS
- Connect to internal database using this server name:
- Navigate to Databases -> RDCms -> and select rds.DeploymentSetting
- Right click on it then choose Edit Top 200 Rows
- Rename the following items:
- RedirectorCertificate – > RedirectorCertificate.bak
- PublishingCertificate -> PublishingCertificate.bak
- DeploymentCertificateHash -> DeploymentCertificateHash.bak
- WebAccessCertificate -> WebAccessCertificate.bak
- Close SSMS
- Close and reopen any Server Manager windows. Then go back and check that deployment certificate level is now showing as Not Configured.
Also if you were using a trusted certificate in IIS you may need to change the certificate for RDWeb by following these steps:
- Launch IIS Manager
- Right click Default Web Site, choose Edit Bindings
- Select https, click Edit
- Choose the appropriate SSL certificate in the dropdown list
- Restart IIS
One scenario – booting a system using a USB Windows PE flash drive, the same flash drive then could not be read within Windows PE. This was because the PE image had no USB 3.0 drivers. The solution was to inject USB 3.0 drivers into the standard Windows 7 PE image.
- Download the desired drivers
- Extract the folder that contains the .cat, .inf, etc. files for the drivers (e.g., files can be extracted from a .exe using 7zip). Place them in a temporary folder (C:\x64)
- Create a mount point folder on your local drive (e.g., C:\mount)
- Open elevated command prompt
- Get the name of the Windows PE system by pointing dism to the wim file (which could be on a portable media or your local drive). For example:
dism /get-wiminfo /wimfile:c:\winpe_amd64\iso\sources\boot.wim
- Mount it. In this example the name determined from previous step was “Microsoft Windows PE (x64)”
dism /mount-wim /wimfile:c:\winpe_amd64\iso\sources\boot.wim /Name:"Microsoft Windows PE (x64)" /mountdir:c:\mount
- Inject the drivers:
dism /image:c:\mount /add-driver /driver:c:\x64 /Recurse
dism /unmount-wim /mountdir:c:\mount /commit