Weblogic 12c installation/implementation in Linux with GUI

Overview

The objective of this Post is to talk about the step by step process of installing the weblogic 12c in GUI mode and creating the domains.

Here is a Quick Summary of what we will be discussing on this post

  1. System requirements
  2. Creating dedicated user and group for weblogic
  3. Install Xterm and supporting packages for Graphical user interface
  4. Installing the weblogic12c using the installation JAR
  5. Start Configuring your Domain
  6. Create Cluster and JVMs

Before we start:  

  1. This Document does not cover the Linux VM machine provisioning
  2. We assume that you have access to ROOT user in your Linux VMs
  3. We assume that you have Windows PC as a base OS and connecting to Linux using SSH tools like Putty/SuperPutty etc.

 

System Requirements:

Please refer this link to know the system requirements for installing weblogic12c https://docs.oracle.com/cd/E24329_01/doc.1211/e24492/prepare.htm#WLSIG107

In our case it is Linux VM.

I have two Virtual machines already built and kept ready with the below configuration

  1. 4 CPU cores
  2. 16GB of Physical Memory(RAM)
  3. Red Hat Enterprise Linux 6 - 64 edition

Name of the virtual machines are mwi-linux-01 and mwi-linux-02

Here are the quick commands to determine  the memory and CPU configuration in LINUX

 

To know how many CPUs are available in the box

Method1:

root@mwi-linux-01# iostat|head -1
Linux 2.6.32-696.1.1.el6.x86_64 (mwi-linux-01)   06/23/2017      _x86_64_        (2 CPU)

Method2:

root@mwi-linux-01# cat /proc/cpuinfo|grep -i processor|wc -l
2

 

To know the Physical memory

Method1:

root@mwi-linux-01#  cat /proc/meminfo|grep -i MemTotal|awk '{ print $2/1024/1024,"GB"}'

15.5775 GB

 

Method2:

root@dr-mwi-linux-01# free -g
             total       used       free     shared    buffers     cached

Mem:            15          9          6          0          0          7

As my system configuration meets the WLS12C installation prerequisites. Let's move on.

 

 

Creating dedicated user and group for weblogic

Create group

groupadd -g 101 weblogic

 

Create User

/usr/sbin/useradd -u 101 -g 101 -c "weblogic" -m -d /home/weblogic -s /bin/bash weblogic

 

 

Install Xterm and supporting packages for Graphical user interface

Before we install GUI packages in the server, In your base OS (Windows) you should install  Xming , you can download Xming installable from here https://sourceforge.net/projects/xming/

After installing you should start the xming server in the windows and configure your SSH tool (putty) to enable X11 forwarding.

These steps should be performed before SSHing (logging in) to the server in PUTTY

Open Putty, Before typing the hostname/IP address to log in

Click on the DefaultSettings" and click the Load button

In the putty LEFT Category tree, Click and Expand the Connection option and further expand SSH

Click X11  , In the right side, you will have check box to Enable X11 forwarding

Now , Go back to the Session Category in PUTTY and click Default Settings and then Save

Now type the Hostname/IP address of your VM to login

Once you logged in.  Switch user to "root"  and execute the below commands one after another

yum groupinstall "X Window System" -y
yum install xterm
yum install xclock

 

Note: we presume that yum repository is up to date.

Its recommend to re-login from putty with your base user id ( NON ROOT| FROM WHERE YOU WILL BE SWITCHING TO ROOT) as there will be an  .Xauthority file created, which is required for weblogic installations as well.

In my case its  aksarav

aksarav@mwi-linux-01> id aksarav
uid=01(aksarav) gid=100(users) groups=100(users),102(admins)

aksarav@mwi-linux-01> ls -lrta .Xauthority
-rw----- – 1 aksarav users 73 Jun 23 12:33 .Xauthority

aksarav@mwi-linux-01> pwd
/home/aksarav

 

After the successful completion of installing those components,  you are ready to test the Graphical Interface of your Linux.

aksarav@mwi-linux-01> xclock
Warning: Missing charsets in String to FontSet conversion

 

Installing the weblogic12c using the installation JAR

Before we start the weblogic12c installation, we need to do some ground level tasks like java installation and directory creation etc.

Let's start with creating a directory which is going to hold our installable files

aksarav@mwi-linux-01> xclock
Warning: Missing charsets in String to FontSet conversion

 

I have already downloaded the JDK and weblogic installation files and uploaded to my installation base directory ( /opt/weblogic/wls_installables)

