[opencms-dev] Lucene 1.5 null pointer exception

Chris Todd chris at christophertodd.com
Wed Mar 31 04:18:01 CEST 2004


I've installed the lucene 1.5 module, followed the readme, and setup the
following crontab job:
* * * * * admin Administrators
net.grcomputing.opencms.search.lucene.CronIndexManager
createIndex=true,registry=/home/me/tomcat4.0/webapps/mywebsite.com/opencms/W
EB-INF/config/luceneconfig.xml

My luceneconfig.xml file is completely default except for the <indexDir>,
which is:
<indexDir>/home/me/tomcat4.0/webapps/mywebsite.com/opencms/WEB-INF/luceneind
ex/</indexDir>

I have created the directory:
/home/me/tomcat4.0/webapps/mywebsite.com/opencms/WEB-INF/luceneindex/
And it has the following permissions:
drwxrwxr-x    2 me    me        4096 Mar 30 00:18 luceneindex

When I run the indexer, however, I get the following exception:
[30.03.2004 21:10:10] <opencms_cronscheduler> Starting job for
com.opencms.core.CmsCronEntry{* * * * * admin Administrators
net.grcomputing.opencms.search.lucene.CronIndexManager
createIndex=true,registry=/home/ctodd/tomcat4.0/webapps/constantvigilance.im
agineis.net/opencms/WEB-INF/config/luceneconfig.xml}
[30.03.2004 21:10:10] <opencms_info> 
=====IndexManager===========================================================
==
[30.03.2004 21:10:10] <opencms_info> Analyzer:
org.apache.lucene.analysis.standard.StandardAnalyzer
[30.03.2004 21:10:10] <opencms_info> Extension map exists to handle
plaintext
[30.03.2004 21:10:10] <opencms_info> Extension map exists to handle
taggedtext
[30.03.2004 21:10:10] <opencms_info> Page DocumentFactory loaded
[30.03.2004 21:10:10] <opencms_cronscheduler> Error running job for
com.opencms.core.CmsCronEntry{* * * * * admin Administrators
net.grcomputing.opencms.search.lucene.CronIndexManager
createIndex=true,registry=/home/me/tomcat4.0/webapps/mywebsite.com/opencms/W
EB-INF/config/luceneconfig.xml} Error: java.lang.NullPointerException
	at org.apache.lucene.store.FSDirectory.create(FSDirectory.java:172)
	at org.apache.lucene.store.FSDirectory.<init>(FSDirectory.java:151)
	at
org.apache.lucene.store.FSDirectory.getDirectory(FSDirectory.java:132)
	at
org.apache.lucene.store.FSDirectory.getDirectory(FSDirectory.java:113)
	at org.apache.lucene.index.IndexWriter.<init>(IndexWriter.java:151)
	at
net.grcomputing.opencms.search.lucene.IndexManager.doIndex(Unknown Source)
	at
net.grcomputing.opencms.search.lucene.CronIndexManager.launch(Unknown
Source)
	at
com.opencms.core.CmsCronScheduleJob.run(CmsCronScheduleJob.java:68)

Any ideas what the problem is?

Regards,
Chris




More information about the opencms-dev mailing list