Tuesday 15 March 2016

Patch Weblogic with bsu utility

In Oracle Weblogic, we often gets security patches and other patches related to product. As Oracle Weblogic Admins it required to apply patches regularly, in this post will see how to apply patches from bsu utility in command prompt.
Preparing to Install Oracle Weblogic Server Patch set :

- Patches can be applied on a per-domain basis or 
installation –wide basis, its better to apply the patch   
to installation wide.
- user the same user
 which was used to install the 
weblogic to login to the servers. 
- Stop all running instances of weblogic on the  
domain hosted on the server.
Installing the Oracle Weblogic Serer Patch Set :
- Down load the required patch set from the oracle support. 
-  copy the patchset to 
 {MW_HOME}/utils/bsu/cache_dir  or any local directory on the server  and make sure its permissions are correct to execute the patch.
- set the WLS_Home    ( eg :. . $WL_HOME/server/bin/setWLSEnv.sh)
- Execute the bsu.sh
bsu.sh -install -patch_download_dir={MW_HOME}/utils/bsu/cache_dir 
         -patchlist={PATCH_ID} -prod_dir={MW_HOME}/{WL_HOME}
u01/oracle/fmw/utils/bsu> ./bsu.sh -install -patch_ 
download_dir
   =/u01/oracle/fmw/utils/bsu/cache_dir/ -patchlist=

12UV -prod_dir=/u01/oracle/fmw/wlserver_10.3 –verbose




Post-Install verification : 
- Restart all the weblogic servers 
- The following command is a simple way to  
determine the application of WebLogic Server PSU.
        . $WL_HOME/server/bin/setWLSEnv.sh 
  $ java weblogic.version 

Uninstalling the Patch : 

 Stop all the weblogic servers on the machine 
- Execute bsu.sh -remove -patchlist={PATCH_ID} -p 
od_dir={MW_HOME}/{WL_HOME}
      - Restart all Weblogic servers.
Note : These are general instruction for patches, but it’s advised to read  the readme file that comes with patch to make sure if it needs any additional steps for particular patch. 

Wednesday 9 March 2016

WebLogic Troubleshooting

Getting error while restarting one of the Weblogic server instance


####<March 1, 2016 6:45:44 PM IST> <Error> <EmbeddedLDAP> <bng1web2prod> <itms> <[ACTIVE] ExecuteThread: '0' for queue: 'weblog
ic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1189689344635> <000000> <Error opening the Transaction Log: ./servers/
itms/data/ldap/ldapfiles/EmbeddedLDAP.tran (Permission denied)>
####<March 1, 2016  6:45:44 PM IST> <Error> <EmbeddedLDAP> <bng1web2prod> <itms> <[ACTIVE] ExecuteThread: '0' for queue: 'weblog
ic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1189689344637> <000000> <Error Instantiating 'dc=web2prod-Domain': nul
l>
####<March 1, 2016  6:45:44 PM IST> <Critical> <EmbeddedLDAP> <bng1web2prod> <itms> <[ACTIVE] ExecuteThread: '0' for queue: 'web
logic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1189689344653> <BEA-171521> <An error occurred while initializing t
he Embedded LDAP Server. The exception thown is java.lang.ClassCastException: com.octetstring.vde.backend.BackendRoot. This ma
y indicate a problem with the data files for the Embedded LDAP Server. This managed server has a replica of the data contained
 on the Master Embedded LDAP Server in the Admin server. This replica has been marked invalid and will be refreshed on the nex
t boot of the managed server. Retry the reboot of this server.>
####<March 1, 2016  6:45:44 PM IST> <Critical> <WebLogicServer> <bng1web2prod> <itms> <main> <<WLS Kernel>> <> <> <1189689344667
<BEA-000362> <Server failed. Reason:
While restarting WL instance on 9.2 I got the above-mentioned error and I found that server is getting started but again it’s getting forced shutdown.

Solution:
Just go to that server instance directory and browse inside that for the
/local/BEA/weblogic92/domain-name/servers/server-name/data/ldap/ldapfiles directory path

You will get below listed files in that particular directory

