IT Operations Discussions
All the up-time. All the nines.

query to know who has logged in the server

risingflight143
Explorer

Hi All

i am new to splunk, I have a server with hostname server01 and i want to know who has logged in to the server in last 1 month. the event id is 4624 for successfully login, how can i use splunk query to fetch the information for last logged in user .

0 Karma

manjunathmeti
Champion

hi @risingflight143,

You need to provide sample data. You can use this sample query:

index=indexname sourcetype=sourcetypename eventid_fieldname=4624 earliest=-1mon
| fields  userfield, logintime, other_fields_you_need
| stats latest(_time) as _time, latest(*) as * by userfield
0 Karma
Get Updates on the Splunk Community!

Splunk Enterprise Security 8.x: The Essential Upgrade for Threat Detection, ...

 Prepare to elevate your security operations with the powerful upgrade to Splunk Enterprise Security 8.x! This ...

Get Early Access to AI Playbook Authoring: Apply for the Alpha Private Preview ...

Passionate about security automation? Apply now to our AI Playbook Authoring Alpha private preview ...

Reduce and Transform Your Firewall Data with Splunk Data Management

Managing high-volume firewall data has always been a challenge. Noisy events and verbose traffic logs often ...