Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We are running a WebLogic 10.3.4 cluster with three managed servers (nodes). We do not use session stickyness, but session replication across the cluster and everything is working fine. When trying to test our web application however, we regularly try to figure out on which node the user currently is (in order to find the correct log files).

The JSESSIONID cookie has the format:

sessionid!primary_server_id!secondary_server_id

as specified in the official WLS Cluster Documentation.

Is there any way to determine the current cluster node given the server IDs from the session cookie?

I know there are alternatives like * log aggregation * rendering a hash inside our page templates which allows identification and possibly others. But I would like to find a minimally invasive solution if possible since any change in software setup and application code may prove difficult.

share|improve this question

1 Answer 1

up vote 0 down vote accepted

Not directly in Weblogic, AFAIK.

If you have an Apache web server (or a similar proxy) fronting the Weblogic cluster, it does log the individual server HASH and map it to the Managed server, and is able to send it to the same weblogic managed server as the previous request.

Example from http://www.bea-weblogic.com/weblogic-server-support-pattern-common-diagnostic-process-for-proxy-plug-in-problems.html

Mon May 10 13:14:40 2004 getpreferredServersFromCookie: -2032354160!-457294087
Mon May 10 13:14:40 2004 GET Primary JVMID1: -2032354160
Mon May 10 13:14:40 2004 GET Secondary JVMID2: -457294087
Mon May 10 13:14:40 2004 [Found Primary]: 172.18.137.50:38625:65535
Mon May 10 13:14:40 2004 list[0].jvmid: -2032354160
Mon May 10 13:14:40 2004 secondary str: -457294087
Mon May 10 13:14:40 2004 list[1].jvmid: -457294087
Mon May 10 13:14:40 2004 secondary str: -457294087
Mon May 10 13:14:40 2004 [Found Secondary]: 172.18.137.54:38625:65535
Mon May 10 13:14:40 2004 Found 2 servers
share|improve this answer
    
While I did not have the oppotunity to test this, it is exactly what I have been looking for. We are using Apache with the WLS module as fronting proxy. Thanks! –  Axel Knauf Mar 2 '12 at 9:23

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.