Wednesday, April 12, 2017

SonarQube 6.3.1 on Solaris 11.3 SPARC

SonarQube 6.3.1 on Solaris 11.3 SPARC

Solaris support was removed from SonarQube 5.4 (see Drop Solaris scripts from distribution). Let's see if we can still get it running (it's just a Java app after all).

First download the most current release, that would be 6.3.1 in our case.

Go to Downloads to do that and then unzip it somewhere (we're using /opt here as per filesystem(5)).

# cd /opt
# unzip .../sonarqube-6.3.1.zip

Let's see, what do we have here...

# vi sonarqube-6.3.1/conf/sonar.properties
# Property values can:^M
...

Ah nasty, config files with CR+LF line endings, let's fix that

# dos2unix sonarqube-6.3.1/conf/sonar.properties sonarqube-6.3.1/conf/sonar.properties
# dos2unix sonarqube-6.3.1/conf/wrapper.conf sonarqube-6.3.1/conf/wrapper.conf

What else do we have...

# ls sonarqube-6.3.1/bin/
jsw-license/          linux-x86-64/         windows-x86-32/
linux-x86-32/         macosx-universal-64/  windows-x86-64/

Well that won't work on SPARC, let's create a new directory...

# mkdir -p sonarqube-6.3.1/bin/solaris-sparc-64/lib
# cp sonarqube-6.3.1/bin/linux-x86-64/sonar.sh sonarqube-6.3.1/bin/solaris-sparc-64/

Now we need a Java Service Wrapper for SPARC. Let's head over to Download the Java Service Wrapper to download one, which would be 64-bit Community SPARC Solaris in our case.

Let's unarchive it somewhere.

# mkdir /tmp/wrapper
# cd /tmp/wrapper
# gzcat .../wrapper-solaris-sparc-64-3.5.32.tar.gz | tar xf -
# cp wrapper-solaris-sparc-64-3.5.32/bin/wrapper /opt/sonarqube-6.3.1/bin/solaris-sparc-64/
# cp wrapper-solaris-sparc-64-3.5.32/lib/libwrapper.so /opt/sonarqube-6.3.1/bin/solaris-sparc-64/lib/

We have to clean up the old wrapper, too...

# rm /opt/sonarqube-6.3.1/lib/jsw/wrapper-3.2.3.jar
# cp wrapper-solaris-sparc-64-3.5.32/lib/wrapper.jar /opt/sonarqube-6.3.1/lib/jsw/wrapper-3.5.32.jar

Last thing, disable the update center since we're on a private network...

# cp /opt/sonarqube-6.3.1/conf/sonar.properties /opt/sonarqube-6.3.1/conf/sonar.properties.default
# perl -w -pi -e 's/^#(sonar.updatecenter.activate=)true/$1false/' /opt/sonarqube-6.3.1/conf/sonar.properties

*drum roll* Does it work?

# /opt/sonarqube-6.3.1/bin/solaris-sparc-64/sonar.sh start
Starting SonarQube...
Started SonarQube.

# tail -f /opt/sonarqube-6.3.1/logs/sonar.log
...
2017.04.12 15:41:42 INFO  app[][o.s.application.App] SonarQube is up

Looks good to me. Go to http://your.hostname:9000/ and enjoy your SonarQube instance running on Solaris/SPARC.

SonarQube 6.3.1 System Info

Read the next part at SonarQube with MySQL 5.7.

Links

No comments:

Post a Comment

389 Directory Server 1.3.x LDAP client authentication

389 Directory Server 1.3.x LDAP client authentication Last time we did a multi-master replication setup, see 389 Directory Server 1.3.x Repl...