0

We recently deployed an IS-KM cluster working with AM cluster. We allocate it on AWS instances, and we installed and configured it, following the documetation available on WSO2 official site.

The issue that we are experiencing now, is related with cookie session and IS carbon console. We use ALB to expose IS-KM nodes to internet. We enabled sticky session property on Target Group because it is a must during the configuration of WSO2 IS-KM on HA. If we have both instances actives on the Target Group (ALB should balance traffic between them) we cannot login to carbon console, we are always been redirected to login.

We checked IS-KM wso2carbon.log during this issue:

TID: [-1234] [] [2020-04-23 08:58:14,215] [9bab1156-3c57-4fdc-876e-c0edf46d4ed5] INFO {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - '[email protected] [-1234]' logged in at [2020-04-23 08:58:14,215-0300]

This log appears on each node at each login retry that we made. Also we notice that both servers are reciving requests during the login as can se below:

Node 1 logs:

ALB IP - - [23/Apr/2020:09:03:07 -0300] GET /carbon/admin/index.jsp?loginStatus=true&loginStatus=true&loginStatus=true&loginStatus=true&loginStatus=true&loginStatus=true&loginStatus=true HTTP/1.1 302 - https://domain-name/carbon/admin/login.jsp Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0 0.001
ALB IP - - [23/Apr/2020:09:03:08 -0300] GET /carbon/admin/js/csrfPrevention.js HTTP/1.1 200 4382 https://domain-name/carbon/admin/login.jsp Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0 0.002

Node 2 logs:

ALB IP - - [23/Apr/2020:09:03:07 -0300] POST /carbon/admin/login_action.jsp HTTP/1.1 302 - https://domain-name/carbon/admin/login.jsp Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0 0.062
ALB IP - - [23/Apr/2020:09:03:07 -0300] GET /carbon/admin/login.jsp HTTP/1.1 200 3431 https://domain-name/carbon/admin/login.jsp Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0 0.003
ALB IP - - [23/Apr/2020:09:03:08 -0300] POST /carbon/admin/js/csrfPrevention.js HTTP/1.1 200 52 https://domain-name/carbon/admin/login.jsp Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0 0.001

As logs show, requests are being sent to different node during the login. If we just put one node on target group, everything goes fantastic.

So the question is, why enabled sticky session is not working correctly? Maybe can be some issue on the IS-KM configuration that is caused that behavior?

1 Answer 1

1

I had a missconfiguration on AWS ALB side. I configured sticky session on listener, but I had to configure it on Target group. After configured it on target group, it works like a charm!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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