[Samba] Getting stats for logged in domain users?
tonywhitmore at users.sourceforge.net
Sun Apr 11 15:01:48 GMT 2004
Frode Lillerud wrote:
> Samba 3.0.2a, Debian linux, 2.6.x kernel, PDC server, WinXP clients.
> Hi, I'm setting up a samba server for one of our branch offices.
> During the monitoring of the server I'd like to be able to view how many
> domain users, and which ones, are logged in on the domain at particular
> times. The users use WinXP.
> Is there any way of getting number of logged on domainusers, their IP's
> or usernames?
You can use the pre-exec (or root pre-exec) options in smb.conf to echo
data out to a separate log file. This takes all the usual subsitution,
so will record IP, NetBIOS name, username etc. of clients.
You can then do what you like with this data, perl-wise :) I'm
considering directing the log output into mysql so that I can analyse
the logs through a PHP interface.
More information about the samba