Gents,
After some tests on recent version of udmsearch (after 3.1.12), I got too many
problems and went back to 3.1.12, only stable for me at the moment (for my use).
To be able to have the number of indexed URLs into this version, I had to do some
changes in the C sources.
These are:
-> src/sql.c:
#define NDOCS_QUERY "SELECT count(*) FROM url"
to
#define NDOCS_QUERY "SELECT * FROM ndocs"
-> src/search.c, from line 700 there is a:
case 'N':
s++;
switch(*s){
Add there (after {) management of the NU keyword (Number URLs):
case 'U':
// Laurent LEVIER patch to display
// number of indexed urls
// UdmGetDocCount(UDM_AGENT * Indexer)
sprintf(UDM_STREND(Target),"%ld",UdmGetDocCount(Agent));
break;
Then compile as usual.
This method is much faster than the one provided by UDMsearch team.
But it requires a new table & a script to update regularly the information:
-> Table (MySQL format):
CREATE TABLE ndocs (
ndocs int(11) DEFAULT '0' NOT NULL
);
-> Script to update automagically is attached (Perl): ndocs-update
Typical use is: ndocs-update -d udmsearchDB -u udmsearch -P udmsearch -v
@+/L
Laurent LEVIER
IT Systems & Networks, Unix System Engineer, Security Expert
Argosnet Security Server : http://www.Argosnet.com
"Le Veilleur Technologique", "The Technology Watcher"
ndocs-update