-rw-r--r--   1 weblogic weblogic   79649      Sep 13  18:48 EmbeddedLDAP.data
-rw-r--r--   1 weblogic weblogic       0          Sep 13  18:48 EmbeddedLDAP.delete
-rw-r--r--   1 weblogic weblogic     648        Sep 13  18:48 EmbeddedLDAP.index
-rw-r--r--   1 weblogic weblogic       0          Sep 13  18:48 EmbeddedLDAP.lok
-rw-r--r--   1 weblogic weblogic   80126      Sep 13  18:48 EmbeddedLDAP.tran
-rw-r--r--   1 weblogic weblogic       8          Sep 13  18:48 EmbeddedLDAP.trpos

Just delete the below listed files inside the directory
-rw-r--r--   1 weblogic weblogic       0      Sep 13 18:48 EmbeddedLDAP.delete
-rw-r--r--   1 weblogic weblogic       0      Sep 13 18:48 EmbeddedLDAP.lok

Now restart the instance from the bin directory, this will get your Server up and running without issue.


Friday 4 March 2016

SSL Configuration for Apache

First make sure that apache installations and SSL changes have done, now use these below steps to configure SSL certificates.

Step 1 : Move to "extra" directory of apache.

Ex: cd /APACHE_HOME/conf/extra

Step 2: Generate Private Key on the Server Running Apache + mod_ssl

Ex: openssl genrsa -des3 -out .key 4096


So your result will be : .key

Step 3: Generate a Certificate Signing Request (CSR)

Ex: openssl req -new -key .key –out .csr
So your result will be : .csr

Step 4: Generate a Self-Signed SSL Certificate

Ex: openssl x509 -req -days 365 -in .csr –signkey .key -out .crt
So your result will be : .crt

Step 5: Generate a CA file

Ex: openssl req -new -x509 -days 365 -key in .key -out in .ca
So your result will be : .ca

Step 6: Generate a DER file

Ex: openssl x509 -in .crt -out .der.crt -outform DER
So your result will be : .der.crt

Step 7: Removal of Passphrase (Optional if you want to remove passphrase)

Ex: openssl rsa -in .key -out new.key
So your result will be : new.key
Now copy that “new.key” to “.key” 
Ex : cp new.key .key .

Step 8: Finally copy .key and .crt to /APACHE_HOME/conf/, so use

Ex : cp .key /APACHE_HOME/conf/
cp .crt /APACHE_HOME/conf/

Note : You can change the key capacity to higher or lower (i have given 4096==4 MB) and also key validity to more days (i have given 365==1 Year).

Now you are done with your SSL certificates

What is a Thread dump? How will you take in unix/linux and windows?

 This is especially useful if your Java application sometimes seems to hang when running under load, as an analysis of the dump will show where the threads are stuck.

We will take thread dump in following ways,

Ø  Linux : kill -3 PID
Ø  Windows (console mode) : crtl+break
Ø  Windows (service) : beasvc -dump -svcname:mydomain_myserver.


The data file and change log file used by the embedded LDAP server can potentially grow quite large. You can configure maximum sizes for these files with the following weblogic.Server command line arguments:

  • -Dweblogic.security.ldap.maxSize=<max bytes>, which limits the size of the data file used by the embedded LDAP server. When the data file exceeds the specified size, WebLogic Server eliminates from the data file space occupied by deleted entries.
  • Dweblogic.security.ldap.changeLogThreshold=<number of entries>, which limits the size of the change log file used by the embedded LDAP server. When the change log file exceeds the specified number of entries, WebLogic Server truncates the change log by removing all entries that have been sent to all Managed Servers.

What is Proxy server ?Types of proxy server

Proxy Server:
In general words proxy server is nothing but an mediator(ex: bus, if you want to go to your home by using bus you can reach your destination) the same way we are using proxy server in weblogic.
 Proxy Server is an intermediary server between your web browser (client) which requests for some information/data and your server (web server/Application server) that process the data.

Types of Proxy Server:
 They are three different types of proxy servers. They are as follows

     1) Forward Proxy Servers:
Forward Proxy Server is a server which forwards the request from the intranet clients (web browser) to the internet servers. These proxy servers are present in the same network of your client.
     2)Open Proxy Server:
An open proxy is a proxy server which is accessible by any Internet user. Any proxy server that doesn’t restrict its client base to its own set of clients and allows any other client to connect to it is known as an “Open Proxy”.An anonymous open proxy allows users to conceal their IP address while browsing the Web or using other Internet services. They are in numerous open proxy servers present in Internet. For converting any flavor of proxy servers to Open Proxy servers we just have to enable the flag “ProxyRequests On” in the configuration file.
      3)Reverse Proxy Server:
