LATEST VERSION: 8.2.7 - CHANGELOG
Pivotal GemFire® v8.2

Session State Log Files

Session State Log Files

Several log files are written by the various parts of the session management code.

  • catalina.log. Log file written by the tc server
  • cacheserver.log. Log file written by the GemFire server process.
  • gemfire_modules.log. Log file written by the GemFire cache client.

Adding FINE Debug Logging to catalina.log

To add GemFire-specific FINE logging to the catalina.log file, perform the following steps:
  1. Add the following lines to your logging.properties file:
    com.gemstone.gemfire.modules.session.catalina.DeltaSessionManager.level = FINE
    com.gemstone.gemfire.modules.session.catalina.DeltaSession.level = FINE
    
  2. Add the following line to the tc Server startup properties:
    -Djava.util.logging.config.file=/path/to/logging.properties
    where /path/to/logging.properties corresponds to the location of the logging.properties file that you configured in step 1.
These configurations will add FINE logging to the catalina.DATE.log file. The following is an example of FINE logging:
06-Sep-2011 15:59:47.250 FINE com.gemstone.gemfire.modules.session.catalina.DeltaSessionManager.start 
DeltaSessionManager[container=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/manager]; 
regionName=gemfire_modules_sessions; regionAttributesId=PARTITION_REDUNDANT]: Starting

06-Sep-2011 15:59:47.254 FINE com.gemstone.gemfire.modules.session.catalina.DeltaSessionManager.registerJvmRouteBinderValve 
DeltaSessionManager[container=StandardEngine[Catalina].StandardHost[localhost].StandardContext[/manager]; 
regionName=gemfire_modules_sessions; regionAttributesId=PARTITION_REDUNDANT]: Registering JVM route binder valve

06-Sep-2011 15:59:47.351 FINE com.gemstone.gemfire.modules.session.catalina.ClientServerSessionCache.createOrRetrieveRegion 
Created session region: com.gemstone.gemfire.internal.cache.LocalRegion[path='/gemfire_modules_sessions';
scope=LOCAL';dataPolicy=EMPTY; gatewayEnabled=false]

Add Session State Logging to server.log

To add session-state-specific logging to the server.log file, add the following property to the catalina.properties file for the tc Server instance:
gemfire-cs.enable.debug.listener=true
Adding this configuration will print logging in the server.log such as the following:
[info 2011/09/06 15:18:27.749 PDT  <ServerConnection on port 40404 Thread 3> tid=0x32] DebugCacheListener: Received 
CREATE for key=5782ED83A3D9F101BBF8D851CE4E798E; value=DeltaSession[id=5782ED83A3D9F101BBF8D851CE4E798E; 
sessionRegionName=gemfire_modules_sessions; operatingRegionName=unset]

[info 2011/09/06 15:18:27.769 PDT  <ServerConnection on port 40404 Thread 3> tid=0x32] DebugCacheListener: Received UPDATE 
for key=5782ED83A3D9F101BBF8D851CE4E798E; value=DeltaSession[id=5782ED83A3D9F101BBF8D851CE4E798E; 
sessionRegionName=gemfire_modules_sessions; operatingRegionName=unset]

[info 2011/09/06 15:19:36.729 PDT  <Timer-2> tid=0x24] DebugCacheListener: Received EXPIRE_DESTROY for 
key=5782ED83A3D9F101BBF8D851CE4E798E

Add Debug Logging to server.log

To add fine-level logging to the GemFire cache server, add the 'log-level' property to the server process. For example:
gfsh> start --name=server1 --cache-xml-file=../conf/cache-server.xml --log-level=fine

This will add fine-level logging to the server.log file.

Note: This will help debug GemFire server issues, but it adds a lot of logging to the file.

Add Debug Logging to gemfire_modules.log

To add fine-level logging to the GemFire Cache Client, add the 'log-level' property to the Listener element in the tc Server of Tomcat server.xml file. For example:
<Listener log-level="fine" 
cache-xml-file="${gemfire-cs.cache.configuration.file}" 
className="com.gemstone.gemfire.modules.session.catalina.ClientServerCacheLifecycleListener"
criticalHeapPercentage="${gemfire-cs.critical.heap.percentage}"
evictionHeapPercentage="${gemfire-cs.eviction.heap.percentage}"
log-file="${gemfire-cs.log.file}"
statistic-archive-file="${gemfire-cs.statistic.archive.file}"
statistic-sampling-enabled="${gemfire-cs.statistic.sampling.enabled}"/>
		

This will add fine-level logging to the file defined by the ${gemfire-cs.log.file} property. The default log file name is gemfire_modules.log.

Note: This will help debug GemFire client issues, but it adds a lot of logging to the file.