用户 102 未列出,输出 cat /etc/passwd
root:x:0:0:root:/root:/bin/bash
daemon:x:1:1:daemon:/usr/sbin:/bin/sh
bin:x:2:2:bin:/bin:/bin/sh
sys:x:3:3:sys:/dev:/bin/sh
sync:x:4:65534:sync:/bin:/bin/sync
games:x:5:60:games:/usr/games:/bin/sh
man:x:6:12:man:/var/cache/man:/bin/sh
lp:x:7:7:lp:/var/spool/lpd:/bin/sh
mail:x:8:8:mail:/var/mail:/bin/sh
news:x:9:9:news:/var/spool/news:/bin/sh
uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
proxy:x:13:13:proxy:/bin:/bin/sh
www-data:x:33:33:www-data:/var/www:/bin/sh
backup:x:34:34:backup:/var/backups:/bin/sh
list:x:38:38:Mailing List Manager:/var/list:/bin/sh
irc:x:39:39:ircd:/var/run/ircd:/bin/sh
gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
libuuid:x:100:101::/var/lib/libuuid:/bin/sh
syslog:x:101:103::/home/syslog:/bin/false
messagebus:x:102:105::/var/run/dbus:/bin/false
colord:x:103:108:colord colour management daemon,,,:/var/lib/colord:/bin/false
usbmux:x:108:46:usbmux daemon,,,:/home/usbmux:/bin/false
pulse:x:110:119:PulseAudio daemon,,,:/var/run/pulse:/bin/false
rtkit:x:111:122:RealtimeKit,,,:/proc:/bin/false
hplip:x:113:7:HPLIP system user,,,:/var/run/hplip:/bin/false
saned:x:114:123::/home/saned:/bin/false
off220:x:1000:1000:off220,,,:/home/off220:/bin/bash
gdm:x:104:111:Gnome Display Manager:/var/lib/gdm:/bin/false
但输出显示有一个用户 102
ps aux | grep -v `whoami`
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 1 0.0 0.0 24332 2248 ? Ss 19:43 0:00 /sbin/init
root 2 0.0 0.0 0 0 ? S 19:43 0:00 [kthreadd]
root 3 0.0 0.0 0 0 ? S 19:43 0:00 [ksoftirqd/0]
root 5 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/u:0]
root 6 0.0 0.0 0 0 ? S 19:43 0:00 [migration/0]
root 7 0.0 0.0 0 0 ? S 19:43 0:00 [watchdog/0]
root 8 0.0 0.0 0 0 ? S 19:43 0:00 [migration/1]
root 10 0.0 0.0 0 0 ? S 19:43 0:00 [ksoftirqd/1]
root 11 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/0:1]
root 12 0.0 0.0 0 0 ? S 19:43 0:00 [watchdog/1]
root 13 0.0 0.0 0 0 ? S 19:43 0:00 [migration/2]
root 14 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/2:0]
root 15 0.0 0.0 0 0 ? S 19:43 0:00 [ksoftirqd/2]
root 16 0.0 0.0 0 0 ? S 19:43 0:00 [watchdog/2]
root 17 0.0 0.0 0 0 ? S 19:43 0:00 [migration/3]
root 18 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/3:0]
root 19 0.0 0.0 0 0 ? S 19:43 0:00 [ksoftirqd/3]
root 20 0.0 0.0 0 0 ? S 19:43 0:00 [watchdog/3]
root 21 0.0 0.0 0 0 ? S< 19:43 0:00 [cpuset]
root 22 0.0 0.0 0 0 ? S< 19:43 0:00 [khelper]
root 23 0.0 0.0 0 0 ? S 19:43 0:00 [kdevtmpfs]
root 24 0.0 0.0 0 0 ? S< 19:43 0:00 [netns]
root 26 0.0 0.0 0 0 ? S 19:43 0:00 [sync_supers]
root 27 0.0 0.0 0 0 ? S 19:43 0:00 [bdi-default]
root 28 0.0 0.0 0 0 ? S< 19:43 0:00 [kintegrityd]
root 29 0.0 0.0 0 0 ? S< 19:43 0:00 [kblockd]
root 30 0.0 0.0 0 0 ? S< 19:43 0:00 [ata_sff]
root 31 0.0 0.0 0 0 ? S 19:43 0:00 [khubd]
root 32 0.0 0.0 0 0 ? S< 19:43 0:00 [md]
root 34 0.0 0.0 0 0 ? S 19:43 0:00 [khungtaskd]
root 35 0.0 0.0 0 0 ? S 19:43 0:00 [kswapd0]
root 36 0.0 0.0 0 0 ? SN 19:43 0:00 [ksmd]
root 37 0.0 0.0 0 0 ? SN 19:43 0:00 [khugepaged]
root 38 0.0 0.0 0 0 ? S 19:43 0:00 [fsnotify_mark]
root 39 0.0 0.0 0 0 ? S 19:43 0:00 [ecryptfs-kthrea]
root 40 0.0 0.0 0 0 ? S< 19:43 0:00 [crypto]
root 48 0.0 0.0 0 0 ? S< 19:43 0:00 [kthrotld]
root 49 0.0 0.0 0 0 ? S 19:43 0:00 [scsi_eh_0]
root 50 0.0 0.0 0 0 ? S 19:43 0:00 [scsi_eh_1]
root 52 0.0 0.0 0 0 ? S 19:43 0:00 [scsi_eh_2]
root 53 0.0 0.0 0 0 ? S 19:43 0:00 [scsi_eh_3]
root 54 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/u:3]
root 75 0.0 0.0 0 0 ? S< 19:43 0:00 [devfreq_wq]
root 76 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/0:2]
root 77 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/1:1]
root 273 0.0 0.0 0 0 ? S 19:43 0:00 [jbd2/sda3-8]
root 274 0.0 0.0 0 0 ? S< 19:43 0:00 [ext4-dio-unwrit]
root 354 0.0 0.0 17224 640 ? S 19:43 0:00 upstart-udev-bridge --daemon
root 358 0.0 0.0 21828 1584 ? Ss 19:43 0:00 /sbin/udevd --daemon
root 412 0.0 0.0 21784 1152 ? S 19:43 0:00 /sbin/udevd --daemon
root 413 0.0 0.0 21732 1056 ? S 19:43 0:00 /sbin/udevd --daemon
root 463 0.0 0.0 0 0 ? S< 19:43 0:00 [kpsmoused]
root 570 0.0 0.0 0 0 ? S< 19:43 0:00 [hd-audio0]
root 730 0.0 0.0 15180 400 ? S 19:43 0:00 upstart-socket-bridge --daemon
root 748 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/3:2]
root 764 0.0 0.0 0 0 ? S 19:43 0:00 [kworker/1:2]
root 788 0.0 0.0 0 0 ? S 19:43 0:00 [jbd2/sda2-8]
root 789 0.0 0.0 0 0 ? S< 19:43 0:00 [ext4-dio-unwrit]
root 801 0.0 0.0 0 0 ? S 19:43 0:00 [jbd2/sda4-8]
root 802 0.0 0.0 0 0 ? S< 19:43 0:00 [ext4-dio-unwrit]
102 828 0.0 0.0 24744 1884 ? Ss 19:43 0:00 dbus-daemon --system --fork --activation=upstart
syslog 833 0.0 0.0 249464 1548 ? Sl 19:43 0:00 rsyslogd -c5
root 865 0.0 0.0 7256 604 ? Ss 19:43 0:00 dhclient3 -e IF_METRIC=100 -pf /var/run/dhclient.eth0.pid -lf /var/lib/dhcp/dhclient.eth0.leases -1 eth0
root 980 0.0 0.0 17780 904 tty4 Ss+ 19:43 0:00 /sbin/getty -8 38400 tty4
root 982 0.0 0.0 17780 908 tty5 Ss+ 19:43 0:00 /sbin/getty -8 38400 tty5
root 994 0.0 0.0 17780 908 tty2 Ss+ 19:43 0:00 /sbin/getty -8 38400 tty2
root 998 0.0 0.0 17780 904 tty3 Ss+ 19:43 0:00 /sbin/getty -8 38400 tty3
root 1004 0.0 0.0 17780 900 tty6 Ss+ 19:43 0:00 /sbin/getty -8 38400 tty6
root 1015 0.0 0.0 130900 3016 ? Ssl 19:43 0:00 gdm-binary
root 1036 0.0 0.0 144868 4020 ? Sl 19:43 0:00 /usr/lib/gdm/gdm-simple-slave --display-id /org/gnome/DisplayManager/Display1
daemon 1038 0.0 0.0 16900 376 ? Ss 19:43 0:00 atd
root 1039 0.0 0.0 19104 1024 ? Ss 19:43 0:00 cron
root 1130 2.6 0.3 145504 25804 tty7 Ss+ 19:43 2:16 /usr/bin/Xorg :0 -background none -verbose -auth /var/run/gdm/auth-for-gdm-x1heKF/database -nolisten tcp vt7
root 1197 0.0 0.0 0 0 ? S< 19:43 0:00 [iprt]
root 1236 0.5 0.0 20476 4832 ? SNs 19:43 0:29 /usr/sbin/preload -s /var/lib/preload/preload.state
root 2555 0.0 0.0 2091628 3876 ? Sl 19:43 0:00 /usr/sbin/console-kit-daemon --no-daemon
root 2622 0.0 0.0 200352 4032 ? Sl 19:43 0:00 /usr/lib/policykit-1/polkitd --no-debug
root 2649 0.0 0.0 219860 4232 ? Sl 19:43 0:00 /usr/lib/upower/upowerd
rtkit 2792 0.0 0.0 168864 1344 ? SNl 19:43 0:00 /usr/lib/rtkit/rtkit-daemon
root 2805 0.0 0.0 121528 3700 ? Sl 19:43 0:00 /usr/lib/accountsservice/accounts-daemon
root 2813 0.0 0.0 0 0 ? S 19:43 0:00 [flush-8:0]
root 2816 0.0 0.0 17780 908 tty1 Ss+ 19:43 0:00 /sbin/getty -8 38400 tty1
root 2819 0.0 0.0 180348 3992 ? Sl 19:44 0:00 /usr/lib/gdm/gdm-session-worker
root 4081 0.0 0.0 193364 3856 ? Sl 19:44 0:00 /usr/lib/udisks/udisks-daemon
root 4085 0.0 0.0 45512 804 ? S 19:44 0:00 udisks-daemon: not polling any devices
root 4494 0.0 0.0 0 0 ? S 20:30 0:00 [kworker/2:1]
root 11407 0.0 0.0 112888 3080 ? Sl 19:58 0:00 /usr/sbin/system-tools-backends
root 11410 0.0 0.2 58884 19032 ? S 19:58 0:00 /usr/bin/perl /usr/share/system-tools-backends-2.0/scripts/SystemToolsBackends.pl -m Platform
root 18649 0.2 1.2 569448 96392 ? Sl 19:49 0:10 /usr/sbin/synaptic
root 18659 0.0 0.0 26548 784 ? S 19:49 0:00 dbus-launch --autolaunch=51015c1973c6bd697d07027500000008 --binary-syntax --close-stderr
root 18660 0.0 0.0 23808 696 ? Ss 19:49 0:00 //bin/dbus-daemon --fork --print-pid 5 --print-address 7 --session
这个用户是干什么用的?为什么它没有列在密码中?(抱歉格式化了,无法让它工作)
答案1
如果您仔细查看 /etc/password 文件,您会注意到用户“messagebus”的用户 ID 为 102。因此,您的 ps 显示的是数字用户 ID,而不是用户名,因为它不适合 ps 的默认列宽。截断用户名不是一个选择,因为它会造成混乱。但您可以手动为用户列设置不同的宽度,例如
`ps ax -o pid,user:19,comm`
现在您应该看到用户名变为“messagebus”。顺便说一句,该命令向正确的用户提供了提示:正在运行的命令是“dbus-daemon”,即消息总线守护程序,它启用进程间通信并在系统用户“messagebus”下运行!
答案2
在您的 passwd 文件中,用户是“messagebus”,如下所示:
messagebus:x:102:105::/var/run/dbus:/bin/false
第三个选项是USERID,第四个是GROUPID。
Dbus 是一个用于应用程序相互通信的消息系统。
您可以在这里阅读有关 dbus 守护进程和消息总线的更多信息: