|
51 | 51 |
|
52 | 52 | ```bash
|
53 | 53 | $ group
|
54 |
| - sj: sj, adm, cdrom, sudo, dip, plugdev, lpadmin, lxd, sambashare |
| 54 | + pavankumar: pavankumar, adm, cdrom, sudo, dip, plugdev, lpadmin, lxd, sambashare |
55 | 55 | ```
|
56 | 56 |
|
57 | 57 | 5. **finger:** Used to check the information of any currently logged in users. i.e, It displays users login time, tty (name), idle time, home directory, shell name etc.
|
58 | 58 |
|
59 | 59 | ```bash
|
60 | 60 | $ finger
|
61 |
| - Login Name Tty Idle Login Time Office Office Phone |
62 |
| - sj sj *:0 Mar 29 01:27 (:0) |
| 61 | + Login Name Tty Idle Login Time Office Office Phone |
| 62 | + pavankumar pavankumar *:0 Mar 29 01:27 (:0) |
63 | 63 | ```
|
64 | 64 |
|
65 | 65 | This may not be available by default in many linux machines. In this case, you need to install it manually.
|
|
71 | 71 |
|
72 | 72 | ```bash
|
73 | 73 | $ users
|
74 |
| - sj |
| 74 | + pavankumar |
75 | 75 | ```
|
76 | 76 |
|
77 | 77 | 7. **grep:** It is a powerful pattern searching tool to find information about a specific user from the system accounts file: /etc/passwd.
|
|
89 | 89 | Example:
|
90 | 90 | w
|
91 | 91 | 18:45:04 up 2:09, 1 user, load average: 0.09, 0.07, 0.02
|
92 |
| - USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT |
93 |
| - sj :0 :0 01:27 ?xdm? 1:14 0.01s /usr/lib/gdm3/g |
| 92 | + USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT |
| 93 | + pavankumar :0 :0 01:27 ?xdm? 1:14 0.01s /usr/lib/gdm3/g |
94 | 94 | ```
|
95 | 95 |
|
96 | 96 | 9. **last or lastb:** Displays a list of last logged in users on the system. You can pass user names to display their login and hostname details.
|
|
101 | 101 | Example:
|
102 | 102 |
|
103 | 103 | last
|
104 |
| - sj :0 :0 Fri Aug 28 01:27 gone - no logout |
| 104 | + pavankumar :0 :0 Fri Aug 28 01:27 gone - no logout |
105 | 105 | reboot system boot 5.4.0-29-generic Fri Aug 28 01:27 still running
|
106 |
| - sj :0 :0 Wed Jul 29 11:46 - crash (29+13:40) |
| 106 | + pavankumar :0 :0 Wed Jul 29 11:46 - crash (29+13:40) |
107 | 107 | reboot system boot 5.4.0-29-generic Wed Jul 29 11:45 still running
|
108 |
| - sj :0 :0 Thu May 14 21:04 - crash (75+14:41) |
| 108 | + pavankumar :0 :0 Thu May 14 21:04 - crash (75+14:41) |
109 | 109 | reboot system boot 5.4.0-29-generic Thu May 14 21:03 still running
|
110 | 110 |
|
111 | 111 | wtmp begins Sun Jan 28 21:03:56 2024
|
|
0 commit comments