I wanted to upgrade our on-prem SonarQube installation from 9.3 to 9.8, and move it to Docker to make future upgrades easier. The database for this would remain unchanged (an on-prem MSSQL server).
According to the documentation (License administration) the ID of the SonarQube instance should only change if the database server is changed (IP, DNS name, new database) and since I wasn’t planning on changing the database I proceeded with the upgrade.
My upgrade steps were as follows:
- stop the existing SQ service
- backup SQL database just in case
- start a new Docker-based installation using the existing configuration almost verbatim (more on this later)
- new instance upgrades DB, but upon logging into the administration tab I find the server ID was changed and our licence was invalidated
The ONLY thing in the DB connection string that was changed was that I’m no longer using integrated authentication (moving from Windows service-based deployment to Docker and I don’t think it’s possible to use integrated security there).
Because of this I had to immediately roll-back the deployment, restore the database backup and start the old service. I’m rather confused why this happened - we’re still using the same database, it’s still the same URL.
How should I make this upgrade if I want to minimise downtime? We have pipelines running and using SQ multiple times, daily, and I can’t have all of that stuck while waiting for an updated key from the SQ licensing team…