如何查看谁登录了多个工作站?

如何查看谁登录了多个工作站?

在开始创建自己的系统之前,我想找到一个现有的系统来执行以下操作:

  • 提供登录到任何工作站的用户的简明列表
  • 显示工作站主机名、IP 和用户名
  • 数据应经常更新或在发生变化时更新
  • Web 或控制台界面
  • 在 Debian/Squeeze 机器上运行
  • 免费/自由软件

情况:

  • 60 个 Ubuntu 10.04 工作站分布在 3 个站点
  • 通过 20Mbps WAN 连接的站点
  • 每个站点都有一台服务器运行 NFS 和 LDAP
  • 配置为通过 LDAP 验证用户身份的工作站并从本地 NFS 服务器自动安装 home
  • 用户可以登录到任何他们想要的机器

答案1

或许有一些手指守护进程已经提供了您的一些要求。

在我的 Ubuntu 系统上有几个可用的:

$ apt-cache search finger --names-only
finger - user information lookup program
cfingerd - configurable finger daemon
efingerd - Another finger daemon for unix capable of fine-tuning your output.
finger-ldap - Finger for machines that authenticate against LDAP
fingerd - remote user information server
xfingerd - BSD-like finger daemon with qmail support

一些手指命令还提供查询机器信息的可能性。

例如,在设置了 Finger 的 Solaris 网络上:

$ finger juser
Login name: juser                    In real life: Joe User
Directory: /home/juser               Shell: /bin/bash
Login             Name          Idle TTY     Host        When   Where
juser Joe User                  0:03 1   machineA     Wed 20:18 >example.org
juser Joe User                  0:20 17  machineB     Wed 20:11 >example.net
No mail.
Plan:
Do this and that ...

或者获取免费机器列表:

$ finger .free
39 hosts free, 5 not responding.
Free hosts are machineC (idle 2 days, 12:24:49), machineD (idle  3:03:50), 
machineE (idle 1 day,  6:22:53), ...

答案2

没有任何东西可以完成所有这些任务,但rwhod可以让您开始。

rwhod在所有节点上运行。在任一节点上运行rwho以查看谁在所有节点上登录。

相关内容