A Proxy Server which takes requests from external clients (web browsers) or Internet and forwards them to servers in an internal network is called as Reverse Proxy Server. Generally, the reverse proxy servers are present in the same network where we have our App/Web servers.
Advantages of using Reverse Proxy Servers: The various advantages of using the proxy servers are as follows
           1) Filtering
2) Caching
3) Bypassing filters and censorship
4) Logging and eavesdropping
5) Gateways to private networks

6) Accessing services anonymously

WebLogic server Life Cycle:

Starting state:
During the starting state that instances ready the domain configuration data from its configuration directory. Whereas the Manager server will get their configuration data from Admin server. It is in this state that the instance the basic services such as the kernal and execute queues, the container service for logging and Node manager service. The server also deploy during this phase.

Stand by: 
In this state the server Instance will allow you to issue just to administrative requests. You can me the server state either running or shutdown state. Normally the server instance will automatically transition through the stand by state to next stage unless you start the instance with the start in stand by command.
Note: All ports are closed in this stat. But you can quickly transition to a running state.

Admin mode: 
The admin mode permits only Administrative task, deploying applications with those applications being able to only request from users with the admin and App tester roles. Running a server in admin mode is also useful when trying to diagnose problems with application gone badly.
Note: Servers will run in admin mode when there is problem with deployed application or JDBC connection pool.we can resume the server from Admin state to resume state.

Resuming state:
This is purely transitional state the server instance goes through after it transitions automatically through Admin state or you issue the resume command after first placing the instance in the stand by or Admin state. You can do this state change from command line or through the Admin console.


Running state: 
This is off course final state the server instance reaches after you either issue a start up command or resume command to move the server out of the Admin or stand by state. It is in the running state that the server can accept the service client request for it services.

What is boot.properties file and how to create

Boot.properties is a file, it containing  weblogic server username and password .
If your server is in production mode then only you have to create manually this boot.properties file.
If your server is in Development then you no need to create this file because server it self create this file while creating Domain.
A boot identity file contains the user credentials for starting and stopping an instance of WebLogic Server. An administration server or managed server can refer to this file for user credentials instead of prompting at the command line to provide them.

To Create boot.properties:
Go to below location
Win :   C:\Oracle\Middleware\user_projects\domains\test_domain\servers\AdminServer\
Linux : Oracle\Middleware\user_projects\domains\test_domain\servers\AdminServer\
1.First you have to create security folder under AdminServer
2.Create boot.properties file under security folder.
3.Open notepad and write the below two lines
username=**********
password=***********
4.Save the file
5.Now your boot.properties file has been ready from next time your server starting it won't ask username and password, internally your server will call boot.properties file .you can find the below info in your log .
<Sep 21, 2014 10:06:35 PM IST> <Notice> <Security> <BEA-090082> <Security initia
lizing using security realm myrealm.>
<Sep 21, 2014 10:06:35 PM IST> <Notice> <Security> <BEA-090083> <Storing boot id
entity in the file: C:\Oracle\Middleware\user_projects\domains\test_domain\serve
rs\MS2\security\boot.properties>
Note:
If your server is in MSI Mode then you have to copy the security folder along with boot.properties and paste in to all your manage servers.

Differences b/w Development and Production Env

SSL:

Development Mode: You can use the demonstration digital certificates and the demonstration keystores provided by the WebLogic Server security services. With these certificates, you can design your application to work within environments secured by SSL.

Production Mode: You must not use the demonstration digital certificates and the demonstration keystores. If you do so, a warning message is displayed.

Deploying applications:

Development Mode: WebLogic Server instances can deploy and update applications that reside in the domain_name/autodeploy directory automatically. It is recommended that this method be used only in a single-server development environment.
Production Mode: The auto-deployment feature is disabled; so, you must use the WebLogic Server administration console, the weblogic.Deployer tool, or the WebLogic Scripting Tool.

Log file rotation:

Development Mode: By default, when you start the WebLogic Server instance, the server automatically renames (rotates) its local server log file as SERVER-NAME.log.n. For the remainder of the server session, messages accumulate in the log file until the file grows to a size of 500 kilobytes.

Production Mode: The server rotates the local log file after the size of the file reaches 5000 kilobytes. When the server is configured for production mode, by default, all versions of the log files are kept. Administrators may want to customize the number of log files retained.

JDBC system resource:

Development Mode: The default capacity is 15 connections.

