Scope
Users that are upgrading from PowerShell Universal v4 to PowerShell Universal v5 using the MSI and SQLite persistence database.
Problem
The service may not start in a timely manner and cause the MSI process to fail.
Root Cause
PowerShell Universal v5 introduced new indices on tables within the PSU database that may be large in size. These include the LogEntry and JobOutput tables. Building these indices can take time and Service Control Manager may not wait for the service to fully start before giving up.
Solution
In order to successfully upgrade, you may need to update the database schema outside of the MSI process. You can use one of the following methods to do so.
Prior to 5.0.6
2. Uninstall the PowerShell Universal v4 service
4. Extract the ZIP file and run the Universal.Server.exe executable as an administrator
5. Allow the PSU service to migrate the database file. This can take some time. Once logging begins in the console window, the process is complete, and you can close the window.
6. Download and install PowerShell Universal v5.
5.0.6 and Later
2. Uninstall the PowerShell Universal v4 service
4. Extract the ZIP file and run the psudb.exe as administrator with the following command line arguments: -p <path to database file> -m
5. This will perform a database migration and will print out when it has completed.
6. Download and install PowerShell Universal v5.