Regd. per-share stats/profile support

Jeremy Allison jra at
Wed Sep 23 19:05:44 UTC 2020

On Wed, Sep 23, 2020 at 08:52:25AM +0000, Sudip Panda via samba-technical wrote:
> Hello Everyone,
> I am new to SAMBA codebase and going through the building blocks
> (tevent, tallocs, TDBs etc.) to address a feature request to provide
> per-share statistics/profile. As of now, I see with smbstatus command
> (with -P and profile option set), SAMBA provide global statistics.
> Also, while I am learning SAMBA, I came across SAMBA TA. Would like
> to understand whether similar request (supporting per-share statistics)
> came in the past and any analysis was done for supporting it using TDBs.
> If any analysis was done in the past, would like to understand the
> outcome of that from you folks. I understand that multiple connection
> can access and modify the per-share stats which actually is a case for global stats as well.

I haven't seen a request for per-share profile stats.

You'd have to add a 'per-share' field inside
the smbprofile_stats_bytes_async struct in
source3/include/smbprofile.h and ensure that
the profile setting macros also add in the
required info to identify a particular share.

More information about the samba-technical mailing list