Sonatype nexus upgrade

How to admin and use Linux system
Post Reply
User avatar
azo
Site Admin
Posts: 11
Joined: Mon Jun 10, 2019 9:23 am

Sonatype nexus upgrade

Post by azo »

Existing version: nexus-3.19.1-01
Version to upgrade: nexus-3.37.0-01

Stop nexus:

Code: Select all

/etc/init.d/nexus stop
Get the latest version

Code: Select all

wget https://download.sonatype.com/nexus/3/latest-unix.tar.gz
Extract downloaded package. Note, all files inside sonatype-work will remain

Code: Select all

tar xzvf latest-unix.tar.gz
Replace existing symlik to new one

Code: Select all

sudo rm /etc/init.d/nexus
sudo ln -s /home/user/nexus-3.37.0-01/bin/nexus /etc/init.d/nexus
Version nexus-3.19.1-01 worked with HTTPS.
If we run new version, it will not be started.

Code: Select all

Keystore was tampered with, or password was incorrect
To avoid the issue we can switch off HTTPS

Code: Select all

sudo nano /home/user/sonatype-work/nexus3/etc/nexus.properties
And make its content like this

Code: Select all

# Jetty section
application-port=8081
#application-port-ssl=8443
# application-host=0.0.0.0
nexus-args=${jetty.etc}/jetty.xml,${jetty.etc}/jetty-http.xml,${jetty.etc}/jetty-requestlog.xml
#,${jetty.etc}/jetty-https.xml
ssl.etc=${karaf.data}/etc/ssl
# nexus-context-path=/

# Nexus section
# nexus-edition=nexus-pro-edition
# nexus-features=\
#  nexus-pro-feature

# nexus.hazelcast.discovery.isEnabled=true
Now Nexus can be run in test mode

Code: Select all

/home/user/nexus-3.37.0-01/bin/nexus run
At this run Nexus installation will be upgraded.
Note, downgrade will not be possible.

Restart system to run Nexus as a service automatically.
Post Reply