You can use the occ command to query usr information, like active/inactive/lastseen etc. Additionally this thread might be of interest for you:
In general I recommend to use the search function to find answers on your question first, because most questions have already been asked and answered in the past