On 8.2.2016 20:38, Peter Pakos wrote:
> Just a quick heads-up,
> The newest version of the ipa_check_consistency script comes with
> Nagios/Opsview plug-in functionality and some further improvements.
> Feel free to take it for a spin!
> https://github.com/peterpakos/ipa_check_consistency


This is an interesting script.

BTW an effective way how to count entries in LDAP is to request base entry and
ask for 'numSubordinates' attribute, it contains number of child entries (on
that particular level, it does not count recursively).

Following should work, but I did not test it :-)
ldapsearch -LLLx -h "${server}.${DOMAIN}" \
      -D "$BINDDN" -w "$BINDPW" -b "cn=groups,cn=accounts,${SUFFIX}" -s base \
      "(objectClass=*)" "numSubordinates" 2>/dev/null \

It will be way way way faster and you will be able to eradicate Perl, which is
always a good thing :-)

Petr^2 Spacek

Manage your subscription for the Freeipa-users mailing list:
Go to http://freeipa.org for more info on the project

Reply via email to