| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- #!<%= @shell %>
- # *************************************************************************
- osWlHome=<%= @osWlHome %>
- osDomain=<%= @osDomain %>
- osDomainPath=<%= @osDomainPath %>
- nodeMgrPort=<%= @nodeMgrPort %>
- hostname=<%= @nodeMgrAddress %>
- user=<%= @wlsUser %>
- password=<%= @wlsPassword %>
- wlsAdminServer=<%= @wlsAdminServer %>
- <% if @jsseEnabled == true %>
- export CONFIG_JVM_ARGS='-Dweblogic.ssl.JSSEEnabled=true -Dweblogic.security.SSL.enableJSSE=true <%= @trust_env %>'
- <% else %>
- export CONFIG_JVM_ARGS='-Dweblogic.ssl.JSSEEnabled=false -Dweblogic.security.SSL.enableJSSE=false <%= @trust_env %>'
- <% end %>
- echo "Stopping Weblogic ${wlsAdminServer} for domain ${osDomain}...."
- echo "Checking if Weblogic ${wlsAdminServer} for domain ${osDomain} is up...."
- echo "CONFIG_JVM_ARGS ${CONFIG_JVM_ARGS}"
- unamestr=`uname`
- if [[ "$unamestr" == 'SunOS' ]]; then
- checkStmt='/usr/ucb/ps wwxa'
- else
- checkStmt='/bin/ps -eo pid,cmd'
- fi
- pid=`${checkStmt} | /bin/grep -i ${wlsAdminServer} | /bin/grep -i ${osDomain} | /bin/grep -v grep | awk '{print $1}'`
- nodePid=`${checkStmt} | /bin/grep -i nodemanager.javahome | /bin/grep -v grep | awk '{print $1}'`
- if [[ ${pid} ]]
- then
- if [[ ${nodePid} ]]
- then
- echo "The Weblogic ${wlsAdminServer} for domain ${osDomain} is running.. Stopping ${wlsAdminServer} NOW...."
- $osWlHome/common/bin/wlst.sh <<-EOF
- nmConnect('${user}','${password}','${hostname}','${nodeMgrPort}','${osDomain}','${osDomainPath}','ssl')
- nmKill('${wlsAdminServer}')
- nmDisconnect()
- EOF
- else
- echo "NodeManager is not running on this machine ${hostname}"
- echo "Start the NodeManager first"
- fi
- else
- echo "The Weblogic ${wlsAdminServer} for domain ${osDomain} is NOT running...."
- fi
- echo "Done...."
|