本文共 1744 字,大约阅读时间需要 5 分钟。
查看组信息:[root@localhost soft]# cat /etc/group
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | [root@localhost soft] # cat /etc/group root:x:0: bin:x:1:bin,daemon daemon:x:2:bin,daemon sys:x:3:bin,adm adm:x:4:adm,daemon tty :x:5: disk:x:6: lp:x:7:daemon mem:x:8: kmem:x:9: wheel:x:10: mail:x:12:mail,postfix uucp:x:14: man :x:15: games:x:20: gopher:x:30: video:x:39: dip:x:40: ftp :x:50: lock:x:54: audio:x:63: nobody:x:99: users :x:100: dbus:x:81: usbmuxd:x:113: utmp:x:22: utempter:x:35: desktop_admin_r:x:499: desktop_user_r:x:498: floppy:x:19: vcsa:x:69: rpc:x:32: rtkit:x:497: avahi-autoipd:x:170: abrt:x:173: cdrom:x:11: tape:x:33: dialout:x:18: wbpriv:x:88: rpcuser:x:29: nfsnobody:x:65534: haldaemon:x:68:haldaemon gdm:x:42: ntp:x:38: apache:x:48: saslauth:x:76: postdrop:x:90: postfix:x:89: pulse:x:496: pulse-access:x:495: fuse:x:494: stapusr:x:156: stapsys:x:157: stapdev:x:158: sshd:x:74: tcpdump:x:72: slocate:x:21: qiang:x:500: mysql:x:27: |
查看当前活跃的用户列表:[root@localhost soft]# w
1 2 3 4 5 | [root@localhost soft] # w 16:56:50 up 13 min, 2 users , load average: 0.00, 0.07, 0.08 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT root tty1 :0 16:48 13:18 4.34s 4.34s /usr/bin/Xorg :0 -nr -verb root pts /0 192.168.1.101 16:52 0.00s 0.27s 0.11s w |
1 | [root@localhost soft] # cat /etc/passwd|grep -v nologin|grep -v halt|grep -v shutdown|awk -F":" '{ print $1"|"$3"|"$4 }'|more |
1 2 3 4 5 | [root@localhost soft] # cat /etc/passwd|grep -v nologin|grep -v halt|grep -v shutdown|awk -F":" '{ print $1"|"$3"|"$4 }'|more root|0|0 sync |5|0 qiang|500|500 mysql|27|27 |
本文转自 梦朝思夕 51CTO博客,原文链接:http://blog.51cto.com/qiangmzsx/1367397
转载地址:http://ywfkl.baihongyu.com/