The CodecUtil.writeHeader signature has changed from

public static DataOutput writeHeader(DataOutput out, String codec, int
version)

in lucene 3.4 (which is the method not found) to

public static void writeHeader(DataOutput out, String codec, int version)

in lucene 4.0

It means that while you're using solr 4.0, some 3.4 jars are stuck
somewhere in the java classpath. Obviously some code is looking for this
3.4 method.

If you're using the start.jar executable, you should have a look at your
system-wide classpath
If you're using tomcat (and that sounds plausible in this situation), you
should trash the "work" directory sub-folders of your tomcat installation;
and restart it. Tomcat unpacks war archives in this directory, and it may
have kept a 3.4 solr war deployed here.

2011/11/9 elisabeth benoit <elisaelisael...@gmail.com>

> Hello,
>
> I've just installed Solr 4.0, and I am getting an error when indexing.
>
> *GRAVE: java.lang.NoSuchMethodError:
>
> org.apache.lucene.util.CodecUtil.writeHeader(Lorg/apache/lucene/store/DataOutput;Ljava/lang/String;I)Lorg/apache/lucene/store/DataOutput;
>    at org.apache.lucene.util.fst.FST.save(FST.java:311)*.
>
> Does anybody know what I've done wrong?
>
> Thanks,
> Elisabeth
>

Reply via email to