Production Mode: The default capacity is 25 connections.

Security:

Development Mode: The configuration of security is relatively relaxed, allowing you to auto-deploy applications.


Production Mode:  The configuration of security is stringent, requiring a user name and password to deploy applications. Before putting a domain into production, familiarize yourself with the securing the production environment.

Change Heap in SOA

If you want to change default Memory Settings in SOA and Customize them according to your Admin and Managed Servers.

Increase Heap size memory in SOA Server follow below steps:

Backup for setSOADomainEnv.sh (/user_projects/domain/<soa_domain_name>/bin/setSOADomainEnv.sh
Update setSOADomainEnv.sh
Find - Below Values in setSOADomainEnv.sh:
DEFAULT_MEM_ARGS="-Xms512m -Xmx1024m"
PORT_MEM_ARGS="-Xms768m -Xmx1536m"

Replace With - Below Custom Values:
# line to specify different Xmx and Xms values to soa_server.
if [ "${SERVER_NAME}" = "soa_server1" ] ; then
DEFAULT_MEM_ARGS="-Xms2048m -Xmx2048m"
PORT_MEM_ARGS="-Xms2048m -Xmx2048m"
elif [ "${SERVER_NAME}" = "" ] || [ "${SERVER_NAME}" = "AdminServer" ]; then
DEFAULT_MEM_ARGS="-Xms512m -Xmx512m"
PORT_MEM_ARGS="-Xms512m -Xmx512m"
fi

3. Restart Admin and Managed Servers, Check new settings using below commands.

4. ps -ef |grep AdminServer and ps -ef |grep soa_server1


Change JDK In Weblogic Server

Sometime it is required to switch JDK used by weblogic server for example from Sun to JRockit (which gives better performance). Another use case could be to switch from 32 to 64 bit JDK as well as latest supported JDK. To verify supported JDK version checkOracle FMW support matrix


Installing new JDK:

First step is to install your desired JDK. Follow these steps to install

1. Download JRockit JDK from OTN

2. FTP the file to server and unzip it by running following command
$ unzip  jrockit_282V30318-01.zip

3. The file will be extracted with .bin extension, change the permission and make it executable.
$ chmod 755 jrockit-jdk1.6.0_29-R28.2.2-4.1.0-linux-x64.bin

4. Install JRockit to your desired location (in my example i have xserver running).

Follow the wizard to complete the installation. I installed JRockit on /u01/Oracle/jrockit-r28.2.2

$ ./jrockit-jdk1.6.0_29-R28.2.2-4.1.0-linux-x64.bin

Changing Weblogic Configuration to use new JDK

1. Shutdown all managed servers in Weblogic domain

2. Backup the following files
$MW_HOME/user_projects/domains/<domain  name>/bin/setDomainEnv.sh
$WL_HOME/common/bin/commEnv.sh

e.g.
$ cd  /u01/Oracle/Middleware/user_projects/domains/base_domain/bin
$ cp setDomainEnv.sh  setDomainEnv.sh.before_jdk_change

$ cd /u01/Oracle/Middleware/wlserver_10.3/common/bin
$ cp commEnv.sh  commEnv.sh.before_jdk_change

3. Edit setDomain.env file and find ${JAVA_HOME}
Comment the JAVA_HOME entry

#JAVA_HOME="${JAVA_HOME}"
#export  JAVA_HOME


4. Add the following after this

# Added the following lines to change to JRockit JDK
JAVA_HOME="/u01/Oracle/jrockit-r28.2.2"
export  JAVA_HOME
JAVA_VENDOR="Oracle"
export JAVA_VENDOR



5. Search the following section in the file, specifically for "-Djrockit.optfile":


Note: This parameter usually gives warning of being obsolete
you will find

EXTRA_JAVA_PROPERTIES="-Dcommon.components.home=${COMMON_COMPONENTS_HOME}   -Djrf.version=11.1.1 
-Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.Jdk14Logger 
-Ddomain.home=${DOMAIN_HOME} 
-Djrockit.optfile=${COMMON_COMPONENTS_HOME}/modules/oracle.jrf_11.1.1/jrocket_optfile.txt 
-Doracle.server.config.dir=${ORACLE_DOMAIN_CONFIG_DIR}/servers/${SERVER_NAME} 
-Doracle.domain.config.dir=${ORACLE_DOMAIN_CONFIG_DIR}
......"

remove the "-Djrockit.optfile" property:
-Djrockit.optfile=${COMMON_COMPONENTS_HOME}/modules/oracle.jrf_11.1.1/jrocket_optfile.txt

6. Save the file

7. Edit commEnv.sh file, find the following section

if [ -z "${JAVA_HOME}" -o -z "${JAVA_VENDOR}" ]; then



8. Add the following line after above section
JAVA_HOME="/u01/Oracle/jrockit-r28.2.2"
export JAVA_HOME
JAVA_VENDOR="Oracle"
export JAVA_VENDOR



9. Start Admin Server and confirm your changes by running following command

$ ps -ef | grep Admin

if you see something similar then your are good to start other managed servers


oracle   13927 13771  5 15:30 ?        00:03:58 /u01/Oracle/jrockit-r282.2/bin/java -jrockit -Xms2048m -Xmx2048m -Dweblogic.Name=AdminServer

Oracle weblogic Patch

patch is a piece of software designed to update a computer program or its supporting data, to fix or improve it. This includes fixing security vulnerabilities and other bugs, with such patches usually called bugfixes or bug fixes, and improving the usability or performance.

Weblogic patch:

For every quarter oracle will release patches in 2015 oracle released 3 patches for weblogic ,find the below

Jan - 12UV --- search for more info for this bug in oracle
April - YUIS --- search for more info for this bug in oracle
July - EJUW --- search for more info for this bug in oracle

Applying the patch in the linux environment.For windows environment use .cmd instead of sh.

Step :1
Check the weblogic version
Go to the below location and execute setEnv
/oracle/.../.../wlserver_10.3/server/bin
After executing set env check weblogic version by using java weblogic.version

Step 2: 
Go to the below location and copy patch file
/oracle/.../.../utils/bsu/cache_dir
cp -rf /home/.../.../AprilPatch/p20181997_1036_Generic.zip .
unzip p20181997_1036_Generic.zip
Step 3:
Apply the patch by using below command ,make sure while applying all instances should be in shutdown state.

bsu.sh -install -patch_download_dir=/oracle/.../Middleware/utils/bsu/cache_dir -patchlist=YUIS -prod_dir=/oracle/app/Middleware/wlserver_10.3


Step:4
Check the version it should be 10.3.6.0.11
java weblogic.version



Successfully applied the patch .now the weblogic version is changed from 10.3.6.0 to 10.3.6.0.11


Friday 26 February 2016

Pack and unpack

WLS_HOME  is an environment variable maps to your “wlserver<version>” directory 


Dir:
opt/middleware/bea10.3/wlserver_10.3/

Execute Following command:

$WL_HOME/common/bin dir 

pack.sh  –managed=true –domain=<domain name> -template=<domain_name.jar> -template_name=”<description>”

pack.sh  –managed=true –domain=mydomain -template=mydomain.jar -template_name=”mydomain template”
Now copy the jar file into another machine 

Unpacking :
command under $WL_HOME/common/bin location
unpack.sh –domain=<domain name> -template=<jar file name>
unpack.sh –domain=mydomain  -template=mydomain.jar


Default  template:
pack-domain=path_of_domain-template=path_of_jara_file_to_create -template_name=”template_name”[-template_author=”author”][-template_desc=”description”] [-managed=true|false][-log=log_file] [-log_priority=log_priority]
unpack-template=path_of_jara_file-domain=path_of_domain_to_be_created[-user_name=username] [-password=password] [-app_dir=application_directory][-java_home=java_home_directory] [-server_start_mode=dev|prod] [-log=log_file][-log_priority=log_priority]


JVM Crash and Native OutOfMemory Exception

JVM Crash Investigation

JVM Core Dump is the most important File to investigate the JVM Crash. By default the Core Dump will be generated. But Just in case if JVM is not able to generate the Core Dump then there may be the following reasons: 

  • If there is not enough disk space or quota to write the file in your File System.  
  • If JVM is not having to create or write a file in the directory. 
  • If another file exists in the same directory with that is read-only or write-protected. Unix/Linux-specific: Use the limit or ulimit commands to determine if core dumps are disabled.  

Example, on Linux, the command “ulimit -c unlimited” enables core dumps to be written, no matter what their size. Core dump sizes can be restricted if disk space limitations are a concern. 
It may be possible to get a thread dump before the process exits. HotSpot supports the Java_Option -XX:+ShowMessageBoxOnError; the corresponding JRockit option is -Djrockit.waitonerror. When the JVM is crashing, it may prompt the user :::Do you want to debug the problem?::: This pauses the process, thereby creating an opportunity to generate a thread dump (a stack trace of every thread in the JVM), attach a debugger, or perform some other debugging activity. However, this does not work in all cases (for eg., in case of stack overflow). 

Crash Because of OutOfMemory: Please apply the Following Flag in your JAVA_OPTIONS in the start Script of your Server: 
-XX:+HeapDumpOnOutOfMemoryError 

 Details: 

1) -XX:+HeapDumpOnOutOfMemoryError option available in 1.5.0_07 and 1.4.2_12, producing an hprof binary format heap dump (By default the DUMP will be generated in your Systems TEMP directory….In Window machine we can easily findout the TEMP directory by running the command “echo %TEMP%”) 

 2) Analyse hprof heap dumps using HAT, or jhat or YourKit (has an hprof import option) hprof heap dumps are platform independent and so you don’t need to analyze the dump on the same system that produced it. 

