-2

The Liberty server starts properly and begins to shutdown withing a second.

The server is being started in eclipse version Juno in my Windows development system. The application is a web application with ejb in it. Server configuration details below.

<server description="localWAS">

<!-- Enable features -->
<featureManager>
    <feature>jsp-2.2</feature>
    <feature>localConnector-1.0</feature>
    <feature>jndi-1.0</feature>
    <feature>wmqJmsClient-1.1</feature>
    <feature>jdbc-4.0</feature>
    <feature>ejbLite-3.1</feature>
    <!-- <feature>jpa-2.0</feature> -->
    <feature>json-1.0</feature>
    <feature>managedBeans-1.0</feature>
    <feature>cdi-1.0</feature>
    <feature>servlet-3.0</feature>
</featureManager>

<variable name="[commonlib]" value="/commonlib"/> 

<variable name="appLocation" value="[deployment ready app location]" />

<variable name="hostname" value="[host]" />

<httpEndpoint host="${hostname}" httpPort="[httpPort]"
    httpsPort="[httpsPort]" id="defaultHttpEndpoint" />

<dataSource id="[oracledb]" jndiName="[oracledb-jndi]">
    <jdbcDriver javax.sql.ConnectionPoolDataSource="oracle.jdbc.pool.OracleConnectionPoolDataSource">
        <library>
            <fileset dir="${[commonlib]}" includes="ojdbc6.jar" />
        </library>
    </jdbcDriver>
    <properties.oracle databaseName="[databaseName]" password="[password]"
        portNumber="1521" serverName="[serverName]" user="[user]" />
</dataSource>

more data sources

<variable name="wmqJmsClient.rar.location" value="/servers/IBM/lib/WMQ/ra/wmq.jmsra.rar" />

<jmsQueueConnectionFactory
    connectionManagerRef="AIXQCF" jndiName="jms/aixQCF">
    <properties.wmqJms channel="SYSTEM.ADMIN.SVRCONN"
        hostName="jdawg.pharmacy.com" pollingInterval="5s" port="1416"
        queueManager="JDAWG.QAS" rescanInterval="5s" transportType="CLIENT" />
</jmsQueueConnectionFactory>

<connectionManager id="AIXQCF" maxPoolSize="2" />

<jmsQueue id="[jmsQueueId]" jndiName="jms/[jmsQueueName]">
    <properties.wmqJms baseQueueName="[baseQueueName]" />
</jmsQueue>

more queues

<jndiEntry id="[jndiEntryId]" jndiName="[jndiEntryName]"
    value="[jndiEntryValue]" />

more jndi entries

<logging
    traceSpecification="*=info:com.ibm.ws.http.internal.*=all:com.ibm.ws.webcontainer.*=all:com.ibm.ws.http.channel.*=all:Naming=all:NamingService=all:com.ibm.ws.app*=all" />

<applicationMonitor updateTrigger="mbean" />

<application context-root="[application-context-root]" id="[application-id]"
    location="${appLocation}" name="[application-name]" type="war" /></server>

I looked at the trace log file located at [..liberty\usr\servers[profile]\logs] and extracted some logs that might be useful. Here are some classes in logs listed to shorten the lines..

ApplicationStateCoordinator - com.ibm.ws.app.manager.ApplicationStateCoordinator
ApplicationStateMachineImpl - com.ibm.ws.app.manager.internal.statemachine.ApplicationStateMachineImpl

ApplicationConfigurator - com.ibm.ws.app.manager.internal.ApplicationConfigurator
AppManagerActivator - com.ibm.ws.app.manager.ready.AppManagerActivator
Util - com.ibm.ws.classloading.internal.Util
VirtualHostImpl - com.ibm.ws.http.internal.VirtualHostImpl 
DynamicVirtualHostConfiguration - com.ibm.ws.webcontainer.osgi.DynamicVirtualHostConfiguration

logs:

[15:01:59:784] 0000001d id=         ApplicationStateCoordinator           > updateStartingAppStatus Entry  
                                                                                                               com.ibm.ws.app.manager_101
                                                                                                               STARTED

[15:01:59:784] 0000001d id=         ApplicationStateCoordinator           < updateStartingAppStatus Exit 

[15:01:59:784] 0000001d id=4150c9af internal.ApplicationConfigurator      < notifyAppStarted Exit 

[15:01:59:784] 0000001d id=6be25de7 ApplicationStateMachineImpl > setInterruptible Entry 

[15:01:59:784] 0000001d id=6be25de7 ApplicationStateMachineImpl > executeQueuedActions Entry 

[15:01:59:784] 0000001d id=         ApplicationStateMachineImpl 1 ASM[0]: [appName]: executeQueuedActions: interruptible=false

[15:01:59:784] 0000001d id=6be25de7 ApplicationStateMachineImpl < executeQueuedActions Exit  
                                                                                                               false

[15:01:59:784] 0000001d id=6be25de7 ApplicationStateMachineImpl < setInterruptible Exit 

[15:01:59:784] 0000001d id=6be25de7 ApplicationStateMachineImpl < enterState Exit 

[15:01:59:784] 0000001d id=         ApplicationStateMachineImpl 1 ASM[0]: [appName]: run: called enterState STOPPED

[15:01:59:784] 0000001d id=6be25de7 ApplicationStateMachineImpl < run Exit 

[15:01:59:784] 00000012 id=         ApplicationStateCoordinator           < getSlowlyStartingApps Exit  
                                                                                                               null

[15:01:59:784] 00000012 id=30ba9255 ready.AppManagerActivator             < start Exit 

