{"id":1357,"date":"2017-09-13T11:06:02","date_gmt":"2017-09-13T16:06:02","guid":{"rendered":"https:\/\/it.thelibrarie.com\/weblog\/?p=1357"},"modified":"2017-09-13T11:06:02","modified_gmt":"2017-09-13T16:06:02","slug":"how-long-has-user-xyz-been-logged-in","status":"publish","type":"post","link":"https:\/\/it.thelibrarie.com\/weblog\/2017\/09\/how-long-has-user-xyz-been-logged-in\/","title":{"rendered":"How Long Has User XYZ Been Logged In"},"content":{"rendered":"<p>And when was the last time they logged into their Exchange mailbox? Very important questions on the Microsoft side of the house.<\/p>\n<p>Currently have an Exchange 2010 server on-prem (soon O365) and several aged accounts that needed to be disabled.<\/p>\n<p>On a Windows machine open a command prompt and type quser.exe. This will show you all of the users currently logged in as well as when they logged in, and any idle time. Especially helpful on the Terminal Services hosts\/RDS machines.<br \/>\n<code> USERNAME              SESSIONNAME        ID  STATE   IDLE TIME  LOGON TIME<\/code><br \/>\n<code>>BSDMAN                console             1  Active      none   9\/8\/2017 7:31 AM<\/code><br \/>\n<code>>ADMIN                 rdp-tcp#0           2  Active      none   9\/11\/2017 11:52 AM<\/code><\/p>\n<p>How about for Mailbox exchange users?<br \/>\n<strong>Open the Exchange Management PowerShell<\/strong><br \/>\n<code>get-mailboxstatistics -server YOUREXSERVERNAME | sort LastLogonTime -Decending<\/code><br \/>\nTo save it to a file just add the <code>> c:\\temp\\ex_last_logon.txt<\/code> to the end.<\/p>\n<p>Profit.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>And when was the last time they logged into their Exchange mailbox? Very important questions on the Microsoft side of the house. Currently have an Exchange 2010 server on-prem (soon O365) and several aged accounts that needed to be disabled. On a Windows machine open a command prompt and type quser.exe. This will show you &hellip; <a href=\"https:\/\/it.thelibrarie.com\/weblog\/2017\/09\/how-long-has-user-xyz-been-logged-in\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">How Long Has User XYZ Been Logged In<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-1357","post","type-post","status-publish","format-standard","hentry","category-microsoft"],"_links":{"self":[{"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/posts\/1357","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/comments?post=1357"}],"version-history":[{"count":1,"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/posts\/1357\/revisions"}],"predecessor-version":[{"id":1358,"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/posts\/1357\/revisions\/1358"}],"wp:attachment":[{"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/media?parent=1357"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/categories?post=1357"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/it.thelibrarie.com\/weblog\/wp-json\/wp\/v2\/tags?post=1357"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}