Need help in deploying warn using WSAdmin install with JNDI - websphere

I am trying to deploy a web application using WSAdmin tool. But it is throwing an error.
JACl script that I am using is :
$AdminApp install /opt/www/temp/SampleApp.war {-nopreCompileJSPs -nodeployejb -server delivery -cell delivery_cell -node delivery_node -appname SampleApp -contextroot SampleApp -MapWebModToVH {{"SampleApp" SampleApp.war,WEB-INF/web.xml default_host}}}
Error I am getting is:
com.ibm.ws.scripting.ScriptingException: WASX7109E: Insufficient data for install task "MapResRefToEJB
ADMA0007E: A validation error occurred in task Mapping resource references to resources. The Java Naming and Directory Interface (JNDI) name is not specified for resource reference jdbc/app_DB in module SampleApp with EJB name.
From the error above I understand that I need to configure my JNDI with -MapResRefToEJB. I tried to understand this option but getting too confused.
Can anyone help me to resolve this issue?

These errors appear to be caused by the MapResRefToEJB option in
the wsadmin command not being set correctly, or the resource it is pointing to
not existing correctly in the web.xml file.
Additional information on MapResRefToEJB
Options for the AdminApp object install, installInteractive, edit,
editInteractive, update, and updateInteractive commands
http://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/index.jsp?topic=/com.ibm.websphere.nd.doc/info/ae/ae/rxml_taskoptions.html
Thank you
Note : Opinions are my own.

Related

can't open pom.xml and application.properties in eclipse

I create a simple login program,
but when I tried to open application.properties to initialize the data base it won't,
and I found this error
"An error has occurred. See error log for more details.
Cannot invoke "org.eclipse.e4.core.contexts.IEclipseContext.activate()" because the return value of "org.eclipse.e4.ui.model.application.ui.basic.MPart.getContext()" is nullé
I installed some snapshots files but it doesn't work
and also I tried to write into the file directly from the notepad but also not working
this is the result when I try to open it enter image description here
I was too facing similar issue. Closing and opening the Eclipse again resolved my issue. My Eclipse version was
Version: 2022-09 (4.25.0)
Build id: 20220908-1902
Probably, try restarting the Eclipse by closing all the processes and applications related to Eclipse.
This was my error:
An error has occurred. See error log for more details.
Cannot invoke "org.eclipse.e4.core.contexts.IEclipseContext.activate()" because the return value of "org.eclipse.e4.ui.model.application.ui.basic.MPart.getContext()" is null

Getting error file not found for ProcessCenter_CaseManagerConfig.properties while running BPMGenerateUpgradeSchemaScripts.bat command

I am updating IBM BPM 8.6.0 to IBM Business Automation Workflow Version 18.0.0.2, after updating fix pack for IBAW when I am running below command I get an error.
BPMGenerateUpgradeSchemaScripts.bat -profileName Node1Profile -de ProcessCenter
Below is the error which is coming on running above command.
Unable to find the response file
C:\IBM\BPM\v8.6\profiles\Node1Profile\config\cells\PCCell1\ProcessCenter_CaseManagerConfig.properties
Unable to find the file C:\IBM\BPM\v8.6\profiles\Node1Profile\config\cells\PCCell1\ProcessCenter_CaseManagerConfig.properties, please run the command 'BPMConfig -update -profile deployment_manager_profile -de deployment_environment_name -caseConfigure' to collect the configuration information for the content data sources, please read the knowledge center for details.
java.io.FileNotFoundException: C:\IBM\BPM\v8.6\profiles\Node1Profile\config\cells\PCCell1\ProcessCenter_CaseManagerConfig.properties (The system cannot find the file specified.)
CWMCO6007E: The BPMGenerateUpgradeSchemaScripts command could not complete successfully. The following exception occurred :
Faild to initialize the CommonInfo. java.io.FileNotFoundException: C:\IBM\BPM\v8.6\profiles\Node1Profile\config\cells\PCCell1\ProcessCenter_CaseManagerConfig.properties (The system cannot find the file specified.)
The file command asked to run first in the above error is on 11 point in the upgrade guide, can some one please suggest whats wrong with this?

Error with import BAR-File from OBIEE 12.2.1.0.0 to 12.2.1.2.0

I'm facing an error by importing the BAR-File of Version 12.2.1.0.0 to 12.2.1.2.0 importing it with importserviceinstance().
It is not a Linux machine, so I use the .cmd files like the wlst.cmd to export and import the BAR-File.
Export: exportServiceInstance(r'C:\DOMAIN_HOME','ssi',r'C:\WORK',r'C:\EXPORT','','','',true,'password')
So I used the option to export also all the user content by setting the second last to true.
Import: importServiceInstance(r'C:\DOMAIN_HOME','ssi',r'C:\EXPORT\ssi.bar',true,true,true,'password')
And here I set every option to true, to get everything (RPD, webcat, security Settings).
This is the error message prompted :
...
oracle.bi.bar.si.framework.handler.WebcatServiceInstanceHandler importServiceInstance
SEVERE: Failed in running importServiceInstance for plugin oracle.bi.migration.webcat.WebcatMetadataManagerGenericPlugin
Impl
oracle.bi.bar.si.framework.handler.ServiceInstanceHandlerHelper logErrorMessages
SEVERE: An error has occurred while executing command, Please check Catalog Manager log for more details.
oracle.bi.bar.si.framework.ServiceInstanceFrameWorkImpl importServiceInstance
SEVERE: Error during import service instance for handler oracle.bi.bar.si.framework.handler.WebcatServiceInstanceHandler
PM oracle.bi.bar.si.ServiceInstanceLifeCycleImpl importServiceInstance
SEVERE: Failed in running all the handlers during import service instance.
...
I've already checked the catalog manager logs, but this didn't help much to locate the problem.
Has anyone already faced the same error or has an idea how to solve this issue?
on windows, your path need to be modified from backslashes to forward
example:
instead of C:\DOMAIN_HOME you can use C:/DOMAIN_HOME
this is for all paths in the wlst commands

