Ankush,
As suggested by Lavanya and Roberto, you can certainly use ldapsearch. If you do not have openLDAP tools installed and available to you, one can certainly use 'dxsearch' command line utility that ships with CA Directory product.
Another option to quickly check "how many number of entries" you have in a particular DSA is to connect to DXconsole and execute 'get cache;'.
At the end of the output you will something like:
dxgrid-db-size = 500000000
Used bytes in file = 282522
Reclaimable bytes = 98
Total number of entries = 1382 <= This line in the output
disable-transaction-log = false
disable-transaction-log-flush = false
Thanks,
Hitesh