#50029 dbmon.sh: Negative ndn. ndn overgrowing max allowed size
Closed: wontfix 3 years ago by spichugi. Opened 5 years ago by jaredl.

Issue Description

Hi! I was speaking with @mreynolds on IRC about how the output from dbmon.sh was showing negative values for our ndn size.

Results from: ldapsearch -LLL -o ldif-wrap=no  -x -D 'cn=directory manager' -W -s sub -b 'cn=config' '(&(objectclass=*)(cn=monitor))'
https://paste.fedoraproject.org/paste/luXmuenYWSy~DtEYLVAdmg/raw

Additionally, there's this as well: https://paste.fedoraproject.org/paste/UYrdQZkBWUtEYK5T50KXdA/raw

Using the version of dbmon.sh that ships w/ our installed version of 389-ds-base get's me:

# dbcachefree - free bytes in dbcache
# free% - percent free in dbcache
# roevicts - number of read-only pages dropped from cache to make room for other pages
#            if this is non-zero, it means the dbcache is maxed out and there is page churn
# hit% - percent of requests that are served by cache
# pagein - number of pages read into the cache
# pageout - number of pages dropped from the cache
dbcachefree 40820736 free% 2.534 roevicts 895028 hit% 99 pagein 1052548 pageout 12209031
# dbname - name of database instance - the row shows the entry cache stats
# count - number of entries in cache
# free - number of free bytes in cache
# free% - percent free in cache
# size - average size of date in cache in bytes (current size/count)
# DNcache - the line below the entry cache stats are the DN cache stats
# count - number of dns in dn cache
# free - number of free bytes in dn cache
# free% - percent free in dn cache
# size - average size of dn in dn cache in bytes (currentdncachesize/currentdncachecount)
# hit_ratio - cache hit ratio
# under each db are the list of selected indexes specified with INDEXLIST
       dbname      count          free  free%    size  hit_ratio
changelog:ent      11728    4377192404   98.8  4433.2       96.0
changelog:dn       11728     536014788   99.8    73.0       79.0
changelog:ndn     592432     -50986328 -101.3   171.0       99.0
 userroot:ent      94931    3793745714   85.7  6693.7       96.0
 userroot:dn       94929     522898753   97.4   147.2       22.0
 userroot:ndn     592432     -50986328 -101.3   171.0       99.0
    ipaca:ent     327902      89795901    2.0 13233.8       96.0
    ipaca:dn      327902     509121558   94.8    84.6        4.0
    ipaca:ndn     592432     -50986328 -101.3   171.0       99.0

and then, if I use the latest version in the master branch (https://pagure.io/389-ds-base/blob/master/f/ldap/admin/src/scripts/dbmon.sh.in) I get:

# dbcachefree - free bytes in dbcache
# free% - percent free in dbcache
# roevicts - number of read-only pages dropped from cache to make room for other pages
#            if this is non-zero, it means the dbcache is maxed out and there is page churn
# hit% - percent of requests that are served by cache
# pagein - number of pages read into the cache
# pageout - number of pages dropped from the cache
dbcachefree 40820736 free% 2.534 roevicts 894198 hit% 99 pagein 1051722 pageout 12200172
# dbname - name of database instance - the row shows the entry cache stats
# count - number of entries in cache
# free - number of free bytes in cache
# free% - percent free in cache
# size - average size of date in cache in bytes (current size/count)
# DNcache - the line below the entry cache stats are the DN cache stats
# count - number of dns in dn cache
# free - number of free bytes in dn cache
# free% - percent free in dn cache
# size - average size of dn in dn cache in bytes (currentdncachesize/currentdncachecount)
# hit_ratio - cache hit ratio
# under each db are the list of selected indexes specified with INDEXLIST
       dbname      count          free  free%    size  hit_ratio
   global:ndn     592650     -50976396 -101.3   170.9       99.0
changelog:ent      11700    4377314638   98.8  4433.4       96.0
changelog:dn       11700     536016832   99.8    73.0       79.0
 userroot:ent      94931    3793777335   85.7  6693.4       96.0
 userroot:dn       94929     522899740   97.4   147.2       22.0
    ipaca:ent     327899      89824993    2.0 13233.8       96.0
    ipaca:dn      327899     509121795   94.8    84.6        4.0

Package Version and Platform

389-ds-base-1.3.7.5-28.el7_5.x86_64

Steps to reproduce

I actually don't know how we got into this state. I'm happy to help debug though.

Actual results

I don't think that the max ndn cache size should be able to be exceeded?

Expected results

Non-negative output from dbmon.sh for the ndn cache.


Metadata Update from @mreynolds:
- Custom field component adjusted to None
- Custom field origin adjusted to None
- Custom field reviewstatus adjusted to None
- Custom field type adjusted to None
- Custom field version adjusted to None
- Issue set to the milestone: 1.4.0

5 years ago

@mreynolds Did we have any idea on this? The NDN cache is now actually a "per-thread ndn" cache, so I can certainly see how that would confuse some scripts ...

Metadata Update from @mreynolds:
- Issue priority set to: major
- Issue set to the milestone: 1.4.3 (was: 1.4.0)

4 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/389ds/389-ds-base/issues/3088

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata Update from @spichugi:
- Issue close_status updated to: wontfix
- Issue status updated to: Closed (was: Open)

3 years ago

Login to comment on this ticket.

Metadata