SonarQube Install - startsonar.bat fails

SonarQube 6.0 Installation
No plugins currently installed
Presently working through what appears to be connect string problem
In a command prompt, running as Administrator, I enter
StartSonar
This fails with rather cryptic output to the Command Prompt window. The following is what I believe is the relevant excerpt from the sonar.log file:
2016.08.11 12:23:29 INFO web[o.sonar.db.Database] Create JDBC data source for jdbc:sqlserver://localhost/DevOps;databaseName=sonar
2016.08.11 12:23:43 ERROR web[o.a.c.c.C.[.[.[/sonar]] Exception sending context initialized event to listener instance of class org.sonar.server.platform.PlatformServletContextListener
java.lang.IllegalStateException: Can not connect to database. Please check connectivity and settings (see the properties prefixed by 'sonar.jdbc.').
at org.sonar.db.DefaultDatabase.checkConnection(DefaultDatabase.java:104) ~[sonar-db-6.0.jar:na]
at org.sonar.db.DefaultDatabase.start(DefaultDatabase.java:71) ~[sonar-db-6.0.jar:na]
Relevant excerpt from .config file:
sonar.jdbc.url=jdbc:sqlserver://localhost/DevOps:1433;databaseName=sonar
sonar.jdbc.username=SonarQube
sonar.jdbc.password=PassWord1234
Finally, victory is mine! To be fair, I looked at the .config file from TeamCity. Thanks JetBrains!
The correct entries from the .config file (Note backslash / escape characters!):
sonar.jdbc.url=jdbc\:sqlserver\://localhost\\DevOps\:1433;databaseName\=Sonar
sonar.jdbc.username=SonarQube
sonar.jdbc.password=PassWord1234

AdminTask.listTCPEndPoints('abc(abc)') throws exception: ADMF0007E: target object is required

I'm working on deploying application to WebSphere 7 using python script and the script is throwing exception at this line:-
AdminTask.listTCPEndPoints('abc(abc)')
If I run the above command before I run the python script, it works fine. It gives me an error ADMF0003E: Invalid parameter value. But the same command fails in the python script with this error:
wsadmin>AdminTask.listTCPEndPoints('abc(abc)')
WASX7015E: Exception running command: "AdminTask.listTCPEndPoints('abc(abc)')"; exception information: com.ibm.websphere.management.cmdframework.CommandValidationException: ADMF0007E: target object is required.
I can guess that there something in the python script that is causing this issue, but I don't understand why is the AdminTask.listTCPEndPoints command is not able to see the parameter being passed. I'm new to WebSphere, I have only used it in past but never configured it. Any help/insight would be highly appreciated.
Thanks!
Added stack trace of interactive mode option
wsadmin>print AdminTask.listTCPEndPoints('-interactive')
List NamedEndPoints that can be used by a TCPInboundChannel
Lists all NamedEndPoints that can be associated with a TCPInboundChannel
*TCPInboundChannel: abc(abc)
excludeDistinguished (excludeDistinguished): 0
WASX7435W: Value 0 is converted to a boolean value of false.
unusedOnly (unusedOnly): 0
WASX7435W: Value 0 is converted to a boolean value of false.
List NamedEndPoints that can be used by a TCPInboundChannel
F (Finish)
C (Cancel)
Select [F, C]: [F] F
WASX7278I: Generated command line: AdminTask.listTCPEndPoints('[-excludeDistinguished false -unusedOnly false]')
WASX7015E: Exception running command: "AdminTask.listTCPEndPoints('-interactive')"; exception information:
com.ibm.websphere.management.cmdframework.CommandValidationException: ADMF0007E: target object is required.
Follow this link. It appears that you have not specified the target object that's why that error is coming.
I suggest use the following command as a starter
print AdminTask.listTCPEndPoints('-interactive')
Note: Instead of copying and pasting the command, type it on the command line. sometimes command editor does not take the command after pasting it directly.
Okay, I was able to fix the error. I was getting that error because as part of the application deployment script, I was copying few of my application jars to WebSphere's java/jre/lib/ext directory so that those are available in classpath. In one of those jar, I had bundled an IBM class (Base64Coder.class) which was required by a class in my jar and it was corrupting the WebSphere AdminTask utility. When I removed that Base64Coder.class from my jar, python script worked fine. I believe, the reason it corrupted WebSphere was that there was a duplication of the same class in the JVM as the class comes with IBM WebSphere installation and was present in AppServer/runtimes/com.ibm.ws.webservices.thinclient_7.0.0.jar

Resources