How to log out all users?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-12-2024 01:51 PM
Does anyone know of a way to end all user sessions so that users need to sign in again?
There is a module for Logged In Users, however this only shows users on the same node as me.
I'm aware of a way to log out an individual via script with GlideSessions.lockOutSessionsInAllNodes(user_record), but where can I get a list of currently signed in users if the module only shows those that are on my node?
I would appreciate any input on this task!
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2024 03:40 AM - edited 06-13-2024 04:05 AM
Hi @MarkD ,
I found a couple of KB articles on User analytics and Logged in Users tracking.
Running the following query on sys_user_list will return all active users
https://.service-now.com/sys_user_session_list.do?sysparm_query=nameISNOTEMPTY%5EinvalidatedISEMPTY&sysparm_view=
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0749943
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0864619
If my answer helped in any way, please mark it as ✅Correct & 👍Helpful
Thanks,
Mahathi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2024 03:56 AM
Hi @MarkD,
This table will let you the same "v_user_session" Open record and there you will get the Lock Out Session button then click on it then session will get terminated.
Please accept my solution if it resolves your issue and thumps up.
Thanks
Jitendra
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2024 07:56 AM
Hi Jitendra, v_user_session is the same table that the Logged In Users module directs to.
It does not display users on other nodes.