Re: user statistic


Subject: Re: user statistic
From: Karen A Swanberg (swanberg@tc.umn.edu)
Date: Wed Oct 03 2001 - 17:56:03 EDT


on 04/19/01, Michael.Kindermann@mainpost.de wisely declared:

> hello,
>
> our server (linux 2.2.10) is running natalk 1.4b2 + asun2.1.4 . is there a
> possibility get some statistics who is using the server by appletalk.
> The server is also running samba, so there are alot of computers connected.
>
> MfG

In the contrib directory of netatalk, there are two subdirectories, nu and
macusers. They both contain scripts that help determine who is logged
in. I don't remember which runs on which platforms, but try them
out. Samba comes with a utilty called smbstatus that does the same thing.

I use openbsd, for which neither nu or macusers worked, but a friend had
written one that did, called afpdstatus. I posted it to this list a few
months ago, if you search the archives you can find it, or I can send it
to you off-line. I strung afpdstatus and smbstatus together into a simple
script, and run that to see who's logged in on both samba and netatalk at
the same time. lsof (from gnu, I think) can also tell you which client the
mac user is logged into.

Here's my simple script, as I said, it calls other scripts provided by
samba and netatalk:

#!/bin/sh
# To Run Rowan's afpdstatus script and then lsof, so can
# tell from whence people are logged in.
echo 'Netatalk users logged in:'

/usr/local/bin/afpdstatus

echo ' '

echo 'Location of Netatalk Users (lsof):'
echo ' '
lsof | grep afpd | grep ESTABLISHED

echo ' '
echo 'Output of smbstatus:'
echo ' '
/usr/local/samba/bin/smbstatus

---
hope that helps,

-Karen

- - Karen Swanberg | Sys Admin | Dept. of Geology and Geophysics 206 Pillsbury Hall | 310 Pillsbury Ave. SE | University of Minnesota Minneapolis, MN 55455 (612) 624-6541 (612) 625-3819 (f)

* <---- Tribble . <--- Tribble.tgz



This archive was generated by hypermail 2b28 : Sun Oct 14 2001 - 03:04:54 EDT