Do you mean you want to find the last login user id other than the Discovery user?
As you can see, I'm really starting to dig into Discovery!
Yes, that is correct. When Discovery scans a host, such as a windows laptop as an example. Is there a way to also find out who is either clogged in, or who 'last logged in? We are looking to collect this type of information so we can help validate the owner of a system, for tracking and auditing purposes.
2 of 2 people found this helpful
Finding the "Owner" of a server or desktop isn't something done OOTB by Discovery.
You would need to write a custom pattern to find and add the information as a new attribute to the Host.
And, if you want that new attribute to appear in the CMDB, then you write a custom syncmapping to put it into the CMDB.
Here is a KA about the topic: Does Discovery retrieve the 'Last Login User' & 'Last Login Time' from the Operating Systems which are discovered?
And, if you search the community, you will see other customers have asked questions and provided answers about the problem.
There is a TPL attached on this posting: Retrieve Last login from Discovery
This is great info and I have found the TPL code, thanks to your help. I was able to successfully upload it, too. However, how do I query Discovery to show me the results (so to speak)?
1 of 1 people found this helpful
The patterns in that post add an attribute to the host node. So if the pattern has been run on a host and data returned, you should see a new attribute appear when viewing the host node view under the 'Other' section.
Alternatively you can just run a query for the new attribute, something like:
search Host where os_class = 'Windows'
show name, last_logged_on_users