Blog - comments

Can someone please forward me all the netbackup commands with detail information I want CLI.

Shekhar D

thanks like it

internet shop
Thanks,I have installed AV server successfully but agent deployment failed on windows2008 OS. After ...
Silvere
Hi Eyal, thanks for your comment. I'm not sure to understand what you mean by predicate here but let...
Hi Greg, thanks for your comment. No, it doesn't matter because dbcc checkdb will issue an internal ...
Blog Gérard Wisson Java Virtual Machine Diagnostics: Starting/stopping JVMD manager

dbi services Blog

Welcome to the dbi services Blog! This IT blog focuses on database, middleware, and OS technologies such as Oracle, Microsoft SQL Server & SharePoint, EMC Documentum, MySQL, PostgreSQL, Sybase, Unix/Linux, etc. The dbi services blog represents the view of our consultants, not necessarily that of dbi services. Feel free to comment on our blog postings.

  • Home
    Home This is where you can find all the blog posts throughout the site.
  • Categories
    Categories Displays a list of categories from this blog.
  • Tags
    Tags Displays a list of tags that have been used in the blog.
  • Bloggers
    Bloggers Search for your favorite blogger from this site.
Posted by on in Middleware

Java Virtual Machine Diagnostics: Starting/stopping JVMD manager

Although the managed server on which Java Virtual Machine Diagnostics (JVMD) manager is deployed is configured to use the the Node Manager like OMS and admin server, it is not started automatically with OMS. In this post, I will describe how to start JVMD manager automatically when the physical server boots.

To implement the script, several steps have to be executed:

  • Creation of a config file containing the encrypted password to connect to the NodeManager
  • Test the start/stop WLST commands
  • Creation of the python scripts
  • Creation of the init script

 

Config file creation

To avoid using a password in clear text, a config file containing the encrypted password will be created.

Set the MW_HOME environment variable.

 

export MW_HOME=/u01/app/oracle/Middleware

 

Create a script folder:

 

mkdir $MW_HOME/script

 

Connect to the NodeManager (in the example, nmpassword is the password to access the nodemanager):

 

source $MW_HOME/wlserver_10.3/server/bin/setWLSEnv.sh

java weblogic.WLST

nmConnect('nodemanager','nmpassword','vmtestoraem12c','7403','GCDomain','/u01/app/oracle/Middleware/gc_inst/user_projects/domains/GCDomain/','SSL')

 

Create files to avoid using the password in clear text:

 

storeUserConfig(userConfigFile='/u01/app/oracle/Middleware/script/userconfigNM.secure',userKeyFile='/u01/app/oracle/Middleware/script/userkeyNM.secure',nm='true')
nmDisconnect()

 

Test the encrypted password:

 

nmConnect(userConfigFile='/u01/app/oracle/Middleware/script/userconfigNM.secure',userKeyFile='/u01/app/oracle/Middleware/script/userkeyNM.secure', host='vmtestoraem12c', port='7403', domainName='GCDomain', domainDir='/u01/app/oracle/Middleware/gc_inst/user_projects/domains/GCDomain', nmType='SSL')

 

Test wlst start/stop command

Before creating a python script, test the start and stop commands:

 

