"Optimise AOD Index" and "Perform Lucene Index" failed in cron run

I’d like to be able to use Advanced OpenDiscovery. I’ve gotten cron to work and repaired my permissions so that I don’t receive an error when I run cron.php from the command line. However, suitecrm.log displays these errors:

Thu May 14 14:54:03 2015 [23926][1][FATAL] Job a28ec562-e911-b1f6-7d0c-5554fd86e0fc (Optimise AOD Index) failed in CRON run
Thu May 14 14:55:05 2015 [28339][1][FATAL] Job b9800615-7eb1-6f72-e11c-5554fdec94b3 (Perform Lucene Index) failed in CRON run

Any help is greatly appreciated!

1 Like

Actually, I tried running cron.php from the command line again and I get this error:

Fatal error: Uncaught exception 'Zend_Search_Lucene_Exception' with message 'Index doesn't exists in the specified directory.' in /home3/lukechao/public_html/modules/AOD_Index/Lib/Zend/Search/Lucene.php:566
Stack trace:
#0 /home3/lukechao/public_html/modules/AOD_Index/AOD_Index.php(307): Zend_Search_Lucene->__construct('modules/AOD_Ind...')
#1 /home3/lukechao/public_html/modules/AOD_Index/AOD_Index.php(68): AOD_Index->getLuceneIndex()
#2 /home3/lukechao/public_html/custom/modules/Schedulers/Ext/ScheduledTasks/scheduledtasks.ext.php(47): AOD_Index->optimise()
#3 [internal function]: aodOptimiseIndex(Object(SchedulersJob))
#4 /home3/lukechao/public_html/modules/SchedulersJobs/SchedulersJob.php(522): call_user_func_array('aodOptimiseInde...', Array)
#5 /home3/lukechao/public_html/include/SugarQueue/SugarCronJobs.php(188): SchedulersJob->runJob()
#6 /home3/lukechao/public_html/include/SugarQueue/SugarCronJobs.php(228): SugarCronJobs->executeJob(Object(SchedulersJob))
#7 /home3/lukechao/public_html/cron.php(74): SugarCronJobs- in /home3/lukechao/public_html/modules/AOD_Index/Lib/Zend/Search/Lucene.php on line 566

Fixing the permissions doesn’t seem to fix the problem…

I’ve made progress on this issue! I found this:

“To rebuild the Index, delete the Index directory in /modules/AOD_Index and clear the records in aod_index and aod_indexevent. Then your scheduled jobs will rebuild the Indexes (Indices?).”

This got rid of the error and the scheduled jobs are now running. However, AOD only indexed 31 out of 2600+ records. Hopefully it’ll index the rest of my records over time.

One day later, I’m still having issues with this. The scheduler for “Perform Lucene index” says “Last successful run: never.” I tried rebuilding the index again, but it only seems to be indexing new entries, not all the records. There are no errors in suitecrm.log or cron.php when I run it from the command line. Any help would be appreciated.

Although I do not know how to do that ( (“To rebuild the Index, delete the Index directory in /modules/AOD_Index and clear the records in aod_index and aod_indexevent. Then your scheduled jobs will rebuild the Indexes (Indices?).” )

I have the same problem. Did you finally came with proper solution?I found in the log (Wed May 27 08:40:02 2015 [1915][1][FATAL] Job 8bfea34e-da5b-3460-9353-556558ba1be4 (AOD) failed in CRON run).
Finally I do not have Lucene as job to run it.

Rebuilding the index fixed the problem. It just took a week for Lucene to index all my records. Deleting the directory requires you to FTP or ssh into your web host, and deleting the records requires you to truncate the table using mysql or phpmyadmin.

1 Like

I am having same problem even after 7.2.2 update. Can you give detailed instructions on how to do this?

Thanks,
Ed

Is it possible to provide us more details about that?
Thanks in advance

You have to delete the /modules/AOD_Index/Index/Index directory. I did it through the command line, but you can do it through FTP or whatever software you use to access the files on your server.

Then you have to delete all the records from the aod_index and aod_indexevent tables in your SuiteCRM database. I did this through phpmyadmin on my web host.

Upon the next cron job, the index should start to be rebuilt, slowly. I have 2700 records, and it took about a week for all of them to be indexed.

1 Like

Worked!

Thanks,
Ed

Hello! I need help. I have ~3200 records and directory /modules/AOD_Index/Index/Index directory takes a lot space(1.27 GB). Is it normally?