Show connection in ps

Ken Cross kcross at
Wed Apr 30 13:23:17 GMT 2003


In the "just for fun" department...

Something I've found very handy is the ability to quickly see all the
connections using "ps -ax":

 2442 S  0:00.04 smbd: kjcwinxp ( WIN2DOM\cross 
 2693 S  0:00.07 smbd: win2 ( WIN2DOM\Administrator 
 3016 S  0:00.05 smbd: nt4srv ( WIN2DOM\User2
 5239 Ss 0:00.08 /usr/pkg/sbin/smbd -D 

It's not as comprehensive as smbstatus, but it's less boring than
hundreds of lines of "smbd -D".  I added this line:

 setproctitle( "%s (%s) %s", get_remote_machine_name(),
conn->client_address, user );

at the end of make_connection_snum in smbd/service.c.


Ken Cross

Network Storage Solutions
Phone 865.675.4070 ext 31
kcross at 

More information about the samba-technical mailing list