nmStart('EMGC_JVMDMANAGER1')
nmKill(EMGC_JVMDMANAGER1')

 

Create the python scripts

The python scripts will be used to start and stop the WLS managed server where JVMD manager is deployed:

Start script:

 

# start_EMGC_JVMDMANAGER1.py 1.0 09/24/2012
#
# file: start_EMGC_JVMDMANAGER1.py
# purpose: start the EMGC_JVMDMANAGER WLS managed server because it is not sta
rted automatically by the emctl command
#
# Author: dbi_services (GWI)
# Version: 1.0 09/24/2012
#
############################################


# connect to the NodeManager using an encrypted file
nmConnect(userConfigFile='/u01/app/oracle/Middleware/script/userconfigNM.secure',userKeyFile='/u01/app/oracle/Middleware/script/userkeyNM.secure', host='vmtestoraem12c', port='7403', domainName='GCDomain', domainDir='/u01/app/oracle/Middleware/gc_inst/user_projects/domains/GCDomain', nmType='SSL')


# start the managed server
nmStart('EMGC_JVMDMANAGER1')


# disconnect from nodemanager
nmDisconnect()

 

Stop script:

 

# stop_EMGC_JVMDMANAGER1.py 1.0 09/24/2012
#
# file: stop_EMGC_JVMDMANAGER1.py
# purpose: stop the EMGC_JVMDMANAGER WLS managed server because it is not stopped automatically by the emctl command
#
# Author: dbi_services (GWI)
# Version: 1.0 09/24/2012
#
############################################

# connect to the NodeManager using an encrypted file
nmConnect(userConfigFile='/u01/app/oracle/Middleware/script/userconfigNM.secure',userKeyFile='/u01/app/oracle/Middleware/script/userkeyNM.secure', host='vmtestoraem12c', port='7403', domainName='GCDomain', domainDir='/u01/app/oracle/Middleware/gc_inst/user_projects/domains/GCDomain', nmType='SSL')

# stop the managed server
nmKill('EMGC_JVMDMANAGER1')

# disconnect from nodemanager
nmDisconnect()

 

Test the python scripts:

 

java weblogic.WLST /u01/app/oracle/Middleware/script/start_EMGC_JVMDMANAGER1.py
java weblogic.WLST /u01/app/oracle/Middleware/script/stop_EMGC_JVMDMANAGER1.py

 

Create an init script

Under /etc/init.d, create the jvmd script:


# jvmd.sh 1.0 09/24/2012
#
# file: jvmd
# purpose: start the EMGC_JVMDMANAGER WLS managed server because this is not sta
rted automatically by the emctl command
#
# Author: dbi_services (GWI)
# Version: 1.0 09/24/2012
#
# chkconfig:   345 85 15
############################################

###BEGIN INIT INFO
# Provides: jvmd
# Required-Start:
# Required-Stop:
# Should-Start:
# Should-Stop:
# Default-Start: 3 4 5
# Default-Stop: 0 1 2 6
# Short-Description: EMGC_JVMDMANAGER WLS managed server
# Description: Start and stop EMGC_JVMDMANAGER WLS managed server
### END INIT INFO

# set Weblogic environment defining CLASSPATH and LD_LIBRARY_PATH
# to start/stop various components.
export MW_HOME=/u01/app/oracle/Middleware
#
source $MW_HOME/wlserver_10.3/server/bin/setWLSEnv.sh > /dev/null
SCRIPTDIR=$MW_HOME/script


start() {
echo "start EMGC_JVMDMANAGER1"
java weblogic.WLST $SCRIPTDIR/start_EMGC_JVMDMANAGER1.py
}

stop() {
echo "stop EMGC_JVMDMANAGER1"
java weblogic.WLST $SCRIPTDIR/stop_EMGC_JVMDMANAGER1.py
}


case "$1" in
    start)
        start
        ;;
    stop)
        stop
        ;;
    *)
        echo -n "Usage: $0 {start|stop}"
        exit 2
esac
exit $?

 

Change the permission:

 

chmod u+x jvmd

 

Create the link in the runlevel folder:

 

/sbin/chkconfig --add jvmd

 

Test the script:

 

/etc/rc3.d/S85jvmd start

/etc/rc3.d/S85jvmd stop

 

At the end, reboot your server and check if the JVMD manager is up and can be used through the OMS admin console.

In case you have to stop/start the OMS and JVMD, of course you can do it manually:

 

java weblogic.WLST /u01/app/oracle/Middleware/script/start_EMGC_JVMDMANAGER1.py
emctl stop oms -all


emctl start oms
java weblogic.WLST /u01/app/oracle/Middleware/script/stop_EMGC_JVMDMANAGER1.py

 

As JVMD manager can be installed on a WLS domain other than the OMS domain, I do not think Oracle will ever integrate the start/stop procedure in the OMS by changing the startOMS.py script.

Rate this blog entry:
3

Gérard Wisson is Delivery Manager and Senior Consultant at dbi Services. He has more than ten years of experience in Enterprise Content Management (ECM) with Documentum as well as in Oracle WebLogic and Java EE / J2EE infrastructures. He is specialized in ECM infrastructure services such as installation, upgrade, high availability, and administration as well as in Oracle WebLogic services such as installation, configuration, and management. He is very experienced in the monitoring and optimization of Java EE / J2EE infrastructures with Grid/Cloud Control and JVMD. Gérard Wisson is certified Oracle Weblogic Server 11g System Administrator and Oracle Certified Associate. Prior to joining dbi services, Gérard Wisson was Senior Consultant at Solfit in Basel. He holds a diploma in Electrical Engineering from the University of Strasbourg (F). His branch-related experience covers Financial Services / Banking, Chemicals & Pharmaceuticals, etc.

Comments

  • No comments made yet. Be the first to submit a comment

Leave your comment

Guest Friday, 22 August 2014
AddThis Social Bookmark Button
Deutsch (DE-CH-AT)   French (Fr)

Contact

Contact us now!

Send us your request!

Our workshops

dbi FlexService SLA - ISO 20000 certified.

dbi FlexService SLA ISO 20000

Expert insight from insiders!

Fixed Price Services

dbi FlexService SLA - ISO 20000 certified.

dbi FlexService SLA ISO 20000

A safe investment: our IT services at fixed prices!

Your flexible SLA

dbi FlexService SLA - ISO 20000 certified.

dbi FlexService SLA ISO 20000

ISO 20000 certified & freely customizable!

dbi services Newsletter