regarding the No.of entries in the Directory Server
I wanted to know the number of entries in our DS. So i have initially made a search on the requried objectclass and then counted the number of DN's in the exported LDIF file:
1)./ldapsearch -h sever -p 389 -b "suffix" -s sub -D "cn=Directory Manager" -w objectclass=thdperson > ldif.file
Then i found the following command to count the no of entries in a DS from the forums...The command looks like this for this search:
2)ldapsearch -h server -p 389 -b "suffix" "objectclass=thdPerson" | grep "^dn:" | wc -1
To my surprise, I fount that the no of entries are different for the above search..Search using command2 gave me the count as 19541 and search1 gave me the count as 19529..
Late i exported a ldif file using the searchcommand2 and the result count of this is 19540....
Then i made a search again by searchcommand2 but this time using cn=Directory Manager..now the count is 19542(one more than the result obtained by using searchcommand2 with anonymous search)
What exactly is causing this variation in the count?Iam a little bit worried because we are migrating our whole data to a new Server with a new DIT and schema..So i just want to make sure that all the entries are present in the new server...