aksarav@dr-mwi-linux-01> ls -rlt
total 4
drwxrwxr-x 2 weblogic weblogic 4096 Jun 22 11:28 weblogic_installables

aksarav@mwi-linux-01> pwd
/opt/weblogic

aksarav@mwi-linux-01> ls -lrt weblogic_installables/
total 4368156
-rw-r--r – 1 weblogic weblogic  923179081 Jun 22 11:22 fmw_12.1.3.0.0_wls.jar
-rw-r--r – 1 weblogic weblogic  366714880 Jun 22 11:22 jdk-8u101-linux-x64.tar
aksarav@mwi-linux-01>

 

You can download Java and weblogic12c from the following links

http://www.oracle.com/technetwork/middleware/weblogic/downloads/wls-main-097127.html

http://www.oracle.com/technetwork/java/javase/downloads/index.html

 

Here is the versions information of my installation files

  • Java 8 u101
  • Weblogic 12.1.3.0

 



 

First and foremost, we need to install Java.

Extract the downloaded tarball "jdk-8u101-linux-x64.tar"  under /opt/ location. You will get a  directory named jdk1.8.0_101 this is going to serve as your JAVA_HOME

aksarav@mwi-linux-01> ls -lrt /opt/jdk1.8.0_101/
total 25912

-rwxr-xr-x 1 weblogic weblogic   110114 Jun 22  2016 THIRDPARTYLICENSEREADME-JAVAFX.txt
-rwxr-xr-x 1 weblogic weblogic  5090295 Jun 22  2016 javafx-src.zip
-r--r--r-- 1 weblogic weblogic   177094 Jun 22  2016 THIRDPARTYLICENSEREADME.txt
-r--r--r-- 1 weblogic weblogic      159 Jun 22  2016 README.html
-r--r--r-- 1 weblogic weblogic       40 Jun 22  2016 LICENSE
drwxr-xr-x 3 weblogic weblogic     4096 Jun 22  2016 include
drwxr-xr-x 4 weblogic weblogic     4096 Jun 22  2016 db
-r--r--r-- 1 weblogic weblogic     3244 Jun 22  2016 COPYRIGHT
-rw-r--r-- 1 weblogic weblogic 21108487 Jun 22  2016 src.zip
-rw-r--r-- 1 weblogic weblogic      526 Jun 22  2016 release
drwxr-xr-x 4 weblogic weblogic     4096 Jun 22  2016 man
drwxr-xr-x 5 weblogic weblogic     4096 Jun 22  2016 jre
drwxr-xr-x 5 weblogic weblogic     4096 Jun 22  2016 lib
drwxr-xr-x 2 weblogic weblogic     4096 Jun 22  2016 bin

 

Now we need to set environment variables and include JAVA in the PATH variable so that we can use JAVA  with reference and not by mentioning the full path all the time.

To set Environment Variable there are many ways like , updating bash_profile, use export commands in terminals etc.

I prefer to do it with another method.

Switch to root ( if you are not already)

Goto /etc/profile.d and create a file named javaenv.sh with the following lines

PATH="$PATH":/opt/jdk1.8.0_101/bin/
export PATH
export JAVA_HOME=/opt/jdk1.8.0_101

 

root@mwi-linux-01# cd /etc/profile.d
root@mwi-linux-01# cat > javaenv.sh
PATH="$PATH":/opt/jdk1.8.0_101/bin/
export PATH
export JAVA_HOME=/opt/jdk1.8.0_101
^D
root@mwi-linux-01# ls -rlt javaenv.sh
-rw-r--r – 1 root root 83 Jun 23 16:05 javaenv.sh

Now su to weblogic and type java -version  you should get a positive result with version info.

weblogic@mwi-linux-01# java -version
java version "1.8.0_101"
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode)

Oof, Don’t get tired.. Here comes the weblogic installation

Goto your installation base directory /opt/weblogic/weblogic_installables  and execute the weblogic installation JAR file.

Ohhhh… Wait..Wait.. There is  something pending for GUI to work.

Switch to root ( if you are not already) and execute the below commands

root@mwi-linux-01# cp /home/aksarav/.Xauthority /home/weblogic/
root@mwi-linux-01# chown weblogic:weblogic /home/weblogic/.Xauthorityroot@mwi-linux-01# cp /home/aksarav/.Xauthority /home/weblogic/ root@mw

 

Yes, you got it right. We are copying the .Xauthority file from base user to weblogic user .