[15:01:59:784] 00000012 id=b34dbc66 LogService-242-ready                  1 BundleEvent STARTED 
                                                                                                               Event:org.osgi.framework.BundleEvent[source=ready_1.0.3.cl50220140403-1858 [242]]

[15:01:59:815] 00000018 id=         com.ibm.ws.kernel.feature.internal.FeatureManager            I CWWKF0008I: Feature update completed in 37.251 seconds.

[15:01:59:815] 00000018 id=         com.ibm.ws.kernel.feature.internal.FeatureManager            A CWWKF0011I: The server defaultServer is ready to run a smarter planet.

[15:02:01:501] 0000002a id=b34dbc66 LogService-242-ready                  1 BundleEvent STOPPING 
                                                                                                               Event:org.osgi.framework.BundleEvent[source=ready_1.0.3.cl50220140403-1858 [242]]

[15:02:01:501] 0000002a id=30ba9255 ready.AppManagerActivator             > stop Entry  
                                                                                                               org.eclipse.osgi.framework.internal.core.BundleContextImpl@a8e8834d

[15:02:01:501] 0000002a id=         ApplicationStateCoordinator           > getSlowlyStoppingApps Entry  
                                                                                                               30
                                                                                                               SECONDS

[15:02:01:501] 0000002a id=4150c9af internal.ApplicationConfigurator      > getStoppingAppPids Entry 

[15:02:01:501] 0000002a id=4150c9af internal.ApplicationConfigurator      < getStoppingAppPids Exit  
                                                                                                               [com.ibm.ws.app.manager_101]

[15:02:01:501] 0000002a id=4150c9af internal.ApplicationConfigurator      > stopRunningApps Entry 

[15:02:01:501] 0000002a id=6be25de7 ApplicationStateMachineImpl > uninstall Entry 
<br>
[15:02:01:501] 0000002a id=         ApplicationStateMachineImpl 1 ASM[0]: [appName]: createDependency: created AppDep[7]: desc="resolves when the app [appName] finishes stopping, at which point it will be removed", future=com.ibm.ws.threading.internal.NonCancelableResultFuture@cf28eb9

[15:02:01:501] 0000002a id=         ApplicationStateMachineImpl 1 ASM[0]: [appName]: created SCA[1] action=REMOVE

[15:02:01:516] 00000021 id=         ApplicationStateMachineImpl 1 ASM[0]: [appName]: run: executing SCA[1] action=REMOVE
<br>.
<br>
[15:02:02:387] 00000021 id=         Util                        > ensureNotNull Entry  
                                                                                                               Parameter 'domain' must not be null
                                                                                                               Thread Context

[15:02:02:387] 00000021 id=         Util                        > ensure Entry  
                                                                                                               Parameter 'domain' must not be null
                                                                                                               true

[15:02:02:387] 00000021 id=         Util                        < ensure Exit 

[15:02:02:387] 00000021 id=         Util                        < ensureNotNull Exit  
                                                                                                               Thread Context

[15:02:02:387] 00000021 id=         Util                        > ensureNotNull Entry  
                                                                                                               Parameter 'id' must not be null
                                                                                                               WebModule:[appName]-[appName]-/[appName]

[15:02:02:387] 00000021 id=         Util                        > ensure Entry  
                                                                                                               Parameter 'id' must not be null
                                                                                                               true

[15:02:02:387] 00000021 id=         Util                        < ensure Exit 
<br>.
<br>
[15:02:02:450] 00000021 id=         VirtualHostImpl                     A CWWKT0017I: Web application removed (default_host): http://[host]:9080/[appName]/

[15:02:02:450] 00000021 id=a90f2905 DynamicVirtualHostConfiguration 1 Context root removed /[appName]/*
user2891264
  • 90
  • 1
  • 10
  • 1
    There is not enough context in this question. What features are configured for the server? Where is it running (VM, standalone server, docker container, ... )? What kind of application is it (web application? osgi application? ejb application?) Is it in dropins or does it have an associated app configuration? The abridged snippets from the logs don't help here. Understanding your server and application configuration would be more helpful for us to help you. – ebullient Mar 23 '16 at 00:08
  • Thanks for you comment ebullient. The server is being started in eclipse version Juno in my Windows development system. The application is web application with ejb in it. I will have the question updated in a few minutes with information on server configuration. – user2891264 Mar 23 '16 at 14:18
  • the detailed trace does not help here, and isn't relevant to the problem. You start the server with eclipse, do you then close eclipse? Starting the server with eclipse effectively runs it in the foreground. There is no reason at all to run LIberty as an administrator, it is not something I would recommend, in fact. Check the file permissions first (make all files owned by a normal user), and then please try starting the server from the command line. It would also be helpful to know what version of Liberty you're using, and what version of WDT (the eclipse tools) you're using. – ebullient Mar 24 '16 at 14:22
  • I did not close the eclipse. Starting the server from the command line, the server doesn't get shutdown, but i need it working in eclipse. Liberty version i have is 8.5.5. WebSphere® Application Server V8.5 Liberty Profile Tools ( 8.5.5022.v20151126_2246), Web Development Tools (8.5.5022.v20151126_2246) – user2891264 Mar 24 '16 at 15:40
  • starting server in eclipse without any app gives same result – user2891264 Mar 24 '16 at 16:02

1 Answers1

0

A couple of things to check -- Do you have application code that is calling System.exit? Are you starting the server without using nohup and then exiting the shell?

Brent Daniel
  • 355
  • 1
  • 4
  • Thanks Brent for your reply, there is no application code calling System.exit(). I am starting the server from eclipse as an administrator. I have added some more information on server configuration in the question. – user2891264 Mar 23 '16 at 14:41