?
Solved

Last Logon field is blank in Active Directory CSVDE Export

Posted on 2014-09-30
3
Medium Priority
?
1,496 Views
Last Modified: 2014-10-06
Hi All,

I have a quick question surrounding an Active Directory export that I have been given from a customer's AD environment.

In quite a few records the lastLogon field is empty but the pwdlastset date has a recent entry.

I dont understand how the lastlogon is blank when there is an entry in the pwdlast set field

Would anyone have any ideas?

TJ
0
Comment
Question by:tjoconnor
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 8

Expert Comment

by:Acosta Technology Services
ID: 40352063
It's likely a problem with the script used to perform the export.  I would try the following and see if some of those "blank" users come back with lastlogon results:

get-aduser -filter * -properties lastLogonTimestamp | select name, lastLogonTimestamp |export-csv "output.csv"
0
 

Author Comment

by:tjoconnor
ID: 40352125
Hi Operationnos, thanks for your reply.

Below is the command I used. I believe you are using lastLogonTimestamp whereas I used LastLogon. Would that be the potential reason for this, as I recently learned that 'lastLogonTimestamp' is replicated among all DC's and 'LastLogon' is only present on the DC that you authenticate with.

But ultimately is there a reason why the lastlogon would be blank and pwdlastset would be populated?

CSVDE -f adexport.csv -r objectClass=computer -l DN,cn,objectClass,lastLogon,pwdLastSet,userAccountControl,operatingSystem,operatingSystemVersion,description –u
0
 
LVL 8

Accepted Solution

by:
Acosta Technology Services earned 2000 total points
ID: 40352132
I believe you are right on the money.  "pwdlastset" would be available from all DC's, while "lastlogon" would only show the results from the DC that the user was authenticated against.  Using "lastlogontimestamp" should provide you the information you're looking for.  Another option would be to query all DC's for "lastlogon" and then merge the data into a single file; using that data you would also have logon location.
0

Featured Post

Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Sometimes clients can lose connectivity with the Lotus Notes Domino Server, but there's not always an obvious answer as to why it happens.   Read this article to follow one of the first experiences I had with Lotus Notes on a client's machine, my…
This article provides a convenient collection of links to Microsoft provided Security Patches for operating systems that have reached their End of Life support cycle. Included operating systems covered by this article are Windows XP,  Windows Server…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Suggested Courses

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question