3) running with -XX:+HeapDumpOnOutOfMemoryError does not impact performance – it is simply a flag to indicate that a heap dump should be generated when the first thread throws OutOfMemoryError. 

 4) -XX:+HeapDumpOnOutOfMemoryError does not work with -XX:+UseConcMarkSweepGC in 1.5.0_07 

TestCase: 

public class TestXss
{
public static void main(final String[] args) throws Exception
{
 // start the given number of threads
 for (int i = 1; i <= Integer.parseInt(args[0]); i++)
  {
    System.out.println("Starting Thread " + i);
    final Thread t = new Thread("T[" + i + "]")
     {
       public void run()
        { 
          try
            {
              while (true)
                {
                  Thread.sleep(1000);
                }
            }
          catch (Exception e)
           {
             e.printStackTrace();
           }
       }
    };
  t.setDaemon(true);
  t.start();
  Thread.sleep(5);
 }
// wait 22 Thread.sleep(1000000);
}
}
Output:

NOTE:   java -Xmx1496m -Xss1m TestXss 5000
Starting Thread 411
Starting Thread 412
Starting Thread 413
Starting Thread 414
Starting Thread 415
Starting Thread 416
Starting Thread 417
Exception in thread “main” java.lang.OutOfMemoryError: unable to create new native thread
at java.lang.Thread.start0(Native Method)
at java.lang.Thread.start(Thread.java:574)
at TestXss.main(TestXss.java:18)


