question

Babar Q. avatar image
Babar Q. asked ·

User Tag from Cookie Value

Dear All,

We are trying to get a user tag from the cookie and for that purpose we found the name (loginid=) in the cookie and wrote a regex (loginid.(.?\d+)) for the cleanup rule but even though anonymous user sessions are appearing.

Below screenshots are for the reference to configuration.

Regards,

Babar

Dynatrace Manageduser session monitoringuser tagging
user-tag.jpg (36.3 KiB)
cleanup-rule.jpg (15.8 KiB)
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

Alexander S. avatar image
Alexander S. answered ·
Hi,

  • The IP address masking is enabled by default since May 2018: https://www.dynatrace.com/news/blog/new-privacy-se...
  • Live user sessions should typically not last longer than 5 minutes till they show up in the user session view. If you see it often that live sessions needs longer than 5 minutes, please create a support ticket.
  • Regarding the persistent cookie: The persistent cookie is only used to detect returning users. The user session cookie is only a session cookie. That means, user using the same browser on the same device will reuse persistent cookie. Therefore Dynatrace can tell you that this user has logged in 10 times from the same device, 5 times with user tag X, 4 times anonymous and 1 time with user tag Y.
    If you want to end a session before the 30 minutes timeout or before the user closes the browser, you can implement an JS API call: dtrum.endSession(); But be aware that we still have the same device cookie information. For applications like an info terminal, the persistent cookie functionality should be disabled.
Alex



3 comments Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

Hello @Alexander S.

Thank you for your comments. During POC we disabled the persistent cookie but encountered with a strange situation.

In the below screenshot a live session has an IP address with a user tag.

In the same session, there are multiple user tags with different IDs.

What can be the issue?

Regards,

Babar

0 Likes 0 · ·

@Babar Q. Hi.. were you able to find out way out for the above issue ? Even am facing the same issue for one of the web application. I can see multiple user tagging under one user session, also there IP addresses and browser family, versions are different, still the users are merged under one user session.

img-20190215-wa0005.jpg

0 Likes 0 · ·

Hello @Pallavi V.

Thank you for your information.

Can you please share the steps with me taken to resolve the issue?

Regards,

Babar

0 Likes 0 · ·
Julius L. avatar image
Julius L. answered ·

Also depends if you use persistent cookies to identify recurring users or not. In this case, you can see some sessions as anonymous (on the main screen), but they have user tag assigned. Since their first session was initiated and completed before you have set the userTag extraction from cookie values.

Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

Babar Q. avatar image
Babar Q. answered ·

Hello @sebastian k.

Once again three points to discuss about User Tag.

  1. After starting a new session, I can see the appearance of new session in User Sessions and also Analyze User Session for a particular application but within sometime few seconds that session will be no longer in both locations.
  2. I cleared my browser's cookie number of times but even though an anonymous session instead of tag/loginid.
  3. The same behavior I can see for few more users.

What can be the reasons behind?

Regards,

Babar

4 comments Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

  1. You are saying that user session disappears for you? Any filters, management zone?
  2. Actually session should be tagged properly without clearing cookies. You don't see user tags at all?
  3. So this is not for all of them but for some part only?

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

No, without any filtration.

I see the tags for some other people but not mine and it always shows anonymous even after clearing the cookies (just to exhaust the option).

Yes many of them have user tags.

Regards,

Babar

0 Likes 0 · ·

All users are using the same browser (type, version)? Are you sure that you have in your cookies proper value?

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

As per my understanding cookie value and clean up rule is correct, therefore, user ID is capturing for few of them.

I tried with the IE, Chrome, Firefox but no tagging even some people have the same OS and Browser version like me and user tag is working for them.

Regards,

Babar

0 Likes 0 · ·
Babar Q. avatar image
Babar Q. answered ·

Hello @sebastian k. and @Julius L.

Thank you for your answers. Now the user tagging is working because = sign in the cookie value was additional.

Two more following things wanted to ask.

  • As per the documentation "Due to the 30-min timeout, finished user sessions don't immediately appear in User sessions view. Finished sessions appear only after 30 minutes." What about live sessions? I have done a complete practice session and even after many minutes past, my session is not appearing in the form of user tag or anonymous.
  • Secondly, public and private IP addresses are capturing in the form of subset instead of an IP address e.g. 82.212.85.0 & 10.50.81.0

Regards,

Babar

24 comments Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

  1. Generally your session should tag if it is life session that is still in use. I've made many experiments on clients environment when I was looking for place to get tag from cookie or css element and it was working almost immediately for live sessions. I think it will show in user sessions as finished after 30 minutes.
  2. Could you share screen?
0 Likes 0 · ·

Hello @sebastian k.

Persistent cookie for user tracking is enabled and I found that my new session joined the existing anonymous completed session. Why?

