SQ Server migration possibilty > Windows to Linux/Docker?

Hi Guys,

I have SonarQube server hosted on windows vm in Azure + Azure SQL db for it. I need to move them to other subscription / vnet which means the esiest/fastest way is to recreate them from scratch in new place :wink: Would like to use this opportunity to not only move it but also migrate to linux.

Current server version is 8.1.0.31237 enterprise, I will upgrade it to 8.6 before migration surely.

My action plan looks like this:

  1. Disable current server vm
  2. Create new vm with linux and docker installed in the right place
  3. Assign network configuration from old vm to new one (dns, proxy & all that stuff)
  4. Install sonar server using docker image & connect to same db

Will the old db works fine in this secenerio (created for windows server and now used on lilnux)? Do I need to setup something again after such migration, for example install plugins or configure again AzureAD integration or those settings will be preserved?

Does it looks like possible? :wink:

Hi,

Welcome to the community!

This platform migration should work seamlessly for you. Just

  • configure the new instance
  • turn off the old instance
  • turn on the new instance

Most settings are stored in the DB and since you’ll point the new instance to the existing database the transition should be transparent to your users. The one think you’ll want to make sure of is transferring your authentication settings from the old server’s sonar.properties to the new one if you’re using LDAP or SSO authentication.

 
HTH,
Ann

Ok, so I’m starting to play around with this. Sadly I’m not an docker guy so I have some issues with accessing sonar gui. Container is up & running but I cannot get the gui to start working - got connection refused. VM with container has 2 ip addresses (local & public) but it doesn’t work on any of them.

Docker run command:
docker run -d --name sonarqube
-p 9000:9000
-e SONAR_JDBC_URL=jdbc:sqlserver://10.161.244.6:1433/sonar
-e SONAR_JDBC_USERNAME= XXX
-e SONAR_JDBC_PASSWORD= XXX
-e SONAR_WEB_HOST=0.0.0.0
-v sonarqube_data:/opt/sonarqube/data
-v sonarqube_extensions:/opt/sonarqube/extensions
-v sonarqube_logs:/opt/sonarqube/logs
sonarqube:8.6-enterprise

Can I ask why you’re going with Docker? Why not just run it on the underlying box?

 
Ann

Let’s say its proof of concept and learning exercise for me :slight_smile:
Now I’m trying to move all apps scattered across many vms to docker containers, next step will be moving them to Azure Container Instances (to stop taking care of vms underneeth) and then If get them all containerized - kubernetes :slight_smile:

In the meantime I figured it out when running container in interactive mode instead as deamon I saw there were problems with accessing db. After fixing it I can access gui now. Last concern is that db migration is running now for about hour now :stuck_out_tongue_winking_eye:

Hi,

That’s a function of the size of your dataset and the horsepower you’ve put under your DB.

 
:+1:
Ann

@ganncamp I was able to login with local admin account after successful migration but looks like aad integration has to be done again. I’ve looked into installed plugins and the list is empty? Marketplace shows me now on 8.6 only 55 available plugins comparing to 89 in 8.1.Is this normal?

Hi,

In recent versions the functionality previously offered as “plugins” has been converted to embedded libraries so it’s normal that you would see fewer options in the Marketplace.

Regarding AAD integration, if you’re doing it via the AAD plugin… I’m not sure what to tell you - that’s not a plugin we support. If you’re doing it via the LDAP integration, that configuration is in your $SONARQUBE-HOME/conf/sonar.properties file & does need to be reapplied in each new version. That’s why I said “most settings are stored in the DB”. You do need to make a few manual updates to to the config file each time, such as how to contact the DB and the LDAP connection details.

 
HTH,
Ann

Thanks for explanation about those plugins :slight_smile:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.