I suppose you've solved this problem already. I just ran into it. And solving
it took the following steps:
-putting in the directory  ....\Tomcat 5.5\conf\Catalina\localhost a proper
solr.xml file, much like the one you have, containing only the text <br />
<Context docBase= "..../solr.war" .... > <Environment name="solr/home"
type="java.lang.String" value="..." /></Context>

- modifying the solrconfig.xml , and this was another necessary step ,
changing the default
<dataDir>${solr.data.dir:./solr/data}</dataDir>
to point to your actual solr-home e.g.:
<dataDir>${solr.data.dir:/usr/local/projects/my_app/current/solr-home/data}</dataDir>

To clarify my configuration: I work with Tomcat 5.5.20 under Windows-XP. My
current dataDir is actually:
<dataDir>${solr.data.dir:K:/solr/cur_solr/solr/data}</dataDir>

may be this could help ! This information should be added in the SolrTomcat
(http://wiki.apache.org/solr/SolrTomcat) - it would have saved me hours ....

yo




Matt Mitchell-2 wrote:
> 
> Here you go:
> 
> <Context docBase="/usr/local/lib/solr.war" debug="0"  
> crossContext="true" >
>     <Environment name="solr/home" type="java.lang.String" value="/usr/ 
> local/projects/my_app/current/solr-home" />
> </Context>
> 
> This is the same file I'm putting into the Tomcat manager "XML  
> Configuration file URL" form input.
> 
> Matt
> 
> On Sep 6, 2007, at 3:25 PM, Tom Hill wrote:
> 
>> It works for me. (fragments with solr 1.2 on tomcat 5.5.20)
>>
>> Could you post your fragment file?
>>
>> Tom
>>
>>
>> On 9/6/07, Matt Mitchell <[EMAIL PROTECTED]> wrote:
>>> Hi,
>>>
>>> I recently upgraded to Solr 1.2. I've set it up through Tomcat using
>>> context fragment files. I deploy using the tomcat web manager. In the
>>> context fragment I set the environment variable solr/home. This use
>>> to work as expected. The solr/home value pointed to the directory
>>> where "data", "conf" etc. live. Now, this value doesn't get used and
>>> instead, tomcat creates a new directory called "solr" and "solr/data"
>>> in the same directory where the context fragment file is located.
>>> It's not really a problem in this particular instance. I like the
>>> idea of it defaulting to "solr" in the same location as the context
>>> fragment file, but as long as I can depend on it always working like
>>> that. It is a little puzzling as to why the value in my environment
>>> setting doesn't work though?
>>>
>>> Has anyone else experienced this behavior?
>>>
>>> Matt
> 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/solr-home-tf4394152.html#a12982101
Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to