首页 > 其他 > 详细

finger

时间:2018-11-14 16:19:53      阅读:135      评论:0      收藏:0      [点我收藏+]

finger

finger命令用于查找并显示用户信息。包括本地与远端主机的用户皆可,帐号名称没有大小写的差别。单独执行finger指令,它会显示本地主机现在所有的用户的登陆信息,包括帐号名称,真实姓名,登入终端机,闲置时间,登入时间以及地址和电话。

语法

finger(选项)(参数)

选项

-l:列出该用户的帐号名称,真实姓名,用户专属目录,登入所用的Shell,登入时间,转信地址,电子邮件状态,还有计划文件和方案文件内容;
-m:排除查找用户的真实姓名;
-s:列出该用户的帐号名称,真实姓名,登入终端机,闲置时间,登入时间以及地址和电话;
-p:列出该用户的帐号名称,真实姓名,用户专属目录,登入所用的Shell,登入时间,转信地址,电子邮件状态,但不显示该用户的计划文件和方案文件内容。

实例

 

列出当前登录用户的相关信息

# finger -l //显示用户信息
Login: root Name: root
Directory: /root Shell: /bin/bash
On since Fri Apr 9 20:17 (CST) on :0 (messages off)
On since Fri Apr 9 20:17 (CST) on pts/1 32 days 22 hours idle
On since Fri Apr 9 20:17 (CST) on pts/3 4 hours 5 minutes idle
(messages off)
On since Wed May 12 18:08 (CST) on pts/4 from 192.168.1.10
On since Wed May 12 18:35 (CST) on pts/5 from 192.168.1.10
7 minutes 54 seconds idle
On since Wed May 12 14:37 (CST) on pts/2 from 192.168.1.10
3 hours 14 minutes idle
On since Wed May 12 14:53 (CST) on pts/7 34 minutes 25 seconds idle
(messages off)
On since Wed May 12 16:53 (CST) on pts/8 from 192.168.1.10
30 minutes 18 seconds idle
Mail last read Mon Mar 31 04:02 2008 (CST)
No Plan.

显示指定用户信息

# finger -m abc

显示远程用户信息

# finger -m root@192.168.1.13

查询本机管理员的资料

finger root

其结果如下:

Login: root Name: root
Directory: /root Shell: /bin/bash
Never logged in.
No mail.
No Plan.

 

finger

原文:https://www.cnblogs.com/jianlibao/p/9958330.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!