Linux+ QOTW 10-24-05

Discussion in 'Linux+' started by tripwire45, Oct 24, 2005.

  1. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    180
    287
    What command can you use to see a list of users on the Linux system and determine if the user has ever logged in and if so, the date and time of the last login?

    1. usermod
    2. userlog
    3. login
    4. loglast
    5. lastlog

    Answer at the end of the week.
     
    Certifications: A+ and Network+
  2. Tyler D

    Tyler D Gigabyte Poster

    1,224
    8
    85
    Have not a clue :rolleyes: never used linux :oops:

    Guess at no 2.
     
    Certifications: A+,70-270
    WIP: 70-290
  3. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    180
    287
    Answer time. Correct answer is #5, lastlog. Here's a sample of the output.
    Code:
    jmpyles@tripwire:~$ lastlog | more
    Username         Port     From             Latest
    root             tty1                      Mon Sep 12 07:53:34 -0600 2005
    daemon                                     **Never logged in**
    bin                                        **Never logged in**
    sys                                        **Never logged in**
    sync                                       **Never logged in**
    games                                      **Never logged in**
    man                                        **Never logged in**
    lp                                         **Never logged in**
    mail                                       **Never logged in**
    news                                       **Never logged in**
    uucp                                       **Never logged in**
    proxy                                      **Never logged in**
    www-data                                   **Never logged in**
    backup                                     **Never logged in**
    list                                       **Never logged in**
    irc                                        **Never logged in**
    gnats                                      **Never logged in**
    Debian-exim                                **Never logged in**
    jmpyles          :0                        Mon Oct 24 08:13:58 -0600 2005
    identd                                     **Never logged in**
    sshd                                       **Never logged in**
     
    Certifications: A+ and Network+
  4. Boycie
    Honorary Member

    Boycie Senior Beer Tester

    6,281
    85
    174
    I would have gone for 2 as well. What flavour are you using?
     
    Certifications: MCSA 2003, MCDST, A+, N+, CTT+, MCT
  5. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    180
    287
    Debian. Didn't try it on another distro but most Debian commands are pretty usable in other distros. Does this not work in ubuntu?

    EDIT: I just tried #2 on my Debian box. The command is not found for either the generic user or root user.
     
    Certifications: A+ and Network+

Share This Page

Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.