Regards,

Babar

0 Likes 0 · ·

Dynatrace detects cookie that has been left in your browser I think. There is also possibility to have multiple user tags in the same session when somebody will logout and login to different user without closing browser os clearing cookies.

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

This make sense but in this situation we are going to have following situations:

  • How to tell users to clear browser cookies
  • Number of sessions will be less than the actual count
  • Successfully logged-in conversion goal will also impact

Regards,

Babar

0 Likes 0 · ·

Does your users all using the same computer and browser? If yes they can work in incognito mode but it is only workaround.

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

It is an e-channel application and used by 1000 of unique users.

Regards,

Babar

0 Likes 0 · ·

So if they are using different computers there should be no problem.

Sebastian

0 Likes 0 · ·

Hello @sebastian k. and @Julius L.

Any thoughts about the below situation?

Public and private IP addresses are capturing in the form of subset instead of an IP address e.g. 82.212.85.0 & 10.50.81.0

Regards,

Babar

0 Likes 0 · ·

Can you show screen? I'm not sure if I understand it correctly.

0 Likes 0 · ·

Hello @sebastian k.

In the below screenshot you can see that IP address captured as a subnet instead of a unique IP address.

Regards,

Babar

0 Likes 0 · ·
session-details.jpg (24.8 KiB)

Question... if you go from user action to purepath, there you also have client IP address. Is it the same?

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

Are you talking about below information?

Regards,

Babar

0 Likes 0 · ·
subnet.jpg (20.8 KiB)

Click on one of user actions => Waterfall analysis => Purepath and check in purepath details IP cought on WebServer.

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

I tried few user actions but could not find the IP address.

Regards,

Babar

0 Likes 0 · ·

I mean this place

0 Likes 0 · ·

Hello @sebastian k.

Yes. The metadata also has the subnet instead of a unique IP address.

Regards,

Babar

0 Likes 0 · ·
metadata.png (4.7 KiB)

Strange... @Babar Q. you have not easy task with this POC i think. Maybe open support ticket for this because actually I have no idea why it happens like this. But there must be some reason in configuration of environment that it is behaving like this.

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

Thank you for all your passions :)

I will open a support case and will make sure to update the post in case they can understand and resolve the situation.

Regards,

Babar

1 Like 1 · ·

I've found something in settings:

you can setup from what place Dynatrace will collect IP. (Web & mobile monitoring settings)

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

Thank you for your continues effort with me to understand the situation. Below screenshot is from the AppMon for determining the client IP address and the same headers I can see in your shared screenshot (on my side this is also the same). Unique IP addresses are available for the ApppMon but not for Dynatrace. Maybe the same header with different sequence will work for Dynatrace.

Regards,

Babar

0 Likes 0 · ·

Ok when you will find out what is wrong give me an update. It can be good case for future :)

0 Likes 0 · ·

Hello @sebastian k.

I just disabled the highlighted default enabled settings and expecting to see the unique IP addresses :)

Regards,

Babar

1 Like 1 · ·

Cool one issue less on the list :D But actually this setting is not active by default. So maybe you've switched it accidentally :)

Sebastian

0 Likes 0 · ·

Hello @sebastian k.

:) Maybe !

Will share the results with you.

Regards,

Babar

0 Likes 0 · ·
Sebastian K. avatar image
Sebastian K. answered ·

Hello Babar,

are you sure that all of those anonymous users has been signed in an have this cookie value? I have never had a problem that value was available and Dynatrace doesn’t detect it. You can always make experiment and disable cleanup rule to check if this help (just experiment)

Sebastian

Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

Space Topics

mobile monitoring dotnet synthetic monitoring reports iis chat kubernetes servicenow amazon web services mysql mainframe rest api errors cassandra dashboard oneagent sdk cmc application monitoring openkit smartscape request attributes monitoring developer community user tagging log monitoring services ufo syntheticadvisory activegate ip addresses auto-detection high five award oracle hyperion webserver uem usql iib test automation license web performance monitoring ios news migration management zones index ibm mq web services notifications sso host monitoring knowledge sharing reports browser monitors java hybris sap vmware maintenance window user action naming javascript appmon ai synthetic classic availability tipstricks automation extensions session replay diagnostic tools permissions davis assistant faq documentation problem detection http monitors server easytravel apdex aws-quickstart network docker tags and metadata cloud foundry google cloud platform synthetic monitoring process groups account usability dynatrace saas gui paas openshift key user actions administration user actions postgresql synthetic locations oneagent security Dynatrace Managed user management custom python technologies mongodb openstack user session monitoring continuous delivery citrix configuration alerting NGINX action naming linux nam installation masking error reporting database mission control jmeter recorder apache mobileapp RUM php threshold azure purepath davis scripting agent aix nodejs android