Showing posts with label OSB 11g. Show all posts
Showing posts with label OSB 11g. Show all posts

Friday, 10 June 2016

blogger

Failed to initialize the application "SB_JMS_Proxy_N7de264e1.N2efb99d.2.1553951a327.N7ffe" due to error weblogic.management.DeploymentException: Exception occured while downloading files

Hello Viewer,

Today i faced one issue while bringing up the OSB servers.Servers were not coming up. After reaching to Admin state it again went to force shutting down mode.

After seeing the logs i got the below error:

 <Error> <Deployer> <BEA-149205> <Failed to initialize the application "SB_JMS_Proxy_N7de264e1.N2efb99d.2.1553951a327.N7ffe" due to error weblogic.management.DeploymentException: Exception occured while downloading files
weblogic.management.DeploymentException: Exception occured while downloading files
        at weblogic.deploy.internal.targetserver.datamanagement.AppDataUpdate.doDownload(AppDataUpdate.java:50)
        at weblogic.deploy.internal.targetserver.datamanagement.DataUpdate.download(DataUpdate.java:59)
        at w
        Truncated. see log file for complete stacktrace
Caused By: java.io.IOException: [DeploymentService:290066]Error occurred while downloading files from Administration Server for deployment request "0". Underlying error is: "null"


Solution: Login to Admin console and goto deployments, search the ear for which you are facing the error, it should be in failed state.
It will not allow you to untarget this ear.just delete it from deployments and try to restart the server. This time servers should come up.

Thanks a lot for your patience!!!

Regards
-Ashish




Monday, 23 May 2016

blogger

Script to enable and disable the proxy service in OSB

Hello Viewer,

Below is the script for enabling and disabling the proxy in OSB which may be required during any end system downtime or for just bouncing the proxy due to some issue like not picking up the messages from queue or any other one.

Note: This is for version prior to 12c.


Steps to be followed:


1) create a file ProxyOperation.py with below content:


------------------------------------------------------------------------------------------------------------------
import wlstModule
import sys
import os
import socket
from com.bea.wli.sb.management.configuration import SessionManagementMBean
from com.bea.wli.sb.management.configuration import ALSBConfigurationMBean
from com.bea.wli.config import Ref
from java.lang import String
from com.bea.wli.monitoring import StatisticType
from com.bea.wli.config import Ref
from com.bea.wli.sb.util import Refs
from com.bea.wli.sb.management.configuration import CommonServiceConfigurationMBean
from java.lang import String
from com.bea.wli.monitoring import StatisticType
from com.bea.wli.config import Ref
from com.bea.wli.sb.util import Refs
from com.bea.wli.sb.management.configuration import CommonServiceConfigurationMBean
project = sys.argv[1]
print('project name  is: ', project)
service = sys.argv[2]
print('service name  is: ', service)
action = sys.argv[3]
print('operation name  is: ', action)
connect('user','password','t3://AdminHost:Adminport')
domainRuntime()
print('WLST Connected')
sessionName = String("SessionScript"+Long(System.currentTimeMillis()).toString())
print('... after session. Session is: ', sessionName)
sessionMBean = findService(SessionManagementMBean.NAME,SessionManagementMBean.TYPE)
print('SessionMBean is: ', sessionMBean)
sessionMBean.createSession(sessionName)
print(String('Session was created ... ').concat(sessionName))
mbean = findService(String('ProxyServiceConfiguration.').concat(sessionName),'com.bea.wli.sb.management.configuration.ProxyServiceConfigurationMBean')
projectName = Refs.makeParentRef(project + '/')
proxyRef = Refs.makeProxyRef(projectName, service)
if action == 'disable' :
  print "Disabling " + service +" has been completed"
  mbean.disableService(proxyRef)
else :
  print "Enabling " + service +" has been completed"
  mbean.enableService(proxyRef)
if action == 'disable' :
  service1 = service+" disabled"
  print service1
  sessionMBean.activateSession(sessionName, service1)
else :
  service1 = service+" enabled"
  print service1
  sessionMBean.activateSession(sessionName, service1)
print
disconnect()
exit()
-------------------------------------------------------------------------------------------------------------------

Note: change the username, password and URL according to your environment.


2) Create a file ProxyOperation.sh with below content


--------------------------------------------------------------------------------------------------------------------
#!/bin/sh


export LOGFILE="/Mylocation/ProxyOperation/ProxyOperation.log"
if [ -f $LOGFILE ]; then
  rm -f $LOGFILE
fi
rm -rf /Mylocation/ProxyOperation/ProxyOperation.log
WL_HOME="wl_home"
export WL_HOME
OSB_HOME="osb_home"
export CLASSPATH=$CLASSPATH:$OSB_HOME/Oracle_OSB/lib/sb-kernel-api.jar
export CLASSPATH=$CLASSPATH:$OSB_HOME/modules/com.bea.common.configfwk_1.2.1.0.jar
export CLASSPATH=$CLASSPATH:$OSB_HOME/Oracle_OSB/lib/alsb.jar
export CLASSPATH=$CLASSPATH:$OSB_HOME/Oracle_OSB/lib/sb-kernel-impl.jar
echo "Please enter operation you want to perform"
read PARAMETER1
cd /Mylocation/ProxyOperation/
sh ${WL_HOME}/common/bin/wlst.sh  /Mylocation/ProxyOperation/ProxyOperation.py $1 $2 $PARAMETER1 >> /Mylocation/ProxyOperation/ProxyOperation.log

---------------------------------------------------------------------------------------------------------------------


Note: 
a) Mylocation: direcotry location where you will place the above files.
b) Change the wl_home and osb_home according to your environment.


How to run:


Suppose path of your proxy service is as below (you can find this path from sbconsole)

Proxy service path: MyServices/CustomerProduct/Services/ProxyServices/Source/PS_Customer_Service
here proxy name is   PS_Customer_Service

now the command to be executed is as below:
sh ProxyOperation.sh  <MyServices/CustomerProduct/Services/ProxyServices/Source>  <PS_Customer_Service>
press enter

Please enter operation you want to performtype disable/enable(case sensitive)
press enter

your proxy will get disable or enable depending upon the operation you specify.

Thanks a lot for your patience!!!

Regards
-Ashish