Hello Shalin,

  Looks like I was using old version of solrconfig.xml (from Solr
1.2). After I updated to the latest solrconfig.xml (from 1.4) it seems
to be working fine.

Another question I got is how would I search on multi-cores,

 1) If I want to search for a word in two different cores?
 2) If I want to search for a word in all the cores.
 3) How would I search on multiple cores on multiple machines?

Single core I'm able to search like,

http://localhost:8080/solr/20090402/select?q=*:*

Thanks,
-vivek

------------------
Just in case if this might be helpful to others who might be trying to
use Solr multicore.

  Here is what I tried.

1)  Created this directory structure -

       multicore/core0 (put in the conf directory - with schema.xml
and solrconfig.xml - under core0)
       multicore/core1

     Make multicore as the solr.home and put the solr.xml under there

2) Added couple of cores in the solr.xml,

 <solr persistent="true">
    <cores adminPath="/admin/cores">
      <core name="core0" instanceDir="core0" dataDir="data"/>
      <core name="core1" instanceDir="core0" dataDir="../core1/data"/>
    </cores>
</solr>

Here core1 is using instancedir of core0 (using same schema.xml and
solrconfig.xml).

2) Started Solr

3) Data/index directory is created under both cores

4)  Tried following URLs,

    a) http://localhost:8080/solr/admin/cores
     - admin interface for both cores
    b) http://localhost:8080/solr/core0/admin/
     - I see the single core admin page
    c) http://localhost:8080/solr/admin/cores?action=STATUS
        - same as a
    d) http://localhost:8080/solr/admin/cores?action=STATUS&core=core0
       - same as b
    e) http://localhost:8080/solr/core0/select?q=*:*
       - shows result xml

5) I then created the core dynamically using CREATE service (this
requires Solr 1.4),

   
http://localhost:8080/solr/admin/cores?action=CREATE&name=20090402&instanceDir=/Users/opal/temp/chat/solr/multicore/core0&dataDir=/Users/opal/temp/chat/solr/multicore/20090402/data

  - this dynamically updated the solr.xml and created a directory
structure (20090402/data) on the file system.

6) The use solrj to add beans to the recently created core







On Wed, Apr 1, 2009 at 8:26 PM, Shalin Shekhar Mangar
<shalinman...@gmail.com> wrote:
> On Thu, Apr 2, 2009 at 2:34 AM, vivek sar <vivex...@gmail.com> wrote:
>> Thanks Shalin.
>>
>> I added that in the solrconfig.xml, but now I get this exception,
>>
>> org.apache.solr.common.SolrException: Not Found
>> Not Found
>> request: http://localhost:8080/solr/core0/update?wt=javabin&version=2.2
>>
>> I do have the "core0" under the solr.home. The core0 directory also
>> contains the conf and data directories. The solr.xml has following in
>> it,
>>
>> <cores adminPath="/admin/cores">
>>      <core name="core0" instanceDir="core0" dataDir="data"/>
>>  </cores>
>>
>>
>
> Are you able to see the Solr admin dashboard at
> http://localhost:8080/solr/core0/admin/ ? Are there any exceptions in
> Solr log?
>
> --
> Regards,
> Shalin Shekhar Mangar.
>

Reply via email to