Note: If you see OOM in the Native Space  ( unable to create new native thread) Then Please first of all Try to decrease the -Xss size. It’s default value is -Xss512K   ———>Reduce it to ——–>  -Xss256K

Like this you will see that JVm is able to create more Native Threads…But beware that if u will decrease it more than a certain limit …u may start getting “java.lang.StackOverflowError”

To Create & Test a Virtual Host

1. Edit your hosts file and map your domain / DNS name to the server ip address. 
Unix - /etc/hosts
Window - C:\WINDOWS\system32\drivers\etc\hosts

In Window entry should be like below -
127.0.0.1       localhost lakshmiweblogicadmin.blogspot.com


2.Create a virtual host, Click on Virtual Hosts, New, Enter name for virtual host.

3.Click on name of virtual host and in "Virtual Hosts Names" field enter your domain name like here,lakshmiweblogicadmin.blogspot.com, if you more then one domain name mapped enter each separated by comma

4.
Click on target tab and select managed or admin server wherever you want to target,
5. Deploy your application on virtual host ( select deployment to deploy and target should be virtual host )
6.
Create a channel
Click on managed or admin server on which you you targeted to virtual host, select channels under protocols on right hand side
Click on new
Enter channel name & select protocol http, select next
Enter port 80, select next
Select default options and click next
Select default option and click next
Click on finish

Now, you can see below lines in the server log file on which you targeted the virtual host -

<Oct 18, 2010 10:52:18 PM IST> <Notice> <Server> <BEA-002613> <Channel "Channel-
0" is now listening on 127.0.0.1:80 for protocols http.>

7.
Now instead of http://<server>:<port>/your_apps_url, access it like http://mukeshnegi.com/your_apps_url

For example - 

if you access your apps like http://localhost:7002/shoppingcart/welcome.jsp then access it like    http://lakshmiweblogicadmin.blogspot.com/shoppingcart/welcome.jsp