Now switch to weblogic user and type xclock to verify GUI is working.

root@mwi-linux-01# su - weblogic
weblogic@mwi-linux-01> xclock
Warning: Missing charsets in String to FontSet conversionroot@mwi-linux-01# su - we

 

If you get the clock window, kudos to yourself.

Now we can resume to weblogic installation using the JAR file

Go to /opt/weblogic/weblogic_installablesand execute the below command

java -jar fmw_12.1.3.0.0_wls.jar

Sample execution output is given below

weblogic@mwi-linux-01> java -jar fmw_12.1.3.0.0_wls.jar
Launcher log file is /tmp/OraInstall2017-06-23_04-50-51PM/launcher2017-06-23_04-50-51PM.log.
Extracting files........
Starting Oracle Universal Installer
Checking if CPU speed is above 300 MHz.   Actual 2600.000 MHz    Passed
Checking monitor: must be configured to display at least 256 colors.   Actual 16777216    Passed
Checking swap space: must be greater than 512 MB.   Actual 2097148 MB    Passed
Checking if this platform requires a 64-bit JVM.   Actual 64    Passed (64-bit not required)
Checking temp space: must be greater than 300 MB.   Actual 3708 MB    Passed
Preparing to launch the Oracle Universal Installer from /tmp/OraInstall2017-06-23_04-50-51PM
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=512m; support was removed in 8.0

 

If everything is OK. You would have got the  below screen

Hit OK to continue

Hit Next to continue

I have decided to use /opt/weblogic/weblogic12130 as my ORACLE_HOME ( ORACLE_HOME should be empty)

Hit Next to continue

 

Hit Next to continue with Weblogic Server installation

Hit Next to continue

As I do not wish to receive email updates from Oracle. I just unchecked the checkbox and left the email empty

Some Dialog box would be displayed to confirm - Just Hit Yes  to continue

You can optionally  hit  Save Response file to perform silent installation of weblogic later. Then Hit Install to continue

Hit Next to continue

 Uncheck the Automatically Launch the Configuration Wizard , Let's go manual and initialize the domain configuration wizard by ourselves

 

Hit Finish to exit.

 

Congratz.. We have completed the weblogic installation.  Let's create domains.



 

 

Weblogic Domain Configuration and Server Creation

Weblogic provides domain configuration wizard  to create domains in GUI, to invoke domain configuration wizard

Got to ORACLE_HOME(/opt/weblogic/weblogic12130)  then to wlserver/common/bin directory

weblogic@mwi-linux-01> ls -rlt config.sh
-rwxr-x- – 1 weblogic weblogic 471 Dec 19  2012 config.sh

Execute the config.sh script, you would be presented with the GUI tool like given below

As we are going to install the basic weblogic server domain, I have selected the corresponding template

Set your username and password the AdminServer( applicable for the whole Domain)

Select the Domain Mode. I am going for a production mode here

I am selecting all the checkboxes

Configure Administration Server.

Configure NodeManager, use the same username and password we have used.

I am adding two new server instances, One per Node.

mwi_server1  – > mwi-linux-01

mwi_server2  – > mwi-linux-02

Create new cluster, I named it as mwi_cluster

Assign the server mwi_server1 and mwi_server2 to mwi_cluster

Configuring  Linux Machines into weblogic.

Assign server to the machines according to the configuration.

mwi_server1  – > mwi-linux-01

mwi_server2  – > mwi-linux-02

 

Click Next to continue

In the , Configuration Summary Page validate the configuration and click create to proceed.

 

After configuration Progress. If everything went well, we would see the configuration Success Page

Well. We have created our Domain now.

The Preceding Illustration would explain our domain setup.

 

 

What's Next

  1. Start the AdminServer from the terminal and access the console with the username and password we have set in domain configuration wizard
  2. Copy the entire ORACLE_HOME /opt/weblogic/weblogic12130 directory from node1(mwi-linux-01) to node2(mwi-linux-02)
  3. Install the JDK and configure the profile.d and set JAVA environment in the node2 (mwi-linux-02). Repeat the steps discussed earlier.
  4. Pack and unpack the mwi_domain from node1(mwi-linux-01) to node2(mwi-linux-02). Refer this link to know how http://www.mwinventory.in/2017/06/how-to-pack-and-unpack-the-domain-in-weblogic.html
  5. Start the node manager in both boxes(nodes) and start the managed server from console.

Good Luck.

Happy to Help. Let me know  if you need any help

Cheers,

A K S A R A V