Linux user creation date

370 pts.
Tags:
Linux
Dear Linux experts, I used ls -ld /home/user_name to get user creation date. why I can't get the creation year of some of the user ID I want to extract. Example:
1. ls -ld /home/user1 => .... mm dd yyyy .....
2. ls -ld /home/user2 => .... mm dd yyyy .......
3. ls -ld /home/user2 => .... mm dd hh:mm .......
Question: I don't know what wrong with my #3 user. It doesn't show the creation year. Please help me. Thank you!
0

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Discuss This Question: 2  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • TheRealRaven
    The most common UNIX/Linux date format will leave the year out when it matches the current year and is 'recent'. So there's probably nothing wrong with your user3. Reading the documentation for ls would tell you how it works.

    From the ls docs:
    By default, file timestamps are listed in abbreviated form, using a
    date like `Mar 30  2002' for non-recent timestamps, and a
    date-without-year and time like `Mar 30 23:45' for recent timestamps.
    This format can change depending on the current locale as detailed
    below.
    
       A timestamp is considered to be "recent" if it is less than six
    months old, and is not dated in the future.  If a timestamp dated today
    is not listed in recent form, the timestamp is in the future, which
    means you probably have clock skew problems which may break programs
    like `make' that rely on file timestamps.
    

    36,370 pointsBadges:
    report
  • srithea
    Thanks @TheRealRaven.
    370 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: