Showing posts with label Ubuntu. Show all posts
Showing posts with label Ubuntu. Show all posts

Sunday, March 23, 2025

Nexus Server Installation in Ubuntu Linux Server - Mithun Technologies - +91-99809 23226

 

Mithun Technologies            +91-9980923226              devopstrainingblr@gmail.com

                                                       http://mithuntechnologies.com/
                                                       http://mithuntechnologies.co.in/ 

Note: As of release 3.78.0, the Unix archive comes bundled with a platform-specific JDK. This means that the Unix archive cannot be used on a Mac. No need to install Java.
 

Login as a root user
sudo su -
cd /opt
wget https://download.sonatype.com/nexus/3/nexus-unix-x86-64-3.78.0-14.tar.gz
tar -xvf nexus-unix-x86-64-3.78.0-14.tar.gz
mv nexus-3.78.0-14 nexus

#As a good security practice, Nexus is not advised to run nexus service as a root user, so create a new user called nexus and grant sudo access to manage nexus services as follows.
 

useradd nexus

#Give the sudo access to nexus user

visudo
nexus ALL=(ALL) NOPASSWD: ALL

#Change the owner and group permissions to /opt/nexus and /opt/sonatype-work directories.

chown -R nexus:nexus /opt/nexus
chown -R nexus:nexus /opt/sonatype-work
chmod -R 775 /opt/nexus
chmod -R 775 /opt/sonatype-work

#Open /opt/nexus/bin/nexus.rc file and  uncomment run_as_user parameter and set as nexus user.

vi /opt/nexus/bin/nexus.rc
run_as_user="nexus"

#Create nexus as a service

ln -s /opt/nexus/bin/nexus /etc/init.d/nexus

#Switch as a nexus user and start the nexus service as follows.

sudo su - nexus

#Enable the nexus services
sudo systemctl enable nexus

#Start the nexus service
sudo systemctl start nexus

#Check  the nexus service status
sudo systemctl status nexus

#Access the Nexus server from Laptop/Desktop browser.
 
http://IPAddess/Hostname:8081/

#Default Credentials
User Name:
Password:

Troubleshooting
---------------------

nexus service is not starting?

a)make sure need to change the ownership and group to /opt/nexus and /opt/sonatype-work directories and permissions (775) for nexus user.
b)make sure you are trying to start nexus service with nexus user.
c)check java is installed or not using java -version command.
d) check the nexus.log file which is availabe in  /opt/sonatype-work/nexus3/log  directory.

Unable to access nexus URL?
-------------------------------------

a)make sure port 8081 is opened in security groups in AWS ec2 instance.

 

 



Monday, September 27, 2021

Java Installation in Ubuntu Linux Server - Mithun Technologies - 9980923226


Mithun Technologies            +91-9980923226              devopstrainingblr@gmail.com

                                                       http://mithuntechnologies.com/
                                                       http://mithuntechnologies.co.in/ 
Java Installation in Ubuntu Linux Server

 

 By default, Ubuntu 18.04 includes OpenJDK version 11,which is an open-source variant of the JRE and JDK.

To install this version, first update the package index with below command.

#sudo apt update

Then execute below commands based on which version you want to install.

#apt install default-jre : For Defauly version.
#apt install openjdk-11-jre-headless : For Java 11
#apt install openjdk-8-jre-headless : For Java 8


Verify the Java installation with below command.
#java -version

To install the JDK, execute the following command, which will also install the JRE.

#sudo apt install default-jdk

Verify that the JDK is installed by checking the version of javac, the Java compiler using below command.

#javac -version


To Install the Open JDK 8, use the below command.

#sudo apt install openjdk-8-jdk

Nexus Server Installation in Ubuntu Linux Server - Mithun Technologies - +91-99809 23226

  Mithun Technologies            +91-9980923226              devopstrainingblr@gmail.com                                                  ...