Fwd: Setting Solr Home via installation script

2019-01-08 Thread Stephon Harris
Seeing if anyone has any thoughts on this again.

-- Forwarded message -
From: Stephon Harris 
Date: Mon, Jan 7, 2019 at 10:05 AM
Subject: Setting Solr Home via installation script
To: 



I am trying to install solr as a service so that when a restart takes place
the solr home directory is set to `example/schemaless/solr`where there are
cores I have created while running solr in the schemaless example.



As instructed in taking Solr to Production
<https://lucene.apache.org/solr/guide/7_4/taking-solr-to-production.html>,
I ran the command sudo bash ./install_solr_service.sh solr-7.4.0.tgz -i
/opt/ -d example/schemaless/solr -u solr -s solr -p 8983 and it started
solr successfully, however the solr home was set to /var/solr/data. I
thought that giving the -d option Solr home would be set to
example/schemaless/solr. What should I do to get solr home set to
example/schemaless/solr? Is there another way I should go about getting the
cores that I created under the schemaless directory in the solr home
directory?

-- 
Stephon Harris

*Enterprise Knowledge, LLC*
*Web: *http://www.enterprise-knowledge.com/
<http://www.google.com/url?q=http%3A%2F%2Fwww.enterprise-knowledge.com%2F&sa=D&sntz=1&usg=AFQjCNFDktFDhseOl_Pha6Pz3fIFaWolNg>
*E-mail:* shar...@enterprise-knowledge.com/
<http://www.google.com/url?q=http%3A%2F%2Fwww.enterprise-knowledge.com%2F&sa=D&sntz=1&usg=AFQjCNFDktFDhseOl_Pha6Pz3fIFaWolNg>
*Cell:* 832-628-8352



-- 
Stephon Harris

*Enterprise Knowledge, LLC*
*Web: *http://www.enterprise-knowledge.com/
<http://www.google.com/url?q=http%3A%2F%2Fwww.enterprise-knowledge.com%2F&sa=D&sntz=1&usg=AFQjCNFDktFDhseOl_Pha6Pz3fIFaWolNg>
*E-mail:* shar...@enterprise-knowledge.com/
<http://www.google.com/url?q=http%3A%2F%2Fwww.enterprise-knowledge.com%2F&sa=D&sntz=1&usg=AFQjCNFDktFDhseOl_Pha6Pz3fIFaWolNg>
*Cell:* 832-628-8352


Setting Solr Home via installation script

2019-01-07 Thread Stephon Harris
I am trying to install solr as a service so that when a restart takes place
the solr home directory is set to `example/schemaless/solr`where there are
cores I have created while running solr in the schemaless example.



As instructed in taking Solr to Production
<https://lucene.apache.org/solr/guide/7_4/taking-solr-to-production.html>,
I ran the command sudo bash ./install_solr_service.sh solr-7.4.0.tgz -i
/opt/ -d example/schemaless/solr -u solr -s solr -p 8983 and it started
solr successfully, however the solr home was set to /var/solr/data. I
thought that giving the -d option Solr home would be set to
example/schemaless/solr. What should I do to get solr home set to
example/schemaless/solr? Is there another way I should go about getting the
cores that I created under the schemaless directory in the solr home
directory?

-- 
Stephon Harris

*Enterprise Knowledge, LLC*
*Web: *http://www.enterprise-knowledge.com/
<http://www.google.com/url?q=http%3A%2F%2Fwww.enterprise-knowledge.com%2F&sa=D&sntz=1&usg=AFQjCNFDktFDhseOl_Pha6Pz3fIFaWolNg>
*E-mail:* shar...@enterprise-knowledge.com/
<http://www.google.com/url?q=http%3A%2F%2Fwww.enterprise-knowledge.com%2F&sa=D&sntz=1&usg=AFQjCNFDktFDhseOl_Pha6Pz3fIFaWolNg>
*Cell:* 832-628-8352


Re: Moving solr home

2017-04-18 Thread Shawn Heisey
On 4/18/2017 7:07 AM, tedsolr wrote:
> Looks like the issues are self inflicted. I have custom start/stop
> scripts that actually specify the solr home directory as a param to
> the start command (start -c -s ...). This was overriding my include
> variable. As for the magical solr.xml file, that's also my doing
> because as part of shutdown the script copies config files where they
> need to go. When I wrote all this 2 years ago I needed the flexibility
> to run multiple nodes on a single host (because requisitioning a
> server took an act of congress).

The service installer script works well for non-Windows systems, and has
one big advantage -- the people on this list will know exactly where
everything is if you are able to tell us the options you used on the
installer.  With custom scripts like what you wrote, we have no idea
where anything is.  The installer script defaults to separating the solr
home from the install dir.

I would strongly recommend using the service installer script if you're
not running on Windows.  It will create a user to run Solr so it's not
running as root.  You can install more than one instance using that
script.  Each one will get its own copy of the binaries.  Although it is
possible to run multiple instances out of one install directory, it does
require custom scripting.  The amount of disk space that separate
install directories use is usually very small compared to the indexes
and modern disk sizes.

Thanks,
Shawn



Re: Moving solr home

2017-04-18 Thread tedsolr
Looks like the issues are self inflicted. I have custom start/stop scripts
that actually specify the solr home directory as a param to the start
command (start -c -s ...). This was overriding my include variable. As for
the magical solr.xml file, that's also my doing because as part of shutdown
the script copies config files where they need to go.

When I wrote all this 2 years ago I needed the flexibility to run multiple
nodes on a single host (because requisitioning a server took an act of
congress). 


Susheel Kumar-3 wrote
> Hi,
> 
> Did you try to utilise the service installation scripts to deploy.  This
> makes it very easy for Prod deployments and allows to decouple data/index
> directory with Solr binaries. See below link
> 
> https://cwiki.apache.org/confluence/display/solr/Taking+Solr+to+Production
> 
> Thanks,
> Susheel
> 
> On Mon, Apr 17, 2017 at 3:46 PM, tedsolr <

> tsmith@

> > wrote:
> 
>> I have a solr cloud cluster (v5.2.1 on redhat linux) that uses the
>> default
>> location for solr home: (install dir)/server/solr. I would like to move
>> the
>> index data somewhere else to make upgrades easier. When I set a SOLR_HOME
>> variable  solr appears to be ignoring it - and even creating a solr.xml
>> file
>> in (install dir)/server/solr. Is solr doing some auto detect instead of
>> using the defined SOLR_HOME variable?
>>
>> pre-reqs:
>> - copied all index data to new solr home
>> - placed a solr.xml file in new solr home
>> - set SOLR_HOME & SOLR_PID_DIR in (install dir)/bin/solr.in.sh
>> - deleted solr.xml from default solr home
>>
>> then restart solr nodes:
>> - the admin console still shows solr.solr.home as default
>> - solr.xml gets recreated in the default solr home folder
>>
>> Anyone know what I'm missing?
>>
>>
>>
>> --
>> View this message in context: http://lucene.472066.n3.
>> nabble.com/Moving-solr-home-tp4330350.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>





--
View this message in context: 
http://lucene.472066.n3.nabble.com/Moving-solr-home-tp4330350p4330489.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Moving solr home

2017-04-17 Thread Susheel Kumar
Hi,

Did you try to utilise the service installation scripts to deploy.  This
makes it very easy for Prod deployments and allows to decouple data/index
directory with Solr binaries. See below link

https://cwiki.apache.org/confluence/display/solr/Taking+Solr+to+Production

Thanks,
Susheel

On Mon, Apr 17, 2017 at 3:46 PM, tedsolr  wrote:

> I have a solr cloud cluster (v5.2.1 on redhat linux) that uses the default
> location for solr home: (install dir)/server/solr. I would like to move the
> index data somewhere else to make upgrades easier. When I set a SOLR_HOME
> variable  solr appears to be ignoring it - and even creating a solr.xml
> file
> in (install dir)/server/solr. Is solr doing some auto detect instead of
> using the defined SOLR_HOME variable?
>
> pre-reqs:
> - copied all index data to new solr home
> - placed a solr.xml file in new solr home
> - set SOLR_HOME & SOLR_PID_DIR in (install dir)/bin/solr.in.sh
> - deleted solr.xml from default solr home
>
> then restart solr nodes:
> - the admin console still shows solr.solr.home as default
> - solr.xml gets recreated in the default solr home folder
>
> Anyone know what I'm missing?
>
>
>
> --
> View this message in context: http://lucene.472066.n3.
> nabble.com/Moving-solr-home-tp4330350.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Moving solr home

2017-04-17 Thread tedsolr
I have a solr cloud cluster (v5.2.1 on redhat linux) that uses the default
location for solr home: (install dir)/server/solr. I would like to move the
index data somewhere else to make upgrades easier. When I set a SOLR_HOME
variable  solr appears to be ignoring it - and even creating a solr.xml file
in (install dir)/server/solr. Is solr doing some auto detect instead of
using the defined SOLR_HOME variable?

pre-reqs:
- copied all index data to new solr home
- placed a solr.xml file in new solr home
- set SOLR_HOME & SOLR_PID_DIR in (install dir)/bin/solr.in.sh
- deleted solr.xml from default solr home

then restart solr nodes:
- the admin console still shows solr.solr.home as default
- solr.xml gets recreated in the default solr home folder

Anyone know what I'm missing?



--
View this message in context: 
http://lucene.472066.n3.nabble.com/Moving-solr-home-tp4330350.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Specify relative path to current core conf folder when it's originally relative to solr home

2016-04-11 Thread Reth RM
 I think there are some root paths defined in solr.sh file that will be in
bin directory. You can pick root directory variable from there and use it.
Example in solrconfig.xml, there is a value as :
" ${solr.install.dir:../../../..}" I think solr.install.dir is the root
path and its definition is set in solr.sh. I'm not sure but worth giving a
try.




On Tue, Apr 12, 2016 at 9:34 AM, scott.chu  wrote:

> I got a custom tokenizer. When configuring it, there's an attribute
> 'fileDir', whose value is  a path relative to solr home. But I wish it can
> be relative to current core. Is there some system variable out-of-box, say
> {current_core}, that I can use in the value? For example,
>
> solr home = /solr5/server/solr
> In the current core's solrconfig.xml, I can specify
> 
> 
> myfiledir
> 
> 
>
> so it will refer to /solr5/server/solr/myfiledir.
>
> But I wanna put myfileDir under current core's conf folder. I wish there's
> something such as:
> ...
> {current_core}/conf/myfiledir
> ...
>
> Is it possible?
>


Specify relative path to current core conf folder when it's originally relative to solr home

2016-04-11 Thread scott.chu
I got a custom tokenizer. When configuring it, there's an attribute 'fileDir', 
whose value is  a path relative to solr home. But I wish it can be relative to 
current core. Is there some system variable out-of-box, say {current_core}, 
that I can use in the value? For example, 

solr home = /solr5/server/solr
In the current core's solrconfig.xml, I can specify


myfiledir



so it will refer to /solr5/server/solr/myfiledir.

But I wanna put myfileDir under current core's conf folder. I wish there's 
something such as:
...
{current_core}/conf/myfiledir
...

Is it possible?


Re: Separating cores from Solr home

2016-03-04 Thread Jan Høydahl
There is also the more clean solution in 
https://issues.apache.org/jira/browse/SOLR-6671 (not committed).

--
Jan Høydahl, search solution architect
Cominvent AS - www.cominvent.com

> 4. mar. 2016 kl. 15.38 skrev Shawn Heisey :
> 
> On 3/3/2016 4:12 AM, Tom Evans wrote:
>> I'm struggling to configure solr cloud to put the index files and
>> core.properties in the correct places in SolrCloud 5.5. Let me explain
>> what I am trying to achieve:
>> 
>> * solr is installed in /opt/solr
>> * the user who runs solr only has read only access to that tree
>> * the solr home files - custom libraries, log4j.properties, solr.in.sh
>> and solr.xml - live in /data/project/solr/releases/, which
>> is then the target of a symlink /data/project/solr/releases/current
>> * releasing a new version of the solr home (eg adding/changing
>> libraries, changing logging options) is done by checking out a fresh
>> copy of the solr home, switching the symlink and restarting solr
>> * the solr core.properties and any data live in /data/project/indexes,
>> so they are preserved when new solr home is released
>> 
>> Setting core specific dataDir with absolute paths in solrconfig.xml
>> only gets me part of the way, as the core.properties for each shard is
>> created inside the solr home.
>> 
>> This is obviously no good, as when releasing a new version of the solr
>> home, they will no longer be in the current solr home.\
> 
> Add the coreRootDirectory config element to your solr.xml file, so Solr
> does core discovery directly on /data/project/indexes, rather than the
> solr home.  The solr.xml and lib directory with your jars will remain in
> the solr home.
> 
> https://cwiki.apache.org/confluence/display/solr/Format+of+solr.xml#Formatofsolr.xml-Solr.xmlParameters
> 
> Because it's easy to end up with different cores sharing a data
> directory, changing dataDir should be avoided unless you have good
> reason, especially in solrconfig.xml, and absolute paths are a
> particularly bad idea.  If you leave dataDir alone, then both
> instanceDir and dataDir for each core will be in subdirectories under
> /data/project/indexes.
> 
> As you probably know, SolrCloud does not use the conf directory in the
> core's instanceDir, so aside from properties files (like
> core.properties) data is the only information you will have for each
> core -- there's no need to have it in a different location than
> instanceDir, which is where core.properties lives.
> 
> I'm going against the advice I've given you in my own config and setting
> dataDir in my core.properties files, but it's a relative path, so if I
> move things around, the data moves too.  I'm also very aware of what's
> in *every* core.properties file, and take care to ensure that they are
> all correct.  I am not running SolrCloud, so each of my cores contains a
> conf directory.
> 
> If moving dataDir outside of instanceDir is important to you, set it in
> core.properties, and use a relative path.  When using a relative path,
> dataDir is relative to instanceDir.  It defaults to ${instanceDir}/data.
> 
> Thanks,
> Shawn
> 



Re: Separating cores from Solr home

2016-03-04 Thread Shawn Heisey
On 3/3/2016 4:12 AM, Tom Evans wrote:
> I'm struggling to configure solr cloud to put the index files and
> core.properties in the correct places in SolrCloud 5.5. Let me explain
> what I am trying to achieve:
>
> * solr is installed in /opt/solr
> * the user who runs solr only has read only access to that tree
> * the solr home files - custom libraries, log4j.properties, solr.in.sh
> and solr.xml - live in /data/project/solr/releases/, which
> is then the target of a symlink /data/project/solr/releases/current
> * releasing a new version of the solr home (eg adding/changing
> libraries, changing logging options) is done by checking out a fresh
> copy of the solr home, switching the symlink and restarting solr
> * the solr core.properties and any data live in /data/project/indexes,
> so they are preserved when new solr home is released
>
> Setting core specific dataDir with absolute paths in solrconfig.xml
> only gets me part of the way, as the core.properties for each shard is
> created inside the solr home.
>
> This is obviously no good, as when releasing a new version of the solr
> home, they will no longer be in the current solr home.\

Add the coreRootDirectory config element to your solr.xml file, so Solr
does core discovery directly on /data/project/indexes, rather than the
solr home.  The solr.xml and lib directory with your jars will remain in
the solr home.

https://cwiki.apache.org/confluence/display/solr/Format+of+solr.xml#Formatofsolr.xml-Solr.xmlParameters

Because it's easy to end up with different cores sharing a data
directory, changing dataDir should be avoided unless you have good
reason, especially in solrconfig.xml, and absolute paths are a
particularly bad idea.  If you leave dataDir alone, then both
instanceDir and dataDir for each core will be in subdirectories under
/data/project/indexes.

As you probably know, SolrCloud does not use the conf directory in the
core's instanceDir, so aside from properties files (like
core.properties) data is the only information you will have for each
core -- there's no need to have it in a different location than
instanceDir, which is where core.properties lives.

I'm going against the advice I've given you in my own config and setting
dataDir in my core.properties files, but it's a relative path, so if I
move things around, the data moves too.  I'm also very aware of what's
in *every* core.properties file, and take care to ensure that they are
all correct.  I am not running SolrCloud, so each of my cores contains a
conf directory.

If moving dataDir outside of instanceDir is important to you, set it in
core.properties, and use a relative path.  When using a relative path,
dataDir is relative to instanceDir.  It defaults to ${instanceDir}/data.

Thanks,
Shawn



Re: Separating cores from Solr home

2016-03-03 Thread Jeff Wartes
It’s a bit backwards feeling, but I’ve had luck setting the install dir and 
solr home, instead of the data dir.

Something like:
-Dsolr.solr.home=/data/solr 
-Dsolr.install.dir=/opt/solr


So all of the Solr files are in in /opt/solr and all of the index/core related 
files end up in /data/solr.




On 3/3/16, 3:58 AM, "Tom Evans"  wrote:

>Hmm, I've worked around this by setting the directory where the
>indexes should live to be the actual solr home, and symlink the files
>from the current release in to that directory, but it feels icky.
>
>Any better ideas?
>
>Cheers
>
>Tom
>
>On Thu, Mar 3, 2016 at 11:12 AM, Tom Evans  wrote:
>> Hi all
>>
>> I'm struggling to configure solr cloud to put the index files and
>> core.properties in the correct places in SolrCloud 5.5. Let me explain
>> what I am trying to achieve:
>>
>> * solr is installed in /opt/solr
>> * the user who runs solr only has read only access to that tree
>> * the solr home files - custom libraries, log4j.properties, solr.in.sh
>> and solr.xml - live in /data/project/solr/releases/, which
>> is then the target of a symlink /data/project/solr/releases/current
>> * releasing a new version of the solr home (eg adding/changing
>> libraries, changing logging options) is done by checking out a fresh
>> copy of the solr home, switching the symlink and restarting solr
>> * the solr core.properties and any data live in /data/project/indexes,
>> so they are preserved when new solr home is released
>>
>> Setting core specific dataDir with absolute paths in solrconfig.xml
>> only gets me part of the way, as the core.properties for each shard is
>> created inside the solr home.
>>
>> This is obviously no good, as when releasing a new version of the solr
>> home, they will no longer be in the current solr home.
>>
>> Cheers
>>
>> Tom


Re: Separating cores from Solr home

2016-03-03 Thread Upayavira
You can add a  entry in your solrconfig to point to an entirely
different location for libraries. Update them, then you just need to
reload cores, not the whole of Solr.

Then, try setting the LOG4J_PROPS envvar before starting Solr, so you
can have your logging configs somewhere else, and solr_home becomes
purely about data alone.

Does that work?

Upayavira

On Thu, Mar 3, 2016, at 11:58 AM, Tom Evans wrote:
> Hmm, I've worked around this by setting the directory where the
> indexes should live to be the actual solr home, and symlink the files
> from the current release in to that directory, but it feels icky.
> 
> Any better ideas?
> 
> Cheers
> 
> Tom
> 
> On Thu, Mar 3, 2016 at 11:12 AM, Tom Evans 
> wrote:
> > Hi all
> >
> > I'm struggling to configure solr cloud to put the index files and
> > core.properties in the correct places in SolrCloud 5.5. Let me explain
> > what I am trying to achieve:
> >
> > * solr is installed in /opt/solr
> > * the user who runs solr only has read only access to that tree
> > * the solr home files - custom libraries, log4j.properties, solr.in.sh
> > and solr.xml - live in /data/project/solr/releases/, which
> > is then the target of a symlink /data/project/solr/releases/current
> > * releasing a new version of the solr home (eg adding/changing
> > libraries, changing logging options) is done by checking out a fresh
> > copy of the solr home, switching the symlink and restarting solr
> > * the solr core.properties and any data live in /data/project/indexes,
> > so they are preserved when new solr home is released
> >
> > Setting core specific dataDir with absolute paths in solrconfig.xml
> > only gets me part of the way, as the core.properties for each shard is
> > created inside the solr home.
> >
> > This is obviously no good, as when releasing a new version of the solr
> > home, they will no longer be in the current solr home.
> >
> > Cheers
> >
> > Tom


Re: Separating cores from Solr home

2016-03-03 Thread Tom Evans
Hmm, I've worked around this by setting the directory where the
indexes should live to be the actual solr home, and symlink the files
from the current release in to that directory, but it feels icky.

Any better ideas?

Cheers

Tom

On Thu, Mar 3, 2016 at 11:12 AM, Tom Evans  wrote:
> Hi all
>
> I'm struggling to configure solr cloud to put the index files and
> core.properties in the correct places in SolrCloud 5.5. Let me explain
> what I am trying to achieve:
>
> * solr is installed in /opt/solr
> * the user who runs solr only has read only access to that tree
> * the solr home files - custom libraries, log4j.properties, solr.in.sh
> and solr.xml - live in /data/project/solr/releases/, which
> is then the target of a symlink /data/project/solr/releases/current
> * releasing a new version of the solr home (eg adding/changing
> libraries, changing logging options) is done by checking out a fresh
> copy of the solr home, switching the symlink and restarting solr
> * the solr core.properties and any data live in /data/project/indexes,
> so they are preserved when new solr home is released
>
> Setting core specific dataDir with absolute paths in solrconfig.xml
> only gets me part of the way, as the core.properties for each shard is
> created inside the solr home.
>
> This is obviously no good, as when releasing a new version of the solr
> home, they will no longer be in the current solr home.
>
> Cheers
>
> Tom


Separating cores from Solr home

2016-03-03 Thread Tom Evans
Hi all

I'm struggling to configure solr cloud to put the index files and
core.properties in the correct places in SolrCloud 5.5. Let me explain
what I am trying to achieve:

* solr is installed in /opt/solr
* the user who runs solr only has read only access to that tree
* the solr home files - custom libraries, log4j.properties, solr.in.sh
and solr.xml - live in /data/project/solr/releases/, which
is then the target of a symlink /data/project/solr/releases/current
* releasing a new version of the solr home (eg adding/changing
libraries, changing logging options) is done by checking out a fresh
copy of the solr home, switching the symlink and restarting solr
* the solr core.properties and any data live in /data/project/indexes,
so they are preserved when new solr home is released

Setting core specific dataDir with absolute paths in solrconfig.xml
only gets me part of the way, as the core.properties for each shard is
created inside the solr home.

This is obviously no good, as when releasing a new version of the solr
home, they will no longer be in the current solr home.

Cheers

Tom


[ANN]: Blog article: every Solr home and example in Solr 5.3

2015-11-02 Thread Alexandre Rafalovitch
If you've recently downloaded Solr 5.x and trying to figure out what
example creates a home where and why the example creation command uses
configset directory but not configset URL parameter, you may find this
useful:

http://blog.outerthoughts.com/2015/11/oh-solr-home-where-art-thou/

Regards,
   Alex.
P.s. I don't normally mention my blog articles or SolrStart updates on
this list, but I've been having so many issues wrapping my head around
the new directory layouts and consequences of start scripts
auto-magic, that I figured I'll make an exception. Hopefully, that's
not too intrusive.


Solr Analyzers, Tokenizers, Filters, URPs and even a newsletter:
http://www.solr-start.com/


Re: solr.xml coreRootDirectory relative to solr home

2014-11-07 Thread Chris Hostetter

: An oversight I think. If you create a patch, let me know and we can
: get it committed.

that definitely sounds bad we should certainly try to fix that before 5.0 
comes out since it does have back-compat implictations...

https://issues.apache.org/jira/browse/SOLR-6718

...better to have a 5.0 release note about tweaking rel-paths when 
people expect more changes then a 5.x release note that might be easily 
overlooked.

-Hoss
http://www.lucidworks.com/


Re: solr.xml coreRootDirectory relative to solr home

2014-11-06 Thread Shawn Heisey
On 11/6/2014 12:02 PM, Erick Erickson wrote:
> An oversight I think. If you create a patch, let me know and we can
> get it committed.
>
> Hmmm, not sure though, this'll change the current behavior that people might 
> be
> counting on....

Relative to the solr home sounds like the best option to me.  It's what
I would expect, since most of the rest of Solr uses directories relative
to other directories that may or may not be explicitly defined.  I
haven't researched in-depth, but I think that the solr home itself is
the only thing in Solr that defaults to something relative to the
current working directory ... and that seems like a very good policy to
keep.

Thanks,
Shawn



Re: solr.xml coreRootDirectory relative to solr home

2014-11-06 Thread Erick Erickson
An oversight I think. If you create a patch, let me know and we can
get it committed.

Hmmm, not sure though, this'll change the current behavior that people might be
counting on

On Thu, Nov 6, 2014 at 1:02 AM, Andreas Hubold
 wrote:
> Hi,
>
> I'm trying to configure a different core discovery root directory in
> solr.xml with the coreRootDirectory setting as described in
> https://cwiki.apache.org/confluence/display/solr/Format+of+solr.xml
>
> I'd like to just set it to a subdirectory of solr home (a "cores" directory
> to avoid confusion with configsets and other directories). I tried
>
> cores
>
> but that's interpreted relative to the current working directory. Other
> paths such as sharedLib are interpreted relative to Solr Home and I had
> expected this here too.
>
> I do not set solr home via system property but via JNDI so I don't think I
> can use a ${solr.home}/cores or something like that? It would be nice solr
> home were available for property substitution even if set via JNDI.
>
> Is there another way to set a path relative to solr home here?
>
> Regards,
> Andreas


solr.xml coreRootDirectory relative to solr home

2014-11-06 Thread Andreas Hubold

Hi,

I'm trying to configure a different core discovery root directory in 
solr.xml with the coreRootDirectory setting as described in 
https://cwiki.apache.org/confluence/display/solr/Format+of+solr.xml


I'd like to just set it to a subdirectory of solr home (a "cores" 
directory to avoid confusion with configsets and other directories). I 
tried


cores

but that's interpreted relative to the current working directory. Other 
paths such as sharedLib are interpreted relative to Solr Home and I had 
expected this here too.


I do not set solr home via system property but via JNDI so I don't think 
I can use a ${solr.home}/cores or something like that? It would be nice 
solr home were available for property substitution even if set via JNDI.


Is there another way to set a path relative to solr home here?

Regards,
Andreas


solr home in jar?

2012-07-17 Thread Matt Mitchell
Hi,

I'd like to bundle up a jar file, with a complete solr home and index.
This jar file is a dependency for another application, which uses an
instance of embedded solr, multi-core. Is there any way to have the
application's embedded solr, read the configs/index data from jar
dependency?

I attempted using CoreContainer with a resource loader (and many other
ways), but no luck! Any ideas?

- Matt


Re: solr/home property seting

2011-05-18 Thread Grijesh
Why you have putted your solr home inside the Tomcat's webapps directory.
This is not the correct way.Put your Solr home somewhere other place outside
the servlet container and set your solr/home path accordingly as
 
   solr/home 
   /opt/solr/home 
   java.lang.String 
 

-
Thanx: 
Grijesh 
www.gettinhahead.co.in 
--
View this message in context: 
http://lucene.472066.n3.nabble.com/solr-home-property-seting-tp2956003p2956047.html
Sent from the Solr - User mailing list archive at Nabble.com.


solr/home property seting

2011-05-17 Thread kun xiong
Hi all,

I am wondering how could I set a path for solr/home property.

Our solr home is inside the solr.war, so I don't want a absolute path(will
deploy to different boxes).

Currently I hard code a relative path as solr/home property in web.xml.

  
   
   solr/home
   *../webapps/solr/home*
   java.lang.String


But in this way, I have to start tomcat under bin/. Seems the root path here
is start path.

How could I set solr/home property to get ride of tomcat start path.

Thanks

Kun


Re: Setting solr home directory in websphere

2010-10-18 Thread Israel Ekpo
You need to make sure that the following system variable is one of the
values specific in the JAVA_OPTS environment variable

-Dsolr.solr.home=path_to_solr_home



On Mon, Oct 18, 2010 at 10:20 PM, Kevin Cunningham <
kcunning...@telligent.com> wrote:

> I've installed Solr a hundred times using Tomcat (on Windows) but now need
> to get it going with WebSphere (on Windows).  For whatever reason this seems
> to be black magic :)  I've installed the war file but have no idea how to
> set Solr home to let WebSphere know where the index and config files are.
>  Can someone enlighten me on how to do this please?
>



-- 
°O°
"Good Enough" is not good enough.
To give anything less than your best is to sacrifice the gift.
Quality First. Measure Twice. Cut Once.
http://www.israelekpo.com/


Setting solr home directory in websphere

2010-10-18 Thread Kevin Cunningham
I've installed Solr a hundred times using Tomcat (on Windows) but now need to 
get it going with WebSphere (on Windows).  For whatever reason this seems to be 
black magic :)  I've installed the war file but have no idea how to set Solr 
home to let WebSphere know where the index and config files are.  Can someone 
enlighten me on how to do this please?


Re: SEVERE: Could not start SOLR. Check solr/home property

2010-04-28 Thread Jon Drukman

On 4/27/10 12:04 PM, Chris Hostetter wrote:


: SEVERE: Could not start SOLR. Check solr/home property

it means something when horribly wrong when starting solr, and since this
is frequently caused by either an incorrect explicit solr/home or an
incorrect implicitly guessed solr home, that is mentioned in the error
message as something to check.

it's part of that error message because in cases where the solr home is
the problem, that may be the only meaningful error message.

in your case however, you have a much more specific error message...

:  java.lang.RuntimeException: java.io.IOException: read past EOF
:at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1068)
:at org.apache.solr.core.SolrCore.(SolrCore.java:579)
:at

...so something seems to be seriously wrong with your index. farther down
below this exception in your logs, there should be a more detailed
execption explaining what file it had problems reading.

If you could post that *full* error message it might help us track this
down ... i would also suggest trying to use the CheckIndex tool to see if
somehow your index got corrupted.


Yes, the index was corrupted.  I don't know how it happened.  Like I 
said, I set the box up months ago and forgot about it.  They decided 
they wanted to use it so I tried to fire it up.  After deleting the 
index, solr started again just fine without any configuration changes. 
Like I said, I have never explicitly set solr/home, in any of my 
production configs, and it always works.


Thanks
-jsd-







Re: SEVERE: Could not start SOLR. Check solr/home property

2010-04-27 Thread Chris Hostetter

: SEVERE: Could not start SOLR. Check solr/home property

it means something when horribly wrong when starting solr, and since this 
is frequently caused by either an incorrect explicit solr/home or an 
incorrect implicitly guessed solr home, that is mentioned in the error 
message as something to check.

it's part of that error message because in cases where the solr home is 
the problem, that may be the only meaningful error message.

in your case however, you have a much more specific error message...

:  java.lang.RuntimeException: java.io.IOException: read past EOF
:at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1068)
:at org.apache.solr.core.SolrCore.(SolrCore.java:579)
:at

...so something seems to be seriously wrong with your index. farther down 
below this exception in your logs, there should be a more detailed 
execption explaining what file it had problems reading.

If you could post that *full* error message it might help us track this 
down ... i would also suggest trying to use the CheckIndex tool to see if 
somehow your index got corrupted.


-Hoss



Re: SEVERE: Could not start SOLR. Check solr/home property

2010-04-26 Thread Otis Gospodnetic
Hi Jon,

Not sure who spits out that error message, but you can always use 
-Dsolr.solr.home=/path/to/solr/home as the JVM param (in your app server 
startup script, most likely).
 Otis

Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
Lucene ecosystem search :: http://search-lucene.com/



- Original Message 
> From: Jon Drukman 
> To: solr-user@lucene.apache.org
> Sent: Mon, April 26, 2010 4:04:39 PM
> Subject: SEVERE: Could not start SOLR. Check solr/home property
> 
> What does this error mean?

SEVERE: Could not start SOLR. Check solr/home 
> property

I've had this solr installation working before, but I haven't 
> looked at it in a few months.  I checked it today and the web side is 
> returning a 500 error, the log file shows this when starting 
> up:


SEVERE: Could not start SOLR. Check solr/home property

> java.lang.RuntimeException: java.io.IOException: read past EOF
   at 
> org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1068)
   at 
> org.apache.solr.core.SolrCore.(SolrCore.java:579)
   at 
> org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:137)
  
> at 
> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:83)
  
> at 
> org.mortbay.jetty.servlet.FilterHolder.doStart(FilterHolder.java:99)
  
> at 
> org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40)
  
> at 
> org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:594)
  
> at org.mortbay.jetty.servlet.Context.startContext(Context.java:139)
  
> at 
> org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1218)

For 
> the record, I've never explictly set "solr/home" ever.  It always "just 
> worked".

-jsd-


Re: SEVERE: Could not start SOLR. Check solr/home property

2010-04-26 Thread Jon Drukman

On 4/26/10 1:18 PM, Siddhant Goel wrote:

Did you by any chance set up multicore? Try passing in the path to the Solr
home directory as -Dsolr.solr.home=/path/to/solr/home while you start Solr.


Nope, no multicore.

I destroyed the index and re-created it from scratch and now it works 
fine.  No idea what was going on there.  Luckily it takes < 10 minutes 
to create and the box is not in production yet.




Re: SEVERE: Could not start SOLR. Check solr/home property

2010-04-26 Thread Siddhant Goel
Did you by any chance set up multicore? Try passing in the path to the Solr
home directory as -Dsolr.solr.home=/path/to/solr/home while you start Solr.

On Mon, Apr 26, 2010 at 1:04 PM, Jon Drukman  wrote:

> What does this error mean?
>
> SEVERE: Could not start SOLR. Check solr/home property
>
> I've had this solr installation working before, but I haven't looked at it
> in a few months.  I checked it today and the web side is returning a 500
> error, the log file shows this when starting up:
>
>
> SEVERE: Could not start SOLR. Check solr/home property
>  java.lang.RuntimeException: java.io.IOException: read past EOF
>   at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1068)
>   at org.apache.solr.core.SolrCore.(SolrCore.java:579)
>   at
> org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:137)
>   at
> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:83)
>   at org.mortbay.jetty.servlet.FilterHolder.doStart(FilterHolder.java:99)
>   at
> org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40)
>   at
> org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:594)
>   at org.mortbay.jetty.servlet.Context.startContext(Context.java:139)
>   at
> org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1218)
>
> For the record, I've never explictly set "solr/home" ever.  It always "just
> worked".
>
> -jsd-
>
>


-- 
- Siddhant


SEVERE: Could not start SOLR. Check solr/home property

2010-04-26 Thread Jon Drukman

What does this error mean?

SEVERE: Could not start SOLR. Check solr/home property

I've had this solr installation working before, but I haven't looked at 
it in a few months.  I checked it today and the web side is returning a 
500 error, the log file shows this when starting up:



SEVERE: Could not start SOLR. Check solr/home property
 java.lang.RuntimeException: java.io.IOException: read past EOF
   at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1068)
   at org.apache.solr.core.SolrCore.(SolrCore.java:579)
   at 
org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:137)
   at 
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:83)

   at org.mortbay.jetty.servlet.FilterHolder.doStart(FilterHolder.java:99)
   at 
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:40)
   at 
org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:594)

   at org.mortbay.jetty.servlet.Context.startContext(Context.java:139)
   at 
org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1218)


For the record, I've never explictly set "solr/home" ever.  It always 
"just worked".


-jsd-



Re: access denied to solr home lib dir

2009-11-24 Thread Charles Moad
 Thank you all for the insight into this problem.  I was 100%
positive that selinux and file permissions were not the problems.
Turns out that tomcat 6 on ubuntu comes with a tomcat security manager
enabled by default.  I had no desire to figure out how this works
since this is for local testing.  I did find you could simply set
"TOMCAT6_SECURITY=no" in "/etc/default/tomcat6".  Restarting tomcat
after that fixed my problems.

Thanks again,
 Charlie

On Mon, Nov 23, 2009 at 4:38 PM, Chris Hostetter
 wrote:
>
> : Check.  I even verified that the tomcat user could create the
> : directory (i.e. "sudo -u tomcat6 mkdir /opt/solr/steve/lib").  Still
> : solr complains.
>
> Note that you have an AccessControlException, not a simple
> FileNotFoundException ... the error here is coming from File.canRead (when
> Solr is asking if it has permision to read the file) but your
> ServletContainer evidently has a security policy in place that prevent's
> solr from even checking (if the security policy allowed it to check, then
> it would return true/false based on the actaul file permisions)...
>
> http://java.sun.com/j2se/1.4.2/docs/api/java/io/File.html#canRead%28%29
>
>    Tests whether the application can read the file denoted by this
>    abstract pathname.
>
>    Returns:
>        true if and only if the file specified by this abstract pathname
>        exists and can be read by the application; false otherwise
>    Throws:
>        SecurityException - If a security manager exists and its
>        SecurityManager.checkRead(java.lang.String) method denies read
>        access to the file
>
> ...note that Tomcat doesn't have any special SecurityManager settings that
> prevent this by default.  something about your tomcat deployment must be
> specifying specific Security Permision rules.
>
> : >> Caused by: java.security.AccessControlException: access denied
> : >> (java.io.FilePermission /opt/solr/steve/./lib read)
> : >>       at 
> java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
> : >>       at 
> java.security.AccessController.checkPermission(AccessController.java:546)
> : >>       at 
> java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
> : >>       at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
> : >>       at java.io.File.canRead(File.java:689)
> : >>       at 
> org.apache.solr.core.SolrResourceLoader.replaceClassLoader(SolrResourceLoader.java:157)
> : >>       at 
> org.apache.solr.core.SolrResourceLoader.addToClassLoader(SolrResourceLoader.java:128)
> : >>       at 
> org.apache.solr.core.SolrResourceLoader.(SolrResourceLoader.java:97)
> : >>       at 
> org.apache.solr.core.SolrResourceLoader.(SolrResourceLoader.java:195)
> : >>       at org.apache.solr.core.Config.(Config.java:93)
> : >>       at 
> org.apache.solr.servlet.SolrDispatchFilter.(SolrDispatchFilter.java:65)
> : >>       ... 40 more
>
>
> -Hoss
>
> imamuseum.org made the following annotations
> -
> Be A Member. Be Amazed. | Make your Museum, your community and your world a 
> better place. | Join Today!
>
>
> -
>
>
>
> NOTICE:
>
> Mon Nov 23 2009 16:38:55
>
>
>
> This email message is for the sole use of the intended
> recipient(s) and may contain confidential and privileged information. Any
> unauthorized review, use, disclosure or distribution is prohibited. If you are
> not the intended recipient, please contact the sender by reply email and
> destroy all copies of the original message.
> -
>
>


Re: access denied to solr home lib dir

2009-11-23 Thread Chris Hostetter

: Check.  I even verified that the tomcat user could create the
: directory (i.e. "sudo -u tomcat6 mkdir /opt/solr/steve/lib").  Still
: solr complains.

Note that you have an AccessControlException, not a simple 
FileNotFoundException ... the error here is coming from File.canRead (when 
Solr is asking if it has permision to read the file) but your 
ServletContainer evidently has a security policy in place that prevent's 
solr from even checking (if the security policy allowed it to check, then 
it would return true/false based on the actaul file permisions)...

http://java.sun.com/j2se/1.4.2/docs/api/java/io/File.html#canRead%28%29

Tests whether the application can read the file denoted by this 
abstract pathname.

Returns:
true if and only if the file specified by this abstract pathname 
exists and can be read by the application; false otherwise 
Throws:
SecurityException - If a security manager exists and its
SecurityManager.checkRead(java.lang.String) method denies read
access to the file

...note that Tomcat doesn't have any special SecurityManager settings that 
prevent this by default.  something about your tomcat deployment must be 
specifying specific Security Permision rules.

: >> Caused by: java.security.AccessControlException: access denied
: >> (java.io.FilePermission /opt/solr/steve/./lib read)
: >>       at 
java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
: >>       at 
java.security.AccessController.checkPermission(AccessController.java:546)
: >>       at 
java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
: >>       at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
: >>       at java.io.File.canRead(File.java:689)
: >>       at 
org.apache.solr.core.SolrResourceLoader.replaceClassLoader(SolrResourceLoader.java:157)
: >>       at 
org.apache.solr.core.SolrResourceLoader.addToClassLoader(SolrResourceLoader.java:128)
: >>       at 
org.apache.solr.core.SolrResourceLoader.(SolrResourceLoader.java:97)
: >>       at 
org.apache.solr.core.SolrResourceLoader.(SolrResourceLoader.java:195)
: >>       at org.apache.solr.core.Config.(Config.java:93)
: >>       at 
org.apache.solr.servlet.SolrDispatchFilter.(SolrDispatchFilter.java:65)
: >>       ... 40 more


-Hoss


Re: access denied to solr home lib dir

2009-11-23 Thread Charles Moad
Check.  I even verified that the tomcat user could create the
directory (i.e. "sudo -u tomcat6 mkdir /opt/solr/steve/lib").  Still
solr complains.

On Sun, Nov 22, 2009 at 10:03 PM, Yonik Seeley  wrote:
> Maybe ensuring that the full parent path (all parent directories) have
> "rx" permissions?
>
> -Yonik
> http://www.lucidimagination.com
>
> On Sun, Nov 22, 2009 at 2:59 PM, Charles Moad  wrote:
>>    I have been trying to get a new solr install setup on Ubuntu 9.10
>> using tomcat6.  I have tried the solr 1.4 release and the latest svn
>> for good measure.  No matter what, I am running into the following
>> permission error.  I removed all the lib includes from solrconfig.xml.
>> I have created the "/opt/solr/steve/lib" directory and all permissions
>> are good.  This directory is optional, but I just cannot get past
>> this.  I've installed solr 1.3 many times without running into this on
>> redhat boxes.
>>
>> Thanks,
>>    Charlie
>>
>> Nov 22, 2009 2:48:53 PM org.apache.catalina.core.StandardContext filterStart
>> SEVERE: Exception starting filter SolrRequestFilter
>> org.apache.solr.common.SolrException:
>> java.security.AccessControlException: access denied
>> (java.io.FilePermission /opt/solr/steve/./lib read)
>>       at 
>> org.apache.solr.servlet.SolrDispatchFilter.(SolrDispatchFilter.java:68)
>>       at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native 
>> Method)
>>       at 
>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
>>       at 
>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
>>       at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
>>       at java.lang.Class.newInstance0(Class.java:355)
>>       at java.lang.Class.newInstance(Class.java:308)
>>       at 
>> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:255)
>>       at 
>> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
>>       at 
>> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)
>>       at 
>> org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3800)
>>       at 
>> org.apache.catalina.core.StandardContext.start(StandardContext.java:4450)
>>       at 
>> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
>>       at 
>> org.apache.catalina.core.ContainerBase.access$000(ContainerBase.java:123)
>>       at 
>> org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.java:145)
>>       at java.security.AccessController.doPrivileged(Native Method)
>>       at 
>> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:769)
>>       at 
>> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:526)
>>       at 
>> org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:630)
>>       at 
>> org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:556)
>>       at 
>> org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:491)
>>       at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1206)
>>       at 
>> org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:314)
>>       at 
>> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>>       at 
>> org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
>>       at org.apache.catalina.core.StandardHost.start(StandardHost.java:722)
>>       at 
>> org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
>>       at 
>> org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
>>       at 
>> org.apache.catalina.core.StandardService.start(StandardService.java:516)
>>       at 
>> org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
>>       at org.apache.catalina.startup.Catalina.start(Catalina.java:583)
>>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>       at 
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>       at 
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>       at java.lang.reflect.Method.invoke(Method.java:597)
>>       at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
>>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>       at 
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>       at 
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>       at java.lang.reflect.Method.invoke(Method.java:597)
>>       at 
>> org.apache.commons.daemon.support.DaemonLoader.start(DaemonLoader.java:177)
>> Caused by: java.security.AccessControlException: access denied
>> (java.io.FilePermission /opt/solr/steve/./lib read)
>>       at 
>> java.security.AccessControlContex

Re: access denied to solr home lib dir

2009-11-22 Thread Yonik Seeley
Maybe ensuring that the full parent path (all parent directories) have
"rx" permissions?

-Yonik
http://www.lucidimagination.com

On Sun, Nov 22, 2009 at 2:59 PM, Charles Moad  wrote:
>    I have been trying to get a new solr install setup on Ubuntu 9.10
> using tomcat6.  I have tried the solr 1.4 release and the latest svn
> for good measure.  No matter what, I am running into the following
> permission error.  I removed all the lib includes from solrconfig.xml.
> I have created the "/opt/solr/steve/lib" directory and all permissions
> are good.  This directory is optional, but I just cannot get past
> this.  I've installed solr 1.3 many times without running into this on
> redhat boxes.
>
> Thanks,
>    Charlie
>
> Nov 22, 2009 2:48:53 PM org.apache.catalina.core.StandardContext filterStart
> SEVERE: Exception starting filter SolrRequestFilter
> org.apache.solr.common.SolrException:
> java.security.AccessControlException: access denied
> (java.io.FilePermission /opt/solr/steve/./lib read)
>       at 
> org.apache.solr.servlet.SolrDispatchFilter.(SolrDispatchFilter.java:68)
>       at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>       at 
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
>       at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
>       at java.lang.Class.newInstance0(Class.java:355)
>       at java.lang.Class.newInstance(Class.java:308)
>       at 
> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:255)
>       at 
> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
>       at 
> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)
>       at 
> org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3800)
>       at 
> org.apache.catalina.core.StandardContext.start(StandardContext.java:4450)
>       at 
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
>       at 
> org.apache.catalina.core.ContainerBase.access$000(ContainerBase.java:123)
>       at 
> org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.java:145)
>       at java.security.AccessController.doPrivileged(Native Method)
>       at 
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:769)
>       at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:526)
>       at 
> org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:630)
>       at 
> org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:556)
>       at 
> org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:491)
>       at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1206)
>       at 
> org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:314)
>       at 
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>       at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
>       at org.apache.catalina.core.StandardHost.start(StandardHost.java:722)
>       at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
>       at 
> org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
>       at 
> org.apache.catalina.core.StandardService.start(StandardService.java:516)
>       at 
> org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
>       at org.apache.catalina.startup.Catalina.start(Catalina.java:583)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>       at java.lang.reflect.Method.invoke(Method.java:597)
>       at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>       at java.lang.reflect.Method.invoke(Method.java:597)
>       at 
> org.apache.commons.daemon.support.DaemonLoader.start(DaemonLoader.java:177)
> Caused by: java.security.AccessControlException: access denied
> (java.io.FilePermission /opt/solr/steve/./lib read)
>       at 
> java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
>       at 
> java.security.AccessController.checkPermission(AccessController.java:546)
>       at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
>       at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
>       at java.io.File.canRe

access denied to solr home lib dir

2009-11-22 Thread Charles Moad
I have been trying to get a new solr install setup on Ubuntu 9.10
using tomcat6.  I have tried the solr 1.4 release and the latest svn
for good measure.  No matter what, I am running into the following
permission error.  I removed all the lib includes from solrconfig.xml.
I have created the "/opt/solr/steve/lib" directory and all permissions
are good.  This directory is optional, but I just cannot get past
this.  I've installed solr 1.3 many times without running into this on
redhat boxes.

Thanks,
Charlie

Nov 22, 2009 2:48:53 PM org.apache.catalina.core.StandardContext filterStart
SEVERE: Exception starting filter SolrRequestFilter
org.apache.solr.common.SolrException:
java.security.AccessControlException: access denied
(java.io.FilePermission /opt/solr/steve/./lib read)
   at 
org.apache.solr.servlet.SolrDispatchFilter.(SolrDispatchFilter.java:68)
   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
   at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
   at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
   at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
   at java.lang.Class.newInstance0(Class.java:355)
   at java.lang.Class.newInstance(Class.java:308)
   at 
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:255)
   at 
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
   at 
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)
   at 
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3800)
   at 
org.apache.catalina.core.StandardContext.start(StandardContext.java:4450)
   at 
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
   at 
org.apache.catalina.core.ContainerBase.access$000(ContainerBase.java:123)
   at 
org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.java:145)
   at java.security.AccessController.doPrivileged(Native Method)
   at 
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:769)
   at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:526)
   at 
org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:630)
   at 
org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:556)
   at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:491)
   at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1206)
   at 
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:314)
   at 
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
   at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
   at org.apache.catalina.core.StandardHost.start(StandardHost.java:722)
   at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
   at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
   at 
org.apache.catalina.core.StandardService.start(StandardService.java:516)
   at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
   at org.apache.catalina.startup.Catalina.start(Catalina.java:583)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
   at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
   at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at 
org.apache.commons.daemon.support.DaemonLoader.start(DaemonLoader.java:177)
Caused by: java.security.AccessControlException: access denied
(java.io.FilePermission /opt/solr/steve/./lib read)
   at 
java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
   at 
java.security.AccessController.checkPermission(AccessController.java:546)
   at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
   at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
   at java.io.File.canRead(File.java:689)
   at 
org.apache.solr.core.SolrResourceLoader.replaceClassLoader(SolrResourceLoader.java:157)
   at 
org.apache.solr.core.SolrResourceLoader.addToClassLoader(SolrResourceLoader.java:128)
   at 
org.apache.solr.core.SolrResourceLoader.(SolrResourceLoader.java:97)
   at 
org.apache.solr.

Re: Problem getting Solr home from JNDI in Tomcat

2009-10-01 Thread Andrew Clegg



Andrew Clegg wrote:
> 
> 
> hossman wrote:
>> 
>> 
>> This is why the examples of using context files on the wiki talk about 
>> keeping the war *outside* of the webapps directory, and using docBase in 
>> your Context declaration...
>>   http://wiki.apache.org/solr/SolrTomcat
>> 
>> 
> 
> Great, I'll try it this way and see if it clears up. Is it okay to keep
> the war file *inside* the Solr home directory (/opt/solr in my case) so
> it's all self-contained?
> 

For the benefit of future searchers -- I tried it this way and it works
fine. Thanks again to everyone for helping.

Andrew.

-- 
View this message in context: 
http://www.nabble.com/Problem-getting-Solr-home-from-JNDI-in-Tomcat-tp25662200p25701748.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Problem getting Solr home from JNDI in Tomcat

2009-09-30 Thread Andrew Clegg


hossman wrote:
> 
> 
> : Hi all, I'm having problems getting Solr to start on Tomcat 6.
> 
> which version of Solr?
> 
> 

Sorry -- a nightly build from about a month ago. Re. your other message, I
was sure the two machines had the same version on, but maybe not -- when I'm
back in the office tomorrow I'll upgrade them both to a fresh nightly.


hossman wrote:
> 
> 
> : Tomcat is installed in /opt/apache-tomcat , solr is in
> : /opt/apache-tomcat/webapps/solr , and my Solr home directory is
> /opt/solr .
> 
> if "solr is in /opt/apache-tomcat/webapps/solr" means that you put the 
> solr.war in /opt/apache-tomcat/webapps/ and tomcat expanded it into  
> /opt/apache-tomcat/webapps/solr then that is your problem -- tomcat isn't 
> even looking at your context file (it only looks at the context files to 
> ersolve URLs that it cant resolve looking in the webapps directory)
> 
> 

Yes, it's auto-expanded from a war in webapps.

I have to admit to being a bit baffled though -- I can't find this rule
anywhere in the Tomcat docs, but I'm a beginner really and they're not the
clearest :-)


hossman wrote:
> 
> 
> This is why the examples of using context files on the wiki talk about 
> keeping the war *outside* of the webapps directory, and using docBase in 
> your Context declaration...
>   http://wiki.apache.org/solr/SolrTomcat
> 
> 

Great, I'll try it this way and see if it clears up. Is it okay to keep the
war file *inside* the Solr home directory (/opt/solr in my case) so it's all
self-contained?

Many thanks,

Andrew.

-- 
View this message in context: 
http://www.nabble.com/Problem-getting-Solr-home-from-JNDI-in-Tomcat-tp25662200p25677750.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Problem getting Solr home from JNDI in Tomcat

2009-09-29 Thread Chris Hostetter

: Now I've got a completely different error:
: "org.apache.lucene.index.CorruptIndexException: Unknown format version: -9".
: I think it might be time for a fresh install...

I've added a FAQ for this...

http://wiki.apache.org/solr/FAQ#What_does_.22CorruptIndexException:_Unknown_format_version.22_mean_.3F

What does "CorruptIndexException: Unknown format version" mean ?

This happens when the Lucene code in Solr used to read the index files 
from disk encounters index files in a format it doesn't recognize.

The most common cause is from using a version of Solr+Lucene that is older 
then the version used to create that index. 


-Hoss



Re: Problem getting Solr home from JNDI in Tomcat

2009-09-29 Thread Chris Hostetter

: Hi all, I'm having problems getting Solr to start on Tomcat 6.

which version of Solr?

: Tomcat is installed in /opt/apache-tomcat , solr is in
: /opt/apache-tomcat/webapps/solr , and my Solr home directory is /opt/solr .

if "solr is in /opt/apache-tomcat/webapps/solr" means that you put the 
solr.war in /opt/apache-tomcat/webapps/ and tomcat expanded it into  
/opt/apache-tomcat/webapps/solr then that is your problem -- tomcat isn't 
even looking at your context file (it only looks at the context files to 
ersolve URLs that it cant resolve looking in the webapps directory)

This is why the examples of using context files on the wiki talk about 
keeping the war *outside* of the webapps directory, and using docBase in 
your Context declaration...
  http://wiki.apache.org/solr/SolrTomcat



-Hoss



Re: Problem getting Solr home from JNDI in Tomcat

2009-09-29 Thread Andrew Clegg


Constantijn Visinescu wrote:
> 
> This might be a bit of a hack but i got this in the web.xml of my
> applicatin
> and it works great.
> 
> 
>     
>solr/home
>/Solr/WebRoot/WEB-INF/solr
>java.lang.String
> 
> 
> 

That worked, thanks. You're right though, it is a bit of a hack -- I'd
prefer to set the path from *outside* the app so it won't get overwritten
when I upgrade.

Now I've got a completely different error:
"org.apache.lucene.index.CorruptIndexException: Unknown format version: -9".
I think it might be time for a fresh install...

Cheers,

Andrew.



-- 
View this message in context: 
http://www.nabble.com/Problem-getting-Solr-home-from-JNDI-in-Tomcat-tp25662200p25663931.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Problem getting Solr home from JNDI in Tomcat

2009-09-29 Thread Constantijn Visinescu
This might be a bit of a hack but i got this in the web.xml of my applicatin
and it works great.



   solr/home
   /Solr/WebRoot/WEB-INF/solr
   java.lang.String


On Tue, Sep 29, 2009 at 2:32 PM, Andrew Clegg wrote:

>
> Hi all, I'm having problems getting Solr to start on Tomcat 6.
>
> Tomcat is installed in /opt/apache-tomcat , solr is in
> /opt/apache-tomcat/webapps/solr , and my Solr home directory is /opt/solr .
> My config file is in /opt/solr/conf/solrconfig.xml .
>
> I have a Solr-specific context file in
> /opt/apache-tomcat/conf/Catalina/localhost/solr.xml which looks like this:
>
> 
> value="/opt/solr" override="true" />
> allow="128\.40\.46\..*,127\.0\.0\.1" />
> 
>
> But when I start Solr and browse to it, it tells me:
>
> java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
> classpath or 'solr/conf/', cwd=/ at
>
> org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
> at
>
> org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
> at org.apache.solr.core.Config.(Config.java:100) at
> org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
> org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
>
> org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
> at
> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
> at
>
> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275)
> at
>
> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
> at
>
> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)
> at
>
> org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3709)
> at
> org.apache.catalina.core.StandardContext.start(StandardContext.java:4356)
> at
> org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1244)
> at
>
> org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:604)
> at
>
> org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:129)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:690) at
> javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at
>
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> at
>
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> at
>
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
> at
>
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
> at
>
> org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
> at
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568)
> at
>
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
> at
>
> org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
> at
>
> org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
> at
>
> org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
> at
>
> org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
> at
>
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> at
>
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
> at
>
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
> at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
> at java.lang.Thread.run(Thread.java:619)
>
> Weirdly, the exact same context file works fine on a different machine.
> I've
> tried giving Context a docBase element (both absolute, and relative paths)
> but it makes no difference -- Solr still isn't seeing the right home
> directory. I also tried setting debug="1" but didn't see any more useful
> info anywhere.
>
> Any ideas? This is a total show-stopper for me as this is our production
> server. (Otherwise I'd think about taking it down and hardwiring the Solr
> home path into the server's context...)
>
> Yours hopefully,
>
> Andrew.
>
> --
> View this message in context:
> http://www.nabble.com/Problem-getting-Solr-home-from-JNDI-in-Tomcat-tp25662200p25662200.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>


Problem getting Solr home from JNDI in Tomcat

2009-09-29 Thread Andrew Clegg

Hi all, I'm having problems getting Solr to start on Tomcat 6.

Tomcat is installed in /opt/apache-tomcat , solr is in
/opt/apache-tomcat/webapps/solr , and my Solr home directory is /opt/solr .
My config file is in /opt/solr/conf/solrconfig.xml .

I have a Solr-specific context file in
/opt/apache-tomcat/conf/Catalina/localhost/solr.xml which looks like this:






But when I start Solr and browse to it, it tells me:

java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
classpath or 'solr/conf/', cwd=/ at
org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
at
org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
at org.apache.solr.core.Config.(Config.java:100) at
org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
at
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
at
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275)
at
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
at
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)
at
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3709)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4356)
at
org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1244)
at
org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:604)
at
org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:129)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:690) at
javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at
org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
at
org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
at
org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
at
org.jstripe.tomcat.probe.Tomcat55AgentValve.invoke(Tomcat55AgentValve.java:20)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619) 

Weirdly, the exact same context file works fine on a different machine. I've
tried giving Context a docBase element (both absolute, and relative paths)
but it makes no difference -- Solr still isn't seeing the right home
directory. I also tried setting debug="1" but didn't see any more useful
info anywhere.

Any ideas? This is a total show-stopper for me as this is our production
server. (Otherwise I'd think about taking it down and hardwiring the Solr
home path into the server's context...)

Yours hopefully,

Andrew.

-- 
View this message in context: 
http://www.nabble.com/Problem-getting-Solr-home-from-JNDI-in-Tomcat-tp25662200p25662200.html
Sent from the Solr - User mailing list archive at Nabble.com.



solr home

2009-09-25 Thread Park, Michael
I already have a handful of solr instances running .  However, I'm
trying to install solr (1.4) on a new linux server with tomcat using a
context file (same way I usually do):

 



   



 

However it throws an exception due to the following:

SEVERE: Could not start SOLR. Check solr/home property

java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
classpath or 'solr/conf/', cwd=/opt/local/solr/fedora_solr

at
org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.
java:198)

at
org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.ja
va:166)

 

Any ideas why this is happening?

 

Thanks, Mike



Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-05 Thread Noble Paul നോബിള്‍ नोब्ळ्
I have raised an issue https://issues.apache.org/jira/browse/SOLR-1414

On Sun, Sep 6, 2009 at 12:32 AM, Archon810 wrote:
>
> Yeah, I'm using single core (solrconfig.xml).
>
>
>
> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>
>> ideally you should be able to us the variable
>>
>> ${solr.core.instanceDir}
>>
>> but as I checked the code that is not being set for a single core
>> deployment. are you using single core?
>>
>> On Fri, Sep 4, 2009 at 9:16 PM, Archon810 wrote:
>>>
>>> OK, so I can't access it by ${solr.home}, but is there a way to access
>>> it?
>>> After all, it's a variable defined in JNDI, shouldn't there be a way to
>>> refer to it?
>>>
>>> Also, what about the INFO message that says it can't find /solr/home,
>>> while
>>> the instructions refer to solr/home ?
>>>
>>>
>>>
>>> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>>>
>>>> ${solr.home} is used for documentation purpose. It is not set as a
>>>> variable.
>>>>
>>>> On Fri, Sep 4, 2009 at 3:58 PM, Archon810 wrote:
>>>>>
>>>>> I saw it being used in the default solrconfig.xml in this phrase:
>>>>> If you wish to hide files under ${solr.home}/conf, explicitly register
>>>>> the
>>>>> ShowFileRequestHandler using...
>>>>>
>>>>> It was only natural to assume it would work for something as trivial as
>>>>> dataDir.
>>>>>
>>>>> So, there's no way to refer to the solr/home value defined in JNDI?
>>>>>
>>>>>
>>>>> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>>>>>
>>>>>> it is nowhere mentioned that you can use a variable ${solr.home} in
>>>>>> your solrconfig.xml. There is a bug related to this issue
>>>>>> https://issues.apache.org/jira/browse/SOLR-1267
>>>>>>
>>>>>> On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>>>>>>>
>>>>>>> Here's my problem.
>>>>>>>
>>>>>>> I'm trying to follow a multi Solr setup, straight from the Solr wiki
>>>>>>> -
>>>>>>> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>>>>>>>
>>>>>>> Here's the relevant code:
>>>>>>> <Context docBase="/some/path/solr.war" debug="0"
>>>>>>> crossContext="true"
>>>>>>> >
>>>>>>>   <Environment name="solr/home" type="java.lang.String"
>>>>>>> value="/some/path/solr1home" override="true" />
>>>>>>> </Context>
>>>>>>>
>>>>>>> Now I want to set the Solr <dataDir> in solrconfig.xml,
>>>>>>> relative
>>>>>>> to
>>>>>>> the solr home property. The instructions
>>>>>>> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
>>>>>>> say <dataDir> is used to specify an alternate directory to hold
>>>>>>> all
>>>>>>> index data other than the default ./data under the Solr home. If
>>>>>>> replication
>>>>>>> is in use, this should match the replication configuration. If this
>>>>>>> directory is not absolute, then it is relative to the current working
>>>>>>> directory of the servlet container.
>>>>>>>
>>>>>>> However, no matter how I try to set the dataDir property, solr home
>>>>>>> is
>>>>>>> not
>>>>>>> being found. For example,
>>>>>>>  <dataDir>${solr.home}/data</dataDir>
>>>>>>>
>>>>>>> What's even more confusing are these INFO notices in the log:
>>>>>>> INFO: No /solr/home in JNDI
>>>>>>> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
>>>>>>> locateSolrHome
>>>>>>> INFO: solr home defaulted to 'solr/' (could not find system property
>>>>>>> or
>>>>>>> JNDI)
>>>>>>>
>>>>>>> The JNDI instructions instruct to specify &qu

Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-05 Thread Archon810

Yeah, I'm using single core (solrconfig.xml).



Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
> 
> ideally you should be able to us the variable
> 
> ${solr.core.instanceDir}
> 
> but as I checked the code that is not being set for a single core
> deployment. are you using single core?
> 
> On Fri, Sep 4, 2009 at 9:16 PM, Archon810 wrote:
>>
>> OK, so I can't access it by ${solr.home}, but is there a way to access
>> it?
>> After all, it's a variable defined in JNDI, shouldn't there be a way to
>> refer to it?
>>
>> Also, what about the INFO message that says it can't find /solr/home,
>> while
>> the instructions refer to solr/home ?
>>
>>
>>
>> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>>
>>> ${solr.home} is used for documentation purpose. It is not set as a
>>> variable.
>>>
>>> On Fri, Sep 4, 2009 at 3:58 PM, Archon810 wrote:
>>>>
>>>> I saw it being used in the default solrconfig.xml in this phrase:
>>>> If you wish to hide files under ${solr.home}/conf, explicitly register
>>>> the
>>>> ShowFileRequestHandler using...
>>>>
>>>> It was only natural to assume it would work for something as trivial as
>>>> dataDir.
>>>>
>>>> So, there's no way to refer to the solr/home value defined in JNDI?
>>>>
>>>>
>>>> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>>>>
>>>>> it is nowhere mentioned that you can use a variable ${solr.home} in
>>>>> your solrconfig.xml. There is a bug related to this issue
>>>>> https://issues.apache.org/jira/browse/SOLR-1267
>>>>>
>>>>> On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>>>>>>
>>>>>> Here's my problem.
>>>>>>
>>>>>> I'm trying to follow a multi Solr setup, straight from the Solr wiki
>>>>>> -
>>>>>> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>>>>>>
>>>>>> Here's the relevant code:
>>>>>> <Context docBase="/some/path/solr.war" debug="0"
>>>>>> crossContext="true"
>>>>>> >
>>>>>>   <Environment name="solr/home" type="java.lang.String"
>>>>>> value="/some/path/solr1home" override="true" />
>>>>>> </Context>
>>>>>>
>>>>>> Now I want to set the Solr <dataDir> in solrconfig.xml,
>>>>>> relative
>>>>>> to
>>>>>> the solr home property. The instructions
>>>>>> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
>>>>>> say <dataDir> is used to specify an alternate directory to hold
>>>>>> all
>>>>>> index data other than the default ./data under the Solr home. If
>>>>>> replication
>>>>>> is in use, this should match the replication configuration. If this
>>>>>> directory is not absolute, then it is relative to the current working
>>>>>> directory of the servlet container.
>>>>>>
>>>>>> However, no matter how I try to set the dataDir property, solr home
>>>>>> is
>>>>>> not
>>>>>> being found. For example,
>>>>>>  <dataDir>${solr.home}/data</dataDir>
>>>>>>
>>>>>> What's even more confusing are these INFO notices in the log:
>>>>>> INFO: No /solr/home in JNDI
>>>>>> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
>>>>>> locateSolrHome
>>>>>> INFO: solr home defaulted to 'solr/' (could not find system property
>>>>>> or
>>>>>> JNDI)
>>>>>>
>>>>>> The JNDI instructions instruct to specify "solr/home", the log
>>>>>> complains
>>>>>> about "/solr/home" (extra slash), the solrconfig.xml file seems to
>>>>>> expect
>>>>>> ${solr.home} - how more confusing can it get?
>>>>>>
>>>>>> This person is having the same issue:
>>>>>> http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/
>>>>>>
>>>>>> So

Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-05 Thread Noble Paul നോബിള്‍ नोब्ळ्
ideally you should be able to us the variable

${solr.core.instanceDir}

but as I checked the code that is not being set for a single core
deployment. are you using single core?

On Fri, Sep 4, 2009 at 9:16 PM, Archon810 wrote:
>
> OK, so I can't access it by ${solr.home}, but is there a way to access it?
> After all, it's a variable defined in JNDI, shouldn't there be a way to
> refer to it?
>
> Also, what about the INFO message that says it can't find /solr/home, while
> the instructions refer to solr/home ?
>
>
>
> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>
>> ${solr.home} is used for documentation purpose. It is not set as a
>> variable.
>>
>> On Fri, Sep 4, 2009 at 3:58 PM, Archon810 wrote:
>>>
>>> I saw it being used in the default solrconfig.xml in this phrase:
>>> If you wish to hide files under ${solr.home}/conf, explicitly register
>>> the
>>> ShowFileRequestHandler using...
>>>
>>> It was only natural to assume it would work for something as trivial as
>>> dataDir.
>>>
>>> So, there's no way to refer to the solr/home value defined in JNDI?
>>>
>>>
>>> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>>>
>>>> it is nowhere mentioned that you can use a variable ${solr.home} in
>>>> your solrconfig.xml. There is a bug related to this issue
>>>> https://issues.apache.org/jira/browse/SOLR-1267
>>>>
>>>> On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>>>>>
>>>>> Here's my problem.
>>>>>
>>>>> I'm trying to follow a multi Solr setup, straight from the Solr wiki -
>>>>> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>>>>>
>>>>> Here's the relevant code:
>>>>> <Context docBase="/some/path/solr.war" debug="0" crossContext="true"
>>>>> >
>>>>>   <Environment name="solr/home" type="java.lang.String"
>>>>> value="/some/path/solr1home" override="true" />
>>>>> </Context>
>>>>>
>>>>> Now I want to set the Solr <dataDir> in solrconfig.xml, relative
>>>>> to
>>>>> the solr home property. The instructions
>>>>> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
>>>>> say <dataDir> is used to specify an alternate directory to hold
>>>>> all
>>>>> index data other than the default ./data under the Solr home. If
>>>>> replication
>>>>> is in use, this should match the replication configuration. If this
>>>>> directory is not absolute, then it is relative to the current working
>>>>> directory of the servlet container.
>>>>>
>>>>> However, no matter how I try to set the dataDir property, solr home is
>>>>> not
>>>>> being found. For example,
>>>>>  <dataDir>${solr.home}/data</dataDir>
>>>>>
>>>>> What's even more confusing are these INFO notices in the log:
>>>>> INFO: No /solr/home in JNDI
>>>>> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
>>>>> locateSolrHome
>>>>> INFO: solr home defaulted to 'solr/' (could not find system property or
>>>>> JNDI)
>>>>>
>>>>> The JNDI instructions instruct to specify "solr/home", the log
>>>>> complains
>>>>> about "/solr/home" (extra slash), the solrconfig.xml file seems to
>>>>> expect
>>>>> ${solr.home} - how more confusing can it get?
>>>>>
>>>>> This person is having the same issue:
>>>>> http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/
>>>>>
>>>>> So, how does one refer to solr home from solrconfig.xml in a JNDI
>>>>> configuration scenario? Also, is there a way to debug/see variables
>>>>> that
>>>>> are
>>>>> defined in a specific context, such as solrconfig.xml? I feel like I'm
>>>>> completely blind here.
>>>>>
>>>>> Thank you!
>>>>> --
>>>>> View this message in context:
>>>>> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25286277.html
>>>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> -
>>>> Noble Paul | Principal Engineer| AOL | http://aol.com
>>>>
>>>>
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25292025.html
>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>
>>>
>>
>>
>>
>> --
>> -
>> Noble Paul | Principal Engineer| AOL | http://aol.com
>>
>>
>
> --
> View this message in context: 
> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25296862.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



-- 
-
Noble Paul | Principal Engineer| AOL | http://aol.com


Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-04 Thread Archon810

OK, so I can't access it by ${solr.home}, but is there a way to access it?
After all, it's a variable defined in JNDI, shouldn't there be a way to
refer to it?

Also, what about the INFO message that says it can't find /solr/home, while
the instructions refer to solr/home ?



Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
> 
> ${solr.home} is used for documentation purpose. It is not set as a
> variable.
> 
> On Fri, Sep 4, 2009 at 3:58 PM, Archon810 wrote:
>>
>> I saw it being used in the default solrconfig.xml in this phrase:
>> If you wish to hide files under ${solr.home}/conf, explicitly register
>> the
>> ShowFileRequestHandler using...
>>
>> It was only natural to assume it would work for something as trivial as
>> dataDir.
>>
>> So, there's no way to refer to the solr/home value defined in JNDI?
>>
>>
>> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>>
>>> it is nowhere mentioned that you can use a variable ${solr.home} in
>>> your solrconfig.xml. There is a bug related to this issue
>>> https://issues.apache.org/jira/browse/SOLR-1267
>>>
>>> On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>>>>
>>>> Here's my problem.
>>>>
>>>> I'm trying to follow a multi Solr setup, straight from the Solr wiki -
>>>> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>>>>
>>>> Here's the relevant code:
>>>> <Context docBase="/some/path/solr.war" debug="0" crossContext="true"
>>>> >
>>>>   <Environment name="solr/home" type="java.lang.String"
>>>> value="/some/path/solr1home" override="true" />
>>>> </Context>
>>>>
>>>> Now I want to set the Solr <dataDir> in solrconfig.xml, relative
>>>> to
>>>> the solr home property. The instructions
>>>> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
>>>> say <dataDir> is used to specify an alternate directory to hold
>>>> all
>>>> index data other than the default ./data under the Solr home. If
>>>> replication
>>>> is in use, this should match the replication configuration. If this
>>>> directory is not absolute, then it is relative to the current working
>>>> directory of the servlet container.
>>>>
>>>> However, no matter how I try to set the dataDir property, solr home is
>>>> not
>>>> being found. For example,
>>>>  <dataDir>${solr.home}/data</dataDir>
>>>>
>>>> What's even more confusing are these INFO notices in the log:
>>>> INFO: No /solr/home in JNDI
>>>> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
>>>> locateSolrHome
>>>> INFO: solr home defaulted to 'solr/' (could not find system property or
>>>> JNDI)
>>>>
>>>> The JNDI instructions instruct to specify "solr/home", the log
>>>> complains
>>>> about "/solr/home" (extra slash), the solrconfig.xml file seems to
>>>> expect
>>>> ${solr.home} - how more confusing can it get?
>>>>
>>>> This person is having the same issue:
>>>> http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/
>>>>
>>>> So, how does one refer to solr home from solrconfig.xml in a JNDI
>>>> configuration scenario? Also, is there a way to debug/see variables
>>>> that
>>>> are
>>>> defined in a specific context, such as solrconfig.xml? I feel like I'm
>>>> completely blind here.
>>>>
>>>> Thank you!
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25286277.html
>>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> -
>>> Noble Paul | Principal Engineer| AOL | http://aol.com
>>>
>>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25292025.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> -
> Noble Paul | Principal Engineer| AOL | http://aol.com
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25296862.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-04 Thread Noble Paul നോബിള്‍ नोब्ळ्
${solr.home} is used for documentation purpose. It is not set as a variable.

On Fri, Sep 4, 2009 at 3:58 PM, Archon810 wrote:
>
> I saw it being used in the default solrconfig.xml in this phrase:
> If you wish to hide files under ${solr.home}/conf, explicitly register the
> ShowFileRequestHandler using...
>
> It was only natural to assume it would work for something as trivial as
> dataDir.
>
> So, there's no way to refer to the solr/home value defined in JNDI?
>
>
> Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
>>
>> it is nowhere mentioned that you can use a variable ${solr.home} in
>> your solrconfig.xml. There is a bug related to this issue
>> https://issues.apache.org/jira/browse/SOLR-1267
>>
>> On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>>>
>>> Here's my problem.
>>>
>>> I'm trying to follow a multi Solr setup, straight from the Solr wiki -
>>> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>>>
>>> Here's the relevant code:
>>> <Context docBase="/some/path/solr.war" debug="0" crossContext="true"
>>> >
>>>   <Environment name="solr/home" type="java.lang.String"
>>> value="/some/path/solr1home" override="true" />
>>> </Context>
>>>
>>> Now I want to set the Solr <dataDir> in solrconfig.xml, relative to
>>> the solr home property. The instructions
>>> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
>>> say <dataDir> is used to specify an alternate directory to hold all
>>> index data other than the default ./data under the Solr home. If
>>> replication
>>> is in use, this should match the replication configuration. If this
>>> directory is not absolute, then it is relative to the current working
>>> directory of the servlet container.
>>>
>>> However, no matter how I try to set the dataDir property, solr home is
>>> not
>>> being found. For example,
>>>  <dataDir>${solr.home}/data</dataDir>
>>>
>>> What's even more confusing are these INFO notices in the log:
>>> INFO: No /solr/home in JNDI
>>> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
>>> locateSolrHome
>>> INFO: solr home defaulted to 'solr/' (could not find system property or
>>> JNDI)
>>>
>>> The JNDI instructions instruct to specify "solr/home", the log complains
>>> about "/solr/home" (extra slash), the solrconfig.xml file seems to expect
>>> ${solr.home} - how more confusing can it get?
>>>
>>> This person is having the same issue:
>>> http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/
>>>
>>> So, how does one refer to solr home from solrconfig.xml in a JNDI
>>> configuration scenario? Also, is there a way to debug/see variables that
>>> are
>>> defined in a specific context, such as solrconfig.xml? I feel like I'm
>>> completely blind here.
>>>
>>> Thank you!
>>> --
>>> View this message in context:
>>> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25286277.html
>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>
>>>
>>
>>
>>
>> --
>> -
>> Noble Paul | Principal Engineer| AOL | http://aol.com
>>
>>
>
> --
> View this message in context: 
> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25292025.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



-- 
-
Noble Paul | Principal Engineer| AOL | http://aol.com


Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-04 Thread Archon810

I saw it being used in the default solrconfig.xml in this phrase:
If you wish to hide files under ${solr.home}/conf, explicitly register the
ShowFileRequestHandler using...

It was only natural to assume it would work for something as trivial as
dataDir.

So, there's no way to refer to the solr/home value defined in JNDI?


Noble Paul നോബിള്‍  नोब्ळ्-2 wrote:
> 
> it is nowhere mentioned that you can use a variable ${solr.home} in
> your solrconfig.xml. There is a bug related to this issue
> https://issues.apache.org/jira/browse/SOLR-1267
> 
> On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>>
>> Here's my problem.
>>
>> I'm trying to follow a multi Solr setup, straight from the Solr wiki -
>> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>>
>> Here's the relevant code:
>> <Context docBase="/some/path/solr.war" debug="0" crossContext="true"
>> >
>>   <Environment name="solr/home" type="java.lang.String"
>> value="/some/path/solr1home" override="true" />
>> </Context>
>>
>> Now I want to set the Solr <dataDir> in solrconfig.xml, relative to
>> the solr home property. The instructions
>> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
>> say <dataDir> is used to specify an alternate directory to hold all
>> index data other than the default ./data under the Solr home. If
>> replication
>> is in use, this should match the replication configuration. If this
>> directory is not absolute, then it is relative to the current working
>> directory of the servlet container.
>>
>> However, no matter how I try to set the dataDir property, solr home is
>> not
>> being found. For example,
>>  <dataDir>${solr.home}/data</dataDir>
>>
>> What's even more confusing are these INFO notices in the log:
>> INFO: No /solr/home in JNDI
>> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
>> locateSolrHome
>> INFO: solr home defaulted to 'solr/' (could not find system property or
>> JNDI)
>>
>> The JNDI instructions instruct to specify "solr/home", the log complains
>> about "/solr/home" (extra slash), the solrconfig.xml file seems to expect
>> ${solr.home} - how more confusing can it get?
>>
>> This person is having the same issue:
>> http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/
>>
>> So, how does one refer to solr home from solrconfig.xml in a JNDI
>> configuration scenario? Also, is there a way to debug/see variables that
>> are
>> defined in a specific context, such as solrconfig.xml? I feel like I'm
>> completely blind here.
>>
>> Thank you!
>> --
>> View this message in context:
>> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25286277.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> -
> Noble Paul | Principal Engineer| AOL | http://aol.com
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25292025.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Solr, JNDI config, dataDir, and solr home problem

2009-09-04 Thread Noble Paul നോബിള്‍ नोब्ळ्
it is nowhere mentioned that you can use a variable ${solr.home} in
your solrconfig.xml. There is a bug related to this issue
https://issues.apache.org/jira/browse/SOLR-1267

On Fri, Sep 4, 2009 at 5:47 AM, Archon810 wrote:
>
> Here's my problem.
>
> I'm trying to follow a multi Solr setup, straight from the Solr wiki -
> http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.
>
> Here's the relevant code:
> <Context docBase="/some/path/solr.war" debug="0" crossContext="true" >
>   <Environment name="solr/home" type="java.lang.String"
> value="/some/path/solr1home" override="true" />
> </Context>
>
> Now I want to set the Solr <dataDir> in solrconfig.xml, relative to
> the solr home property. The instructions
> http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
> say <dataDir> is used to specify an alternate directory to hold all
> index data other than the default ./data under the Solr home. If replication
> is in use, this should match the replication configuration. If this
> directory is not absolute, then it is relative to the current working
> directory of the servlet container.
>
> However, no matter how I try to set the dataDir property, solr home is not
> being found. For example,
>  <dataDir>${solr.home}/data</dataDir>
>
> What's even more confusing are these INFO notices in the log:
> INFO: No /solr/home in JNDI
> Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
> locateSolrHome
> INFO: solr home defaulted to 'solr/' (could not find system property or
> JNDI)
>
> The JNDI instructions instruct to specify "solr/home", the log complains
> about "/solr/home" (extra slash), the solrconfig.xml file seems to expect
> ${solr.home} - how more confusing can it get?
>
> This person is having the same issue:
> http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/
>
> So, how does one refer to solr home from solrconfig.xml in a JNDI
> configuration scenario? Also, is there a way to debug/see variables that are
> defined in a specific context, such as solrconfig.xml? I feel like I'm
> completely blind here.
>
> Thank you!
> --
> View this message in context: 
> http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25286277.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



-- 
-
Noble Paul | Principal Engineer| AOL | http://aol.com


Solr, JNDI config, dataDir, and solr home problem

2009-09-03 Thread Archon810

Here's my problem.

I'm trying to follow a multi Solr setup, straight from the Solr wiki -
http://wiki.apache.org/solr/SolrTomcat#head-024d7e11209030f1dbcac9974e55106abae837ac.

Here's the relevant code:
<Context docBase="/some/path/solr.war" debug="0" crossContext="true" >
   <Environment name="solr/home" type="java.lang.String"
value="/some/path/solr1home" override="true" />
</Context>

Now I want to set the Solr <dataDir> in solrconfig.xml, relative to
the solr home property. The instructions
http://wiki.apache.org/solr/SolrConfigXml#head-e8fbf2d748d90c5900aac712d0e3385ced5bd128
say <dataDir> is used to specify an alternate directory to hold all
index data other than the default ./data under the Solr home. If replication
is in use, this should match the replication configuration. If this
directory is not absolute, then it is relative to the current working
directory of the servlet container.

However, no matter how I try to set the dataDir property, solr home is not
being found. For example,
  <dataDir>${solr.home}/data</dataDir>

What's even more confusing are these INFO notices in the log:
INFO: No /solr/home in JNDI
Sep 3, 2009 4:33:26 PM org.apache.solr.core.SolrResourceLoader
locateSolrHome
INFO: solr home defaulted to 'solr/' (could not find system property or
JNDI)

The JNDI instructions instruct to specify "solr/home", the log complains
about "/solr/home" (extra slash), the solrconfig.xml file seems to expect
${solr.home} - how more confusing can it get? 

This person is having the same issue:
http://mysolr.com/tips/setting-solr-home-solrhome-in-jndi-on-tomcat-55/

So, how does one refer to solr home from solrconfig.xml in a JNDI
configuration scenario? Also, is there a way to debug/see variables that are
defined in a specific context, such as solrconfig.xml? I feel like I'm
completely blind here.

Thank you!
-- 
View this message in context: 
http://www.nabble.com/Solr%2C-JNDI-config%2C-dataDir%2C-and-solr-home-problem-tp25286277p25286277.html
Sent from the Solr - User mailing list archive at Nabble.com.



Cannot get solr to pickup solr/home property

2009-08-16 Thread Aaron Aberg
Software:
Linux CentOS
Tomcat 5.5
Plesk 9.2.1
Solr 1.3.0

This is the error log I get when I stop solr (or attempt to) and then
restart it from Plesk:

INFO: Manager: stop: Stopping web application at '/solr'
Aug 15, 2009 10:49:30 PM org.apache.catalina.core.StandardContext stop
INFO: Container
org.apache.catalina.core.ContainerBase.[PSA].[mywebk9.com].[/solr] has
not been started
Aug 15, 2009 10:49:31 PM org.apache.catalina.core.ApplicationContext log
INFO: Manager: list: Listing contexts for virtual host 'mywebk9.com'
Aug 15, 2009 10:49:42 PM org.apache.catalina.core.ApplicationContext log
INFO: Manager: start: Starting web application at '/solr'
Aug 15, 2009 10:49:43 PM org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
Aug 15, 2009 10:49:43 PM org.apache.solr.core.SolrResourceLoader
locateInstanceDir
INFO: Using JNDI solr.home: /usr/share/tomcat5/solr
Aug 15, 2009 10:49:43 PM
org.apache.solr.core.CoreContainer$Initializer initialize
INFO: looking for solr.xml: /usr/share/tomcat5/solr/solr.xml
Aug 15, 2009 10:49:43 PM org.apache.solr.core.SolrResourceLoader 
INFO: Solr home set to '/usr/share/tomcat5/solr/'
Aug 15, 2009 10:49:43 PM org.apache.solr.core.SolrResourceLoader
createClassLoader
INFO: Adding 'file:/usr/share/tomcat5/solr/lib/jetty-6.1.3.jar' to
Solr classloader
Aug 15, 2009 10:49:43 PM org.apache.solr.core.SolrResourceLoader
createClassLoader
INFO: Adding 'file:/usr/share/tomcat5/solr/lib/servlet-api-2.5-6.1.3.jar'
to Solr classloader
Aug 15, 2009 10:49:43 PM org.apache.solr.core.SolrResourceLoader
createClassLoader
INFO: Adding 'file:/usr/share/tomcat5/solr/lib/jetty-util-6.1.3.jar'
to Solr classloader
Aug 15, 2009 10:49:43 PM org.apache.solr.core.SolrResourceLoader
createClassLoader
INFO: Adding 'file:/usr/share/tomcat5/solr/lib/jsp-2.1/' to Solr classloader
Aug 15, 2009 10:49:43 PM org.apache.solr.servlet.SolrDispatchFilter init
SEVERE: Could not start SOLR. Check solr/home property
java.lang.ExceptionInInitializerError
at 
org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
at 
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
at 
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:221)
at 
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:302)
at 
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:78)
at 
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3635)
at 
org.apache.catalina.core.StandardContext.start(StandardContext.java:4222)
at 
org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1176)
at 
org.apache.catalina.manager.ManagerServlet.doGet(ManagerServlet.java:369)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
at 
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at 
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
at 
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at 
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at 
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
at java.lang.Thread.run(Thread.java:636)
Caused by: java.lang.RuntimeException: XPathFactory#newInstance()
failed to create an XPathFactory for the default object model:
http://java.sun.com/jaxp/xpath/dom with the
XPathFactoryConfigurationException:
javax.xml.xpath.XPathFactoryConfigurationException: No XPathFctory
implementation found for the object model:
http://java.sun.com/jaxp/xpath/dom
at javax.xml.xpath.XPathFactory.newInstance(Unknown Source)
at org.apache.solr.core.Config.(Config.java:41)
... 26 more
Aug 

Re: solr/home in web.xml relative to web server home

2009-08-07 Thread Chris Hostetter

: the environment variable (env-entry) in web.xml to configure the solr/home is
: relative to the web server's working directory. I find this unusual as all the
: servlet paths are relative to the web applications directory (webapp context,
: that is). So, I specified solr/home relative to the web app dir, as well, at
: first.

the intention is not that the SOlr Home dir be configured inside the 
web.xml -- it is *possible* to specify the solr home dir in the web.xml as 
you describe, but that's relaly just a fallback for people who really, 
really, want to bake all of the information into the war.  

solr.war is an application -- when you run hte paplication you specify (at 
run time) some configuration information.  Hardcoding that config 
information into the war file is akin to compile a C++ program with all of 
hte config options hardcoded -- you can do it, but it's not very generic, 
and requires a lot of hacking whenever you want to upgrade.

: (In my case, I want to deliver the solr web application including a custom
: entity processor, so that is why I want to include the solr war as part of my
: release cycle. It is easier to deliver that to the system administration than
: to provide them with partial packages they have to install into an already
: installed war, imho.)

you don't have to "install into an already installed war" to add custom 
plugins .. you just have to put the jar file for your custom plugins into 
a "lib" directory instead of your solr home dir.

This is really no different then something like the Apache HTTPD server. 
there is the application (the binary httpd / solr.war) there is your 
configuration (httpd.conf / solr home dir) and there are custom modules 
you can choose to load (libmod_entityprocessor.so / 
your-entityprocessor.jar)



-Hoss



Re: How to set solr/home in linux OS?

2009-08-06 Thread Amit Nithian
Have you tried setting solr home via the JNDI? I think you can set it via
solr/home but that would require adding this to your servlet context
configuration.
Another option is to trace the startup scripts for Glassfish and see what
environment variables are passed in. JAVA_OPTS would make sense but seems
like you are having trouble with it.

- Amit

On Thu, Aug 6, 2009 at 7:15 PM, Otis Gospodnetic  wrote:

> It looks like you export JAVA_OPTS in your .profile, but I bet Tomcat also
> sets and thus overrides this same JAVA_OPTS it its own start up script.  So
> that is what you should edit and modify.  I'm a Jetty user, so I don't have
> a Tomcat startup script to check for you.
>
> Otis
> --
> Sematext is hiring -- http://sematext.com/about/jobs.html?mls
> Lucene, Solr, Nutch, Katta, Hadoop, HBase, UIMA, NLP, NER, IR
>
>
>
> - Original Message 
> > From: huenzhao 
> > To: solr-user@lucene.apache.org
> > Sent: Thursday, August 6, 2009 9:53:26 PM
> > Subject: Re: How to set solr/home in linux OS?
> >
> >
> > I have tried, but it was also not work!
> >
> > The goal to set solr.home in tomcat6 is to start solr when the tomcat6 is
> > starting.
> >
> > So I think the problem is that the solr can not start by set the
> solr.home
> > when glassfish is starting.
> >
> >
> >
> >
> > Chantal Ackermann wrote:
> > >
> > >
> > > You have to quote values that include whitespace:
> > >
> > > export JAVA_OPTS="$JAVA_OPTS
> -Dsolr.solr.home=/home/huenzhao/search/solr"
> > >
> > > or to make it accessible for other paths as well:
> > > export SOLR_HOME=/home/huenzhao/search/solr
> > > export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=$SOLR_HOME"
> > >
> > >
> > >
> > > Cheers,
> > > Chantal
> > >
> > > huenzhao schrieb:
> > >> Hi all,
> > >>
> > >> I know how to configure solr.home by using tomcat6, but I don't know
> how
> > >> to
> > >> set solr.home by using Glassfish(V2.1). I have tried to set the
> solr.home
> > >> in
> > >> .profile as fellows:
> > >>
> > >> export solr.home=/home/huenzhao/search/solr
> > >> export solr/home=/home/huenzhao/search/solr
> > >> export solr.solr.home=/home/huenzhao/search/solr
> > >> export JAVA_OPTS=$JAVA_OPTS
> -Dsolr.solr.home=/home/huenzhao/search/solr
> > >>
> > >> and they all not work. The error is:
> > >>
> > >> HTTP Status 500 - Severe errors in solr configuration. Check your log
> > >> files
> > >> for more detailed information on what may be wrong. If you want solr
> to
> > >> continue after configuration errors, change: false in null
> > >> -
> > >> java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
> > >> classpath or 'solr/conf/',
> > >> cwd=/home/huenzhao/search/glassfish/domains/domain1/config at
> > >>
> >
> org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
> > >> at
> > >>
> >
> org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
> > >> at org.apache.solr.core.Config.(Config.java:100) at
> > >> org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
> > >> org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
> > >>
> >
> org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
> > >> at
> > >>
> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
> > >> at
> > >>
> >
> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:273)
> > >> at
> > >>
> >
> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:385)
> > >> at
> > >>
> >
> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:119)
> > >> at
> > >>
> >
> org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4498)
> > >> at
> > >>
> org.apache.catalina.core.StandardContext.start(StandardContext.java:5317)
> > >> at com.sun.enterprise.web.WebModule.start(WebModule.java:353) at
> > >>
> >
> org.apache.catalina.core.ContainerBase.addChildInter

Re: How to set solr/home in linux OS?

2009-08-06 Thread Otis Gospodnetic
It looks like you export JAVA_OPTS in your .profile, but I bet Tomcat also sets 
and thus overrides this same JAVA_OPTS it its own start up script.  So that is 
what you should edit and modify.  I'm a Jetty user, so I don't have a Tomcat 
startup script to check for you.

Otis
--
Sematext is hiring -- http://sematext.com/about/jobs.html?mls
Lucene, Solr, Nutch, Katta, Hadoop, HBase, UIMA, NLP, NER, IR



- Original Message 
> From: huenzhao 
> To: solr-user@lucene.apache.org
> Sent: Thursday, August 6, 2009 9:53:26 PM
> Subject: Re: How to set solr/home in linux OS?
> 
> 
> I have tried, but it was also not work!
> 
> The goal to set solr.home in tomcat6 is to start solr when the tomcat6 is
> starting.
> 
> So I think the problem is that the solr can not start by set the solr.home
> when glassfish is starting.
> 
> 
> 
> 
> Chantal Ackermann wrote:
> > 
> > 
> > You have to quote values that include whitespace:
> > 
> > export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr"
> > 
> > or to make it accessible for other paths as well:
> > export SOLR_HOME=/home/huenzhao/search/solr
> > export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=$SOLR_HOME"
> > 
> > 
> > 
> > Cheers,
> > Chantal
> > 
> > huenzhao schrieb:
> >> Hi all,
> >> 
> >> I know how to configure solr.home by using tomcat6, but I don't know how
> >> to
> >> set solr.home by using Glassfish(V2.1). I have tried to set the solr.home
> >> in
> >> .profile as fellows:
> >> 
> >> export solr.home=/home/huenzhao/search/solr
> >> export solr/home=/home/huenzhao/search/solr
> >> export solr.solr.home=/home/huenzhao/search/solr
> >> export JAVA_OPTS=$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr
> >> 
> >> and they all not work. The error is:
> >> 
> >> HTTP Status 500 - Severe errors in solr configuration. Check your log
> >> files
> >> for more detailed information on what may be wrong. If you want solr to
> >> continue after configuration errors, change: false in null
> >> -
> >> java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
> >> classpath or 'solr/conf/',
> >> cwd=/home/huenzhao/search/glassfish/domains/domain1/config at
> >> 
> org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
> >> at
> >> 
> org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
> >> at org.apache.solr.core.Config.(Config.java:100) at
> >> org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
> >> org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
> >> 
> org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
> >> at
> >> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
> >> at
> >> 
> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:273)
> >> at
> >> 
> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:385)
> >> at
> >> 
> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:119)
> >> at
> >> 
> org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4498)
> >> at
> >> org.apache.catalina.core.StandardContext.start(StandardContext.java:5317)
> >> at com.sun.enterprise.web.WebModule.start(WebModule.java:353) at
> >> 
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:989)
> >> at
> >> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:973)
> >> at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:704)
> >> at
> >> com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1627)
> >> at
> >> com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1232)
> >> at
> >> 
> com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:182)
> >> at
> >> 
> com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:278)
> >> at
> >> 
> com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1005)
> >> at
> >> 
> >> ……
> >> 
> >> Anybody knows?
> >> 
> >> Thanks!
> >> 
> >> enzhao...@gmail.com
> >> 
> >> --
> >> View this message in context:
> >> 
> http://www.nabble.com/How-to-set-solr-home-in-linux-OS--tp24840832p24840832.html
> >> Sent from the Solr - User mailing list archive at Nabble.com.
> > 
> > 
> 
> -- 
> View this message in context: 
> http://www.nabble.com/How-to-set-solr-home-in-linux-OS--tp24840832p24857511.html
> Sent from the Solr - User mailing list archive at Nabble.com.



Re: How to set solr/home in linux OS?

2009-08-06 Thread huenzhao

I have tried, but it was also not work!

The goal to set solr.home in tomcat6 is to start solr when the tomcat6 is
starting.

So I think the problem is that the solr can not start by set the solr.home
when glassfish is starting.
 



Chantal Ackermann wrote:
> 
> 
> You have to quote values that include whitespace:
> 
> export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr"
> 
> or to make it accessible for other paths as well:
> export SOLR_HOME=/home/huenzhao/search/solr
> export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=$SOLR_HOME"
> 
> 
> 
> Cheers,
> Chantal
> 
> huenzhao schrieb:
>> Hi all,
>> 
>> I know how to configure solr.home by using tomcat6, but I don't know how
>> to
>> set solr.home by using Glassfish(V2.1). I have tried to set the solr.home
>> in
>> .profile as fellows:
>> 
>> export solr.home=/home/huenzhao/search/solr
>> export solr/home=/home/huenzhao/search/solr
>> export solr.solr.home=/home/huenzhao/search/solr
>> export JAVA_OPTS=$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr
>> 
>> and they all not work. The error is:
>> 
>> HTTP Status 500 - Severe errors in solr configuration. Check your log
>> files
>> for more detailed information on what may be wrong. If you want solr to
>> continue after configuration errors, change: false in null
>> -
>> java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
>> classpath or 'solr/conf/',
>> cwd=/home/huenzhao/search/glassfish/domains/domain1/config at
>> org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
>> at
>> org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
>> at org.apache.solr.core.Config.(Config.java:100) at
>> org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
>> org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
>> org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
>> at
>> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
>> at
>> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:273)
>> at
>> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:385)
>> at
>> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:119)
>> at
>> org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4498)
>> at
>> org.apache.catalina.core.StandardContext.start(StandardContext.java:5317)
>> at com.sun.enterprise.web.WebModule.start(WebModule.java:353) at
>> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:989)
>> at
>> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:973)
>> at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:704)
>> at
>> com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1627)
>> at
>> com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1232)
>> at
>> com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:182)
>> at
>> com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:278)
>> at
>> com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1005)
>> at
>> 
>> ……
>> 
>> Anybody knows?
>> 
>> Thanks!
>> 
>> enzhao...@gmail.com
>> 
>> --
>> View this message in context:
>> http://www.nabble.com/How-to-set-solr-home-in-linux-OS--tp24840832p24840832.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
> 
> 

-- 
View this message in context: 
http://www.nabble.com/How-to-set-solr-home-in-linux-OS--tp24840832p24857511.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: How to set solr/home in linux OS?

2009-08-06 Thread Chantal Ackermann


You have to quote values that include whitespace:

export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr"

or to make it accessible for other paths as well:
export SOLR_HOME=/home/huenzhao/search/solr
export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=$SOLR_HOME"



Cheers,
Chantal

huenzhao schrieb:

Hi all,

I know how to configure solr.home by using tomcat6, but I don't know how to
set solr.home by using Glassfish(V2.1). I have tried to set the solr.home in
.profile as fellows:

export solr.home=/home/huenzhao/search/solr
export solr/home=/home/huenzhao/search/solr
export solr.solr.home=/home/huenzhao/search/solr
export JAVA_OPTS=$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr

and they all not work. The error is:

HTTP Status 500 - Severe errors in solr configuration. Check your log files
for more detailed information on what may be wrong. If you want solr to
continue after configuration errors, change: false in null
-
java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
classpath or 'solr/conf/',
cwd=/home/huenzhao/search/glassfish/domains/domain1/config at
org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
at
org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
at org.apache.solr.core.Config.(Config.java:100) at
org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
at
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
at
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:273)
at
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:385)
at
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:119)
at
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4498)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:5317)
at com.sun.enterprise.web.WebModule.start(WebModule.java:353) at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:989)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:973)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:704) at
com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1627) at
com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1232) at
com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:182)
at
com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:278)
at
com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1005)
at

……

Anybody knows?

Thanks!

enzhao...@gmail.com

--
View this message in context: 
http://www.nabble.com/How-to-set-solr-home-in-linux-OS--tp24840832p24840832.html
Sent from the Solr - User mailing list archive at Nabble.com.


How to set solr/home in linux OS?

2009-08-06 Thread huenzhao

Hi all,

I know how to configure solr.home by using tomcat6, but I don't know how to
set solr.home by using Glassfish(V2.1). I have tried to set the solr.home in
.profile as fellows:

export solr.home=/home/huenzhao/search/solr
export solr/home=/home/huenzhao/search/solr
export solr.solr.home=/home/huenzhao/search/solr
export JAVA_OPTS=$JAVA_OPTS -Dsolr.solr.home=/home/huenzhao/search/solr

and they all not work. The error is:

HTTP Status 500 - Severe errors in solr configuration. Check your log files
for more detailed information on what may be wrong. If you want solr to
continue after configuration errors, change: false in null
-
java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in
classpath or 'solr/conf/',
cwd=/home/huenzhao/search/glassfish/domains/domain1/config at
org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:194)
at
org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:162)
at org.apache.solr.core.Config.(Config.java:100) at
org.apache.solr.core.SolrConfig.(SolrConfig.java:113) at
org.apache.solr.core.SolrConfig.(SolrConfig.java:70) at
org.apache.solr.core.CoreContainer$Initializer.initialize(CoreContainer.java:117)
at
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:69)
at
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:273)
at
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:385)
at
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:119)
at
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4498)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:5317)
at com.sun.enterprise.web.WebModule.start(WebModule.java:353) at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:989)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:973)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:704) at
com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1627) at
com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1232) at
com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:182)
at
com.sun.enterprise.server.WebModuleDeployEventListener.moduleDeployed(WebModuleDeployEventListener.java:278)
at
com.sun.enterprise.admin.event.AdminEventMulticaster.invokeModuleDeployEventListener(AdminEventMulticaster.java:1005)
at 

……

Anybody knows? 

Thanks! 

enzhao...@gmail.com

-- 
View this message in context: 
http://www.nabble.com/How-to-set-solr-home-in-linux-OS--tp24840832p24840832.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: solr/home in web.xml relative to web server home

2009-07-29 Thread Shalin Shekhar Mangar
On Wed, Jul 29, 2009 at 2:42 PM, Chantal Ackermann <
chantal.ackerm...@btelligent.de> wrote:

> Hi all,
>
> the environment variable (env-entry) in web.xml to configure the solr/home
> is relative to the web server's working directory. I find this unusual as
> all the servlet paths are relative to the web applications directory (webapp
> context, that is). So, I specified solr/home relative to the web app dir, as
> well, at first.
>
> I think it makes deployment in an unknown environment, or in different
> environments using a simple war more complex than it needed to be. If a
> webapp relative path inside the war file could be used, the configuration of
> solr (and cores) could be included in the war file completely with no
> outside dependency - except, of course, of the data directory if that is to
> go some place else.
> (In my case, I want to deliver the solr web application including a custom
> entity processor, so that is why I want to include the solr war as part of
> my release cycle. It is easier to deliver that to the system administration
> than to provide them with partial packages they have to install into an
> already installed war, imho.)
>

You don't need to create a custom war for that. You can package the
EntityProcessor into a separate jar and add it to solr_home/lib directory.

-- 
Regards,
Shalin Shekhar Mangar.


solr/home in web.xml relative to web server home

2009-07-29 Thread Chantal Ackermann

Hi all,

the environment variable (env-entry) in web.xml to configure the 
solr/home is relative to the web server's working directory. I find this 
unusual as all the servlet paths are relative to the web applications 
directory (webapp context, that is). So, I specified solr/home relative 
to the web app dir, as well, at first.


I think it makes deployment in an unknown environment, or in different 
environments using a simple war more complex than it needed to be. If a 
webapp relative path inside the war file could be used, the 
configuration of solr (and cores) could be included in the war file 
completely with no outside dependency - except, of course, of the data 
directory if that is to go some place else.
(In my case, I want to deliver the solr web application including a 
custom entity processor, so that is why I want to include the solr war 
as part of my release cycle. It is easier to deliver that to the system 
administration than to provide them with partial packages they have to 
install into an already installed war, imho.)


Am I the only one who has run into that?

Thanks for any input on that!
Chantal



--
Chantal Ackermann


Re: Solr Home on Linux JBoss ignored

2009-06-05 Thread Matt Weber

Check the dataDir setting in solrconfig.xml.

Thanks,

Matt Weber
eSr Technologies
http://www.esr-technologies.com




On Jun 5, 2009, at 6:03 AM, Dean Pullen wrote:


I lied, it's actually saving data to:

/usr/local/jboss-portal-2.7.1.GA/bin/C:\home\jboss\solr\data

Which is a tad crazy! And I have no idea why!

Dean.

-Original Message-
From: Dean Pullen [mailto:dean.pul...@msp-uk.com]
Sent: 05 June 2009 09:47
To: solr-user@lucene.apache.org
Subject: Solr Home on Linux JBoss ignored

Hi all,

Have an odd problem on JBoss 4.2.3 running on Redhat.
It's odd, because the configuration works fine on Windows.

Our Solr home is defined in the Solr.war web.xml as:

[Linux]

 solr/home
 java.lang.String
 /home/jboss/solr


[Windows]

 solr/home
 java.lang.String
 c:/home/jboss/solr


However, on Linux Solr is still defaulting to JBoss Web's [Tomcat]  
work directory, i.e.
/usr/local/jboss-portal-2.7.1.GA/server/default/work/jboss.web/ 
localhost/solr


Instead of the defined /home/jboss/solr


Can anyone shed any light on this?

Thanks,

Dean.


Scanned by MailDefender - managed email security from intY - 
www.maildefender.net

Scanned by MailDefender - managed email security from intY - 
www.maildefender.net

Scanned by MailDefender - managed email security from intY - 
www.maildefender.net




RE: Solr Home on Linux JBoss ignored

2009-06-05 Thread Dean Pullen
I lied, it's actually saving data to:

/usr/local/jboss-portal-2.7.1.GA/bin/C:\home\jboss\solr\data

Which is a tad crazy! And I have no idea why!

Dean.

-Original Message-
From: Dean Pullen [mailto:dean.pul...@msp-uk.com] 
Sent: 05 June 2009 09:47
To: solr-user@lucene.apache.org
Subject: Solr Home on Linux JBoss ignored

Hi all,

Have an odd problem on JBoss 4.2.3 running on Redhat.
It's odd, because the configuration works fine on Windows.

Our Solr home is defined in the Solr.war web.xml as:

[Linux]

  solr/home
  java.lang.String
  /home/jboss/solr


[Windows]

  solr/home
  java.lang.String
  c:/home/jboss/solr
 

However, on Linux Solr is still defaulting to JBoss Web's [Tomcat] work 
directory, i.e.
/usr/local/jboss-portal-2.7.1.GA/server/default/work/jboss.web/localhost/solr

Instead of the defined /home/jboss/solr


Can anyone shed any light on this?

Thanks,

Dean.


Scanned by MailDefender - managed email security from intY - 
www.maildefender.net

Scanned by MailDefender - managed email security from intY - 
www.maildefender.net

Scanned by MailDefender - managed email security from intY - 
www.maildefender.net


Solr Home on Linux JBoss ignored

2009-06-05 Thread Dean Pullen
Hi all,

Have an odd problem on JBoss 4.2.3 running on Redhat.
It's odd, because the configuration works fine on Windows.

Our Solr home is defined in the Solr.war web.xml as:

[Linux]

  solr/home
  java.lang.String
  /home/jboss/solr


[Windows]

  solr/home
  java.lang.String
  c:/home/jboss/solr
 

However, on Linux Solr is still defaulting to JBoss Web's [Tomcat] work 
directory, i.e.
/usr/local/jboss-portal-2.7.1.GA/server/default/work/jboss.web/localhost/solr

Instead of the defined /home/jboss/solr


Can anyone shed any light on this?

Thanks,

Dean.


Scanned by MailDefender - managed email security from intY - 
www.maildefender.net

Re: getting solr home path dynamically

2009-04-01 Thread Erik Hatcher


On Apr 1, 2009, at 10:55 AM, Radha C. wrote:

But I am having trouble in identifying the xml location,
I am having the input xml in $solrhome/inputdata/example.xml, Do you  
have

any idea about how to get solrhome
location dynamically by using any solrj API class?


Using SolrJ remotely, you can hit the /admin/system request handler to  
get the Solr home directory.  In a URL it'd be http://localhost:8983/solr/admin/system 
.  You get this sort of thing in the response:






 0
 80


 example
 10.0.1.193

 2009-04-01T15:24:32.428Z
 2009-04-01T15:21:20.765Z
 
  /Users/erikhatcher/dev/solr/example/solr
  /Users/erikhatcher/dev/solr/example/./solr/datastr>
  /Users/erikhatcher/dev/solr/example/solr/data/ 
index


 

...

And you can navigate the SolrJ response to get to the directory/ 
instance value.


I question whether it's a good idea to do this from a SolrJ client  
though, as that directory is only useful on the server itself and  
client on the same machine, but not actually remotely.  But, you can  
get at it at least :)


Erik




RE: getting solr home path dynamically

2009-04-01 Thread Radha C.
Hi,
 
No luck, I tried as follows, my solr home is there out of of my solrj
client. I think it is looking for the config at CWD,
 
config = new SolrConfig();
   String dir= config.getResourceLoader().getDataDir(); ( I used
getInstanceDir() also )
//File f = new File( home, "solr.xml" );
System.out.println("solr home : "+dir);
 
But got an exception 
 
Apr 1, 2009 8:20:41 PM org.apache.solr.core.SolrResourceLoader
locateInstanceDir
INFO: JNDI not configured for solr (NoInitialContextEx)
Apr 1, 2009 8:20:41 PM org.apache.solr.core.SolrResourceLoader
locateInstanceDir
INFO: solr home defaulted to 'solr/' (could not find system property or
JNDI)
Apr 1, 2009 8:20:41 PM org.apache.solr.core.SolrResourceLoader 
INFO: Solr home set to 'solr/'
Apr 1, 2009 8:20:41 PM org.apache.solr.core.SolrResourceLoader
createClassLoader
INFO: Reusing parent classloader
Exception in thread "main" java.lang.RuntimeException: Can't find resource
'solrconfig.xml' in classpath or 'solr/conf/', cwd=D:\Lucene\solrjclient
at
org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java
:197)
at
org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:1
65)
at org.apache.solr.core.Config.(Config.java:101)
at org.apache.solr.core.SolrConfig.(SolrConfig.java:111)
at org.apache.solr.core.SolrConfig.(SolrConfig.java:68)
at SolrDeleteTest.main(SolrDeleteTest.java:30)
Java Result: 1
 
 
Anybody have any idea ??


  _  

From: Giovanni De Stefano [mailto:giovanni.destef...@gmail.com] 
Sent: Wednesday, April 01, 2009 8:19 PM
To: solr-user@lucene.apache.org; cra...@ceiindia.com
Subject: Re: Indexing fields of xml file using solrj


Hello,
 
you can try with:
 
SolrConfig.config.getResourceLoader().getInstanceDir()
 
Let me know if it works.
 
Cheers,
Giovanni

 
On 4/1/09, Radha C.  wrote: 

Hey No,

Actually I did not look at your response email. But I saw your email after I
responded to shalin and you gave me a correct answer. Thanks a lot.
So I started coding it also, I thought to reply to u once I executed
successfully. Here is my code,
DirectXmlRequest xmlreq = new DirectXmlRequest( "/update", xml.toString() );

server.request( xmlreq );

server.commit();
But I am having trouble in identifying the xml location,
I am having the input xml in $solrhome/inputdata/example.xml, Do you have
any idea about how to get solrhome
location dynamically by using any solrj API class?


_

From: Giovanni De Stefano [mailto:giovanni.destef...@gmail.com]
Sent: Wednesday, April 01, 2009 7:30 PM
To: solr-user@lucene.apache.org; cra...@ceiindia.com
Subject: Re: Indexing fields of xml file using solrj


I understand Shalin is a guru and I am nobody but...

http://lucene.apache.org/solr/api/org/apache/solr/client/solrj/request/Direc
tXmlRequest.html

Is what you need if you want to use Solrj...

:-)


On 4/1/09, Radha C.  wrote:

Thanks shalin,

I need to index the xml which is in solr's format only. I want to index that
xnl directly using solrj same like how we post using curl. Is there any API
class is available for that?

Can you please provide me any reference link?

-Original Message-
From: Shalin Shekhar Mangar [mailto:shalinman...@gmail.com]
Sent: Wednesday, April 01, 2009 6:07 PM
To: solr-user@lucene.apache.org; cra...@ceiindia.com
Subject: Re: Indexing fields of xml file using solrj

On Wed, Apr 1, 2009 at 5:17 PM, Radha C.  wrote:
> Hi All,
>
> I want to index the document fields in a xml file to index using
> solrj. I know how to index the document fields using doc.addfield().
> But I dont know how to post the xml document instead of adding each field
in solrj.
>
> Can I index xml file using solrj? Can anyone help me in how to do this?
>

Solr will only accept xml files which are in the solr's update xml format.
You cannot post any arbitrary xml (you can convert using the xslt). You can
also parse it yourself and use solrj for adding the document. There's
DataImportHandler too which can parse XML using xpath.

--
Regards,
Shalin Shekhar Mangar.









Re: Check solr/home property

2008-10-03 Thread sunnyfr

Thanks its ok now , my data folder loose is right ... the directory didn't
have good rights.
THANKS A LOT GUYS


Erik Hatcher wrote:
> 
> Also note that with Solr 1.3.0 final release, it should be solr.xml,  
> not multicore.xml - and the internals of that file changed too.  Grab  
> a final release to see the specifics.
> 
>   Erik
> 
> 
> On Oct 3, 2008, at 4:32 AM, Shalin Shekhar Mangar wrote:
> 
>> If you are using multicore.xml then the solr/home property in your  
>> tomcat
>> should be /data/solr
>>
>> On Fri, Oct 3, 2008 at 12:25 PM, sunnyfr <[EMAIL PROTECTED]> wrote:
>>
>>>
>>> Thanks Hoss,
>>>
>>> I thought it might come from tomcat if it doesn't find it :
>>> [EMAIL PROTECTED]:/etc/tomcat5.5/Catalina/localhost# ls
>>> solr.xml
>>>
>>> [EMAIL PROTECTED]:/var/lib/tomcat5.5/webapps# ls
>>> solr  solr.war
>>>
>>> I have solrconfig.xml in my folder /data/solr/books/conf/
>>> and I've multicore.xml in /data/solr/
>>> 
>>> >> sharedLib="lib" >
>>> 
>>> 
>>> 
>>> 
>>>
>>> solr.xml
>>> >> crossContext="true" >
>>>  >> override="true" />
>>> >>
>>> And my error :
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: 0.058: [GC
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]:  [PSYoungGen:
>>> 5121K->288K(298688K)] 5121K->288K(2005376K), 0.0021570 secs] [Times:
>>> user=0.00 sys=0.00, real=0.01 secs]  0.060: [Full GC (System)  
>>> [PSYoungGen:
>>> 288K->0K(298688K)] [PSOldGen: 0K->180K(1706688K)] 288K- 
>>> >180K(2005376K)
>>> [PSPermGen: 3002K->3002K(21248K)], 0.0067110 secs] [Times: user=0.00
>>> sys=0.00, real=0.00 secs]
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
>>> org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO:  
>>> The
>>> Apache Tomcat Native library which allows optimal performance in  
>>> production
>>> environments was not found on the java.library.path:
>>> /usr/java/packages/lib/amd64:/lib:/usr/lib
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
>>> org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing  
>>> Coyote
>>> HTTP/1.1 on http-8180
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
>>> org.apache.catalina.startup.Catalina load INFO: Initialization  
>>> processed in
>>> 350 ms
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
>>> org.apache.catalina.core.StandardService start INFO: Starting service
>>> Catalina
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
>>> org.apache.catalina.core.StandardEngine start INFO: Starting Servlet
>>> Engine:
>>> Apache Tomcat/5.5
>>> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
>>> org.apache.catalina.core.StandardHost start INFO: XML validation  
>>> disabled
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.servlet.SolrDispatchFilter init INFO:
>>> SolrDispatchFilter.init()
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO:  
>>> Using JNDI
>>> solr.home: /data/solr
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.servlet.SolrDispatchFilter initMultiCore INFO:  
>>> looking for
>>> multicore.xml: /data/solr/multicore.xml
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO:  
>>> Using JNDI
>>> solr.home: /data/solr
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.core.SolrResourceLoader  INFO: Solr home set to
>>> '/data/solr/'
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.core.SolrResourceLoader createClassLoader INFO:  
>>> Reusing
>>> parent classloader
>>> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
>>> org.apache.solr.servlet.SolrDispatchFilter init SEVERE: Could not  
>>> start
>>> SOLR. Check solr/home property java.lang.RuntimeException: Can't find
>>> resource 'solrconfig.x

Re: Check solr/home property

2008-10-03 Thread Erik Hatcher
Also note that with Solr 1.3.0 final release, it should be solr.xml,  
not multicore.xml - and the internals of that file changed too.  Grab  
a final release to see the specifics.


Erik


On Oct 3, 2008, at 4:32 AM, Shalin Shekhar Mangar wrote:

If you are using multicore.xml then the solr/home property in your  
tomcat

should be /data/solr

On Fri, Oct 3, 2008 at 12:25 PM, sunnyfr <[EMAIL PROTECTED]> wrote:



Thanks Hoss,

I thought it might come from tomcat if it doesn't find it :
[EMAIL PROTECTED]:/etc/tomcat5.5/Catalina/localhost# ls
solr.xml

[EMAIL PROTECTED]:/var/lib/tomcat5.5/webapps# ls
solr  solr.war

I have solrconfig.xml in my folder /data/solr/books/conf/
and I've multicore.xml in /data/solr/

sharedLib="lib" >






solr.xml

 
override="true" />
288K(298688K)] 5121K->288K(2005376K), 0.0021570 secs] [Times:
user=0.00 sys=0.00, real=0.01 secs]  0.060: [Full GC (System)  
[PSYoungGen:
288K->0K(298688K)] [PSOldGen: 0K->180K(1706688K)] 288K- 
>180K(2005376K)

[PSPermGen: 3002K->3002K(21248K)], 0.0067110 secs] [Times: user=0.00
sys=0.00, real=0.00 secs]
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO:  
The
Apache Tomcat Native library which allows optimal performance in  
production

environments was not found on the java.library.path:
/usr/java/packages/lib/amd64:/lib:/usr/lib
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing  
Coyote

HTTP/1.1 on http-8180
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.startup.Catalina load INFO: Initialization  
processed in

350 ms
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.StandardService start INFO: Starting service
Catalina
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.StandardEngine start INFO: Starting Servlet
Engine:
Apache Tomcat/5.5
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.StandardHost start INFO: XML validation  
disabled

Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.servlet.SolrDispatchFilter init INFO:
SolrDispatchFilter.init()
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO:  
Using JNDI

solr.home: /data/solr
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.servlet.SolrDispatchFilter initMultiCore INFO:  
looking for

multicore.xml: /data/solr/multicore.xml
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO:  
Using JNDI

solr.home: /data/solr
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader  INFO: Solr home set to
'/data/solr/'
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader createClassLoader INFO:  
Reusing

parent classloader
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.servlet.SolrDispatchFilter init SEVERE: Could not  
start

SOLR. Check solr/home property java.lang.RuntimeException: Can't find
resource 'solrconfig.xml' in classpath or '/data/solr/conf/', cwd=/  
^Iat


org 
.apache 
.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java: 
168)

^Iat

org 
.apache 
.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:136)

^Iat org.apache.solr.core.Config.(Config.java:97) ^Iat
org.apache.solr.core.SolrConfig.(SolrConfig.java:108) ^Iat
org.apache.solr.core.SolrConfig.(SolrConfig.java:65) ^Iat
org 
.apache 
.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:89)

^Iat

org 
.apache 
.catalina 
.core 
.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:221)

^Iat

org 
.apache 
.catalina 
.core 
.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java: 
302)

^Iat

org 
.apache 
.catalina 
.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:78)

^Iat org.apache.catalin
Oct  3 08:53:43 solr-test jsvc.exec[24013]: text.java:3635) ^Iat
org.apache.catalina.core.StandardContext.start(StandardContext.java: 
4222)

^Iat

org 
.apache 
.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)

^Iat
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java: 
740)
^Iat  
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)

^Iat

org 
.apache 
.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:626)

^Iat

org 
.apache 
.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
^Iat  
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java: 
488)
^Iat org.apache.catalina.startup.HostConfig

Re: Check solr/home property

2008-10-03 Thread Shalin Shekhar Mangar
If you are using multicore.xml then the solr/home property in your tomcat
should be /data/solr

On Fri, Oct 3, 2008 at 12:25 PM, sunnyfr <[EMAIL PROTECTED]> wrote:

>
> Thanks Hoss,
>
> I thought it might come from tomcat if it doesn't find it :
> [EMAIL PROTECTED]:/etc/tomcat5.5/Catalina/localhost# ls
> solr.xml
>
> [EMAIL PROTECTED]:/var/lib/tomcat5.5/webapps# ls
> solr  solr.war
>
> I have solrconfig.xml in my folder /data/solr/books/conf/
> and I've multicore.xml in /data/solr/
> 
> 
>  
>  
>  
> 
>
> solr.xml
>  crossContext="true" >
>override="true" />
> 
> And my error :
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: 0.058: [GC
> Oct  3 08:53:42 solr-test jsvc.exec[24013]:  [PSYoungGen:
> 5121K->288K(298688K)] 5121K->288K(2005376K), 0.0021570 secs] [Times:
> user=0.00 sys=0.00, real=0.01 secs]  0.060: [Full GC (System) [PSYoungGen:
> 288K->0K(298688K)] [PSOldGen: 0K->180K(1706688K)] 288K->180K(2005376K)
> [PSPermGen: 3002K->3002K(21248K)], 0.0067110 secs] [Times: user=0.00
> sys=0.00, real=0.00 secs]
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
> org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The
> Apache Tomcat Native library which allows optimal performance in production
> environments was not found on the java.library.path:
> /usr/java/packages/lib/amd64:/lib:/usr/lib
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
> org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote
> HTTP/1.1 on http-8180
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
> org.apache.catalina.startup.Catalina load INFO: Initialization processed in
> 350 ms
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
> org.apache.catalina.core.StandardService start INFO: Starting service
> Catalina
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
> org.apache.catalina.core.StandardEngine start INFO: Starting Servlet
> Engine:
> Apache Tomcat/5.5
> Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
> org.apache.catalina.core.StandardHost start INFO: XML validation disabled
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.servlet.SolrDispatchFilter init INFO:
> SolrDispatchFilter.init()
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO: Using JNDI
> solr.home: /data/solr
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.servlet.SolrDispatchFilter initMultiCore INFO: looking for
> multicore.xml: /data/solr/multicore.xml
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO: Using JNDI
> solr.home: /data/solr
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.core.SolrResourceLoader  INFO: Solr home set to
> '/data/solr/'
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.core.SolrResourceLoader createClassLoader INFO: Reusing
> parent classloader
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
> org.apache.solr.servlet.SolrDispatchFilter init SEVERE: Could not start
> SOLR. Check solr/home property java.lang.RuntimeException: Can't find
> resource 'solrconfig.xml' in classpath or '/data/solr/conf/', cwd=/ ^Iat
>
> org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:168)
> ^Iat
>
> org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:136)
> ^Iat org.apache.solr.core.Config.(Config.java:97) ^Iat
> org.apache.solr.core.SolrConfig.(SolrConfig.java:108) ^Iat
> org.apache.solr.core.SolrConfig.(SolrConfig.java:65) ^Iat
> org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:89)
> ^Iat
>
> org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:221)
> ^Iat
>
> org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:302)
> ^Iat
>
> org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:78)
> ^Iat org.apache.catalin
> Oct  3 08:53:43 solr-test jsvc.exec[24013]: text.java:3635) ^Iat
> org.apache.catalina.core.StandardContext.start(StandardContext.java:4222)
> ^Iat
>
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
> ^Iat
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
> ^Iat org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
> ^Iat
>
&

Re: Check solr/home property

2008-10-03 Thread sunnyfr
alina.startup.ContextConfig.init(ContextConfig.java:990)
^Iat org.apach
Oct  3 10:29:24 solr-test jsvc.exec[27026]: ontextConfig.java:279) ^Iat
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
^Iat
org.apache.catalina.core.StandardContext.init(StandardContext.java:5071)
^Iat
org.apache.catalina.core.StandardContext.start(StandardContext.java:3984)
^Iat
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
^Iat org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
^Iat org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
^Iat
org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:626)
^Iat
org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
^Iat org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:488)
^Iat org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138) ^Iat
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
^Iat
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.j

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



Re: Check solr/home property

2008-10-02 Thread sunnyfr

Thanks Hoss,

I thought it might come from tomcat if it doesn't find it :
[EMAIL PROTECTED]:/etc/tomcat5.5/Catalina/localhost# ls
solr.xml

[EMAIL PROTECTED]:/var/lib/tomcat5.5/webapps# ls
solr  solr.war

I have solrconfig.xml in my folder /data/solr/books/conf/
and I've multicore.xml in /data/solr/


  
  
  


solr.xml

   
288K(298688K)] 5121K->288K(2005376K), 0.0021570 secs] [Times:
user=0.00 sys=0.00, real=0.01 secs]  0.060: [Full GC (System) [PSYoungGen:
288K->0K(298688K)] [PSOldGen: 0K->180K(1706688K)] 288K->180K(2005376K)
[PSPermGen: 3002K->3002K(21248K)], 0.0067110 secs] [Times: user=0.00
sys=0.00, real=0.00 secs]
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.AprLifecycleListener lifecycleEvent INFO: The
Apache Tomcat Native library which allows optimal performance in production
environments was not found on the java.library.path:
/usr/java/packages/lib/amd64:/lib:/usr/lib
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.coyote.http11.Http11BaseProtocol init INFO: Initializing Coyote
HTTP/1.1 on http-8180
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.startup.Catalina load INFO: Initialization processed in
350 ms
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.StandardService start INFO: Starting service
Catalina
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine:
Apache Tomcat/5.5
Oct  3 08:53:42 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:42 AM
org.apache.catalina.core.StandardHost start INFO: XML validation disabled
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.servlet.SolrDispatchFilter init INFO:
SolrDispatchFilter.init()
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO: Using JNDI
solr.home: /data/solr
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.servlet.SolrDispatchFilter initMultiCore INFO: looking for
multicore.xml: /data/solr/multicore.xml
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader locateInstanceDir INFO: Using JNDI
solr.home: /data/solr
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader  INFO: Solr home set to
'/data/solr/'
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.core.SolrResourceLoader createClassLoader INFO: Reusing
parent classloader
Oct  3 08:53:43 solr-test jsvc.exec[24013]: Oct 3, 2008 8:53:43 AM
org.apache.solr.servlet.SolrDispatchFilter init SEVERE: Could not start
SOLR. Check solr/home property java.lang.RuntimeException: Can't find
resource 'solrconfig.xml' in classpath or '/data/solr/conf/', cwd=/ ^Iat
org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:168)
^Iat
org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:136)
^Iat org.apache.solr.core.Config.(Config.java:97) ^Iat
org.apache.solr.core.SolrConfig.(SolrConfig.java:108) ^Iat
org.apache.solr.core.SolrConfig.(SolrConfig.java:65) ^Iat
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:89)
^Iat
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:221)
^Iat
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:302)
^Iat
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:78)
^Iat org.apache.catalin
Oct  3 08:53:43 solr-test jsvc.exec[24013]: text.java:3635) ^Iat
org.apache.catalina.core.StandardContext.start(StandardContext.java:4222)
^Iat
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
^Iat org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
^Iat org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
^Iat
org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:626)
^Iat
org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
^Iat org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:488)
^Iat org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138) ^Iat
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
^Iat
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
^Iat org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1022)
^Iat org.apache.catalina.core.StandardHost.start(StandardHost.java:736) ^Iat
org.apache.catali
Oct  3 08:53:43 solr-test jsvc.exec[24013]: 14) ^Iat
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) ^Iat
org.apache.catalina.core.StandardService.start(StandardService.java:448)
^Iat org.apache.cata

Re: Check solr/home property

2008-10-02 Thread Chris Hostetter
: 
: I don't know why in my logs I've this error:
: 
: Could not start SOLR. Check solr/home property java.lang.RuntimeException:
: Can't find resource 'solrconfig.xml' in classpath or 'solr/conf/',

what get's logged before and that?  what is the full error with the full 
stack trace? ... it's possible that you aren't specifyingthe Solr Home 
properly -- or it's possible you are specifying it properly, but there is 
a severe error in your configs ... we can't know without seeing hte full 
error.



-Hoss



Check solr/home property

2008-10-01 Thread sunnyfr

Hi everybody,

I don't know why in my logs I've this error:

Could not start SOLR. Check solr/home property java.lang.RuntimeException:
Can't find resource 'solrconfig.xml' in classpath or 'solr/conf/',

Help would be more than welcome.
Cheers,
-- 
View this message in context: 
http://www.nabble.com/Check-solr-home-property-tp19757163p19757163.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Solr 1.3 does not recognize Solr home...

2008-09-22 Thread Ryan McKinley


I have temporarily solved the problem by hardcoding the folders in the
 element like so:

C:\tomcatweb\merchant\data   (in the  
solrconfig.xml)


Any ideas of what I am doing wrong?



Is it solr home or or the data directory that is getting set wrong?

I *think* the difference is that with 1.2, you could not use  
properties to set the dataDir, it was hardcoded to "/data/" relative  
to your solr home.


In 1.3, the example comes with a default property ${data.dir:./data}  
(or something like that


If you remove the  element altogether, it should go back to  
1.2 behavior...


ryan



Solr 1.3 does not recognize Solr home...

2008-09-22 Thread William Pierce

Folks:

I have an odd situation that I am hoping someone can shed light on.

I have a solr apps running under tomcat 6.0.14 (on a windows xp sp3 
machine).

The app is declared in the tomcat config file as follows:

In file "merchant.xml" for the "merchant" app:


  


I have of course created the folders:  c:\tomcatweb\merchant under which you 
can find the "data", "conf" and

"bin" folders.

Now this configuration worked with 1.2.  It also worked with the 1.3
solr.war but still using the older 1.2 config files that I have been using.

The problem comes when I use the 1.3 solr.war and use the new 1.3
solrconfig.xml files.  I used as a base the config files found in the
"example" folder of the 1.3 bits I downloaded.  I then modified these files
by including
the various fields, field types, and the request handler definitions, etc
that are particular to my configuration.

When I start up tomcat,  I notice that the home directory is set to
"Windows\system32\solr" and the requisite index files are being created
under that.

I have temporarily solved the problem by hardcoding the folders in the
 element like so:

C:\tomcatweb\merchant\data   (in the solrconfig.xml)

Any ideas of what I am doing wrong?





Re: What is the variable in sfconfig.xml for solr home

2008-08-08 Thread Jacob Singh
Hi SHalin,

I'm using JNDI and to set the solr home via an override like so:

  
    solr/home
path/to/solr/home
java.lang.String
  


This works like a charm, and I have 20 instances which all link to the
same conf/ folder which has the solrconfig.xml

It's just that I don't think I need 20 solrconfig.xml files since they
are all identical except the section in question below.

Best,
Jacob

Shalin Shekhar Mangar wrote:
> Not sure why you are passing the args. If you are using the standard
> directory structure, it may not be needed.
> 
> Try removing the args and env sections and see. It works great for me that
> way.
> 
> On Fri, Aug 8, 2008 at 12:57 PM, Jacob Singh <[EMAIL PROTECTED]> wrote:
> 
>> Hi Shanlin,
>>
>> Thanks for your reply.
>>
>> I tried the following:
>> 
>>  /opt/solr/bin/snapshooter
>>  /opt/solr/bin
>>  true
>>   -d ${solr.solr.home:.}/data  
>>   MYVAR=val1 
>>
>> in my solrconfig.xml
>>
>> but I always get the default (.).  I am using overrides through JNDI to
>> set solr/home and this works fine for everything, but it seems the
>> variable is not set here  I'm testing it by putting a logging call
>> of $* in snapshooter, and it always receives -d ./data
>>
>> Do you have any idea what could be causing it?
>>
>> Best,
>> Jacob
>>
>> Shalin Shekhar Mangar wrote:
>>> You can set solr home by passing -Dsolr.solr.home=/path/to/solr/home when
>>> running your container (the double solr is *not* a typo)
>>>
>>> You can also use JNDI to configure it. Look under the "Installation and
>>> Configuration" section in the wiki for container-specific instructions:
>>> http://wiki.apache.org/solr/
>>>
>>> On Fri, Aug 8, 2008 at 6:26 AM, Jacob Singh <[EMAIL PROTECTED]>
>> wrote:
>>>> I see in the docs:
>>>>
>>>> System property substitution
>>>>
>>>> Solr supports system property substitution, allowing the launching JVM
>>>> to specify string substitutions within either of Solr's configuration
>>>> files. The syntax ${property[:default value]}. Substitutions are valid
>>>> in any element or attribute text. Here's an example of allowing the
>>>> runtime to dictate the data directory:
>>>>
>>>>   ${solr.data.dir:./solr/data}
>>>>
>>>>
>>>> So what is the property for solr home?  I've tried solr.home,
>>>> solr.solr/home (from JNDI), solr.solrhome...
>>>>
>>>> Thanks,
>>>> Jacob
>>>>
>>>> P.S. is there a list of properties available somewhere?
>>>>
>>>>
>>>
>>
> 
> 



Re: What is the variable in sfconfig.xml for solr home

2008-08-08 Thread Shalin Shekhar Mangar
Not sure why you are passing the args. If you are using the standard
directory structure, it may not be needed.

Try removing the args and env sections and see. It works great for me that
way.

On Fri, Aug 8, 2008 at 12:57 PM, Jacob Singh <[EMAIL PROTECTED]> wrote:

> Hi Shanlin,
>
> Thanks for your reply.
>
> I tried the following:
> 
>  /opt/solr/bin/snapshooter
>  /opt/solr/bin
>  true
>   -d ${solr.solr.home:.}/data  
>   MYVAR=val1 
>
> in my solrconfig.xml
>
> but I always get the default (.).  I am using overrides through JNDI to
> set solr/home and this works fine for everything, but it seems the
> variable is not set here  I'm testing it by putting a logging call
> of $* in snapshooter, and it always receives -d ./data
>
> Do you have any idea what could be causing it?
>
> Best,
> Jacob
>
> Shalin Shekhar Mangar wrote:
> > You can set solr home by passing -Dsolr.solr.home=/path/to/solr/home when
> > running your container (the double solr is *not* a typo)
> >
> > You can also use JNDI to configure it. Look under the "Installation and
> > Configuration" section in the wiki for container-specific instructions:
> > http://wiki.apache.org/solr/
> >
> > On Fri, Aug 8, 2008 at 6:26 AM, Jacob Singh <[EMAIL PROTECTED]>
> wrote:
> >
> >> I see in the docs:
> >>
> >> System property substitution
> >>
> >> Solr supports system property substitution, allowing the launching JVM
> >> to specify string substitutions within either of Solr's configuration
> >> files. The syntax ${property[:default value]}. Substitutions are valid
> >> in any element or attribute text. Here's an example of allowing the
> >> runtime to dictate the data directory:
> >>
> >>   ${solr.data.dir:./solr/data}
> >>
> >>
> >> So what is the property for solr home?  I've tried solr.home,
> >> solr.solr/home (from JNDI), solr.solrhome...
> >>
> >> Thanks,
> >> Jacob
> >>
> >> P.S. is there a list of properties available somewhere?
> >>
> >>
> >
> >
>
>


-- 
Regards,
Shalin Shekhar Mangar.


Re: What is the variable in sfconfig.xml for solr home

2008-08-08 Thread Jacob Singh
Hi Shanlin,

Thanks for your reply.

I tried the following:

  /opt/solr/bin/snapshooter
  /opt/solr/bin
  true
   -d ${solr.solr.home:.}/data  
   MYVAR=val1 

in my solrconfig.xml

but I always get the default (.).  I am using overrides through JNDI to
set solr/home and this works fine for everything, but it seems the
variable is not set here  I'm testing it by putting a logging call
of $* in snapshooter, and it always receives -d ./data

Do you have any idea what could be causing it?

Best,
Jacob

Shalin Shekhar Mangar wrote:
> You can set solr home by passing -Dsolr.solr.home=/path/to/solr/home when
> running your container (the double solr is *not* a typo)
> 
> You can also use JNDI to configure it. Look under the "Installation and
> Configuration" section in the wiki for container-specific instructions:
> http://wiki.apache.org/solr/
> 
> On Fri, Aug 8, 2008 at 6:26 AM, Jacob Singh <[EMAIL PROTECTED]> wrote:
> 
>> I see in the docs:
>>
>> System property substitution
>>
>> Solr supports system property substitution, allowing the launching JVM
>> to specify string substitutions within either of Solr's configuration
>> files. The syntax ${property[:default value]}. Substitutions are valid
>> in any element or attribute text. Here's an example of allowing the
>> runtime to dictate the data directory:
>>
>>   ${solr.data.dir:./solr/data}
>>
>>
>> So what is the property for solr home?  I've tried solr.home,
>> solr.solr/home (from JNDI), solr.solrhome...
>>
>> Thanks,
>> Jacob
>>
>> P.S. is there a list of properties available somewhere?
>>
>>
> 
> 



Re: What is the variable in sfconfig.xml for solr home

2008-08-07 Thread Shalin Shekhar Mangar
You can set solr home by passing -Dsolr.solr.home=/path/to/solr/home when
running your container (the double solr is *not* a typo)

You can also use JNDI to configure it. Look under the "Installation and
Configuration" section in the wiki for container-specific instructions:
http://wiki.apache.org/solr/

On Fri, Aug 8, 2008 at 6:26 AM, Jacob Singh <[EMAIL PROTECTED]> wrote:

> I see in the docs:
>
> System property substitution
>
> Solr supports system property substitution, allowing the launching JVM
> to specify string substitutions within either of Solr's configuration
> files. The syntax ${property[:default value]}. Substitutions are valid
> in any element or attribute text. Here's an example of allowing the
> runtime to dictate the data directory:
>
>   ${solr.data.dir:./solr/data}
>
>
> So what is the property for solr home?  I've tried solr.home,
> solr.solr/home (from JNDI), solr.solrhome...
>
> Thanks,
> Jacob
>
> P.S. is there a list of properties available somewhere?
>
>


-- 
Regards,
Shalin Shekhar Mangar.


What is the variable in sfconfig.xml for solr home

2008-08-07 Thread Jacob Singh
I see in the docs:

System property substitution

Solr supports system property substitution, allowing the launching JVM
to specify string substitutions within either of Solr's configuration
files. The syntax ${property[:default value]}. Substitutions are valid
in any element or attribute text. Here's an example of allowing the
runtime to dictate the data directory:

   ${solr.data.dir:./solr/data}


So what is the property for solr home?  I've tried solr.home,
solr.solr/home (from JNDI), solr.solrhome...

Thanks,
Jacob

P.S. is there a list of properties available somewhere?



Re: Problems finding solr/home using JNDI on tomcat

2008-06-13 Thread Kjeld Froberg

Hi, yes, it is writable for tomcat.

Thanks for trying to help

Kjeld

Stefan Oestreicher skrev:
Unfortunately I'm neither a solr nor a tomcat expert.

My setup is as follows:

solr.xml in /etc/tomcat5.5/Catalina//solr.xml





And my ?

HTH,

Stefan Oestreicher

--
Dr. Maté GmbH
Stefan Oestreicher / Entwicklung
[EMAIL PROTECTED]
http://www.netdoktor.at
Tel Buero: + 43 1 405 55 75 24
Fax Buero: + 43 1 405 55 75 55
Alser Str. 4 1090 Wien Altes AKH Hof 1 1.6.6

-Ursprüngliche Nachricht-
Von: Kjeld Froberg [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 13. Juni 2008 11:42
An: solr-user@lucene.apache.org
Betreff: Re: Problems finding solr/home using JNDI on tomcat

Hi,
Same problem.

Contextfile:

   

Output.

13-06-2008 11:36:20 org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
13-06-2008 11:36:20 org.apache.solr.core.Config getInstanceDir
INFO: JNDI not configured for Solr (NoInitialContextEx)
13-06-2008 11:36:20 org.apache.solr.core.Config getInstanceDir

Regards
Kjeld


Stefan Oestreicher skrev:
  Hi,

  I'm using tomcat5.5 too. I believe you need to specify override to be
true.

  
 
  

  HTH,

  mit freundlichen Grüßen,

  Stefan Oestreicher

  --
  Dr. Maté GmbH
  Stefan Oestreicher / Entwicklung
  [EMAIL PROTECTED]
  http://www.netdoktor.at
  Tel Buero: + 43 1 405 55 75 24
  Fax Buero: + 43 1 405 55 75 55
  Alser Str. 4 1090 Wien Altes AKH Hof 1 1.6.6

  -Ursprüngliche Nachricht-
  Von: Kjeld Froberg [mailto:[EMAIL PROTECTED]
  Gesendet: Freitag, 13. Juni 2008 11:22
  An: solr-user@lucene.apache.org
  Betreff: Problems finding solr/home using JNDI on tomcat

  Hi

  I'm using solr 1.2.0 on a Tomcat 5.5 engine And have copied a solr.xml in
  catalina_home/conf/hostname

  
 
  

  And Tomcat certainly reads the solr.xml file, because solr is deployed
fine.
  However it cannot find the environment property, because there is a
  javax.naming.NoInitialContextException when trying to lookup the JNDI
name.

  13-06-2008 10:24:46 org.apache.solr.servlet.SolrDispatchFilter init
  INFO: SolrDispatchFilter.init()
  13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir
  INFO: JNDI not configured for Solr (NoInitialContextEx)
  13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir

  Any suggestions for how to solve that?

  Regards
  Kjeld




Re: Problems finding solr/home using JNDI on tomcat

2008-06-13 Thread Stefan Oestreicher
Unfortunately I'm neither a solr nor a tomcat expert.

My setup is as follows:

solr.xml in /etc/tomcat5.5/Catalina//solr.xml





And my  is /data/java/dev02

Is your solr.home writable by tomcat and outside of ? 

HTH,

Stefan Oestreicher
 
--
Dr. Maté GmbH
Stefan Oestreicher / Entwicklung
[EMAIL PROTECTED]
http://www.netdoktor.at
Tel Buero: + 43 1 405 55 75 24
Fax Buero: + 43 1 405 55 75 55
Alser Str. 4 1090 Wien Altes AKH Hof 1 1.6.6

-Ursprüngliche Nachricht-
Von: Kjeld Froberg [mailto:[EMAIL PROTECTED] 
Gesendet: Freitag, 13. Juni 2008 11:42
An: solr-user@lucene.apache.org
Betreff: Re: Problems finding solr/home using JNDI on tomcat

Hi,
Same problem.

Contextfile:



Output.

13-06-2008 11:36:20 org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
13-06-2008 11:36:20 org.apache.solr.core.Config getInstanceDir
INFO: JNDI not configured for Solr (NoInitialContextEx)
13-06-2008 11:36:20 org.apache.solr.core.Config getInstanceDir

Regards
Kjeld


Stefan Oestreicher skrev:
  Hi,

  I'm using tomcat5.5 too. I believe you need to specify override to be
true.

  
 
  

  HTH,

  mit freundlichen Grüßen,

  Stefan Oestreicher

  --
  Dr. Maté GmbH
  Stefan Oestreicher / Entwicklung
  [EMAIL PROTECTED]
  http://www.netdoktor.at
  Tel Buero: + 43 1 405 55 75 24
  Fax Buero: + 43 1 405 55 75 55
  Alser Str. 4 1090 Wien Altes AKH Hof 1 1.6.6

  -Ursprüngliche Nachricht-
  Von: Kjeld Froberg [mailto:[EMAIL PROTECTED]
  Gesendet: Freitag, 13. Juni 2008 11:22
  An: solr-user@lucene.apache.org
  Betreff: Problems finding solr/home using JNDI on tomcat

  Hi

  I'm using solr 1.2.0 on a Tomcat 5.5 engine And have copied a solr.xml in
  catalina_home/conf/hostname

  
 
  

  And Tomcat certainly reads the solr.xml file, because solr is deployed
fine.
  However it cannot find the environment property, because there is a
  javax.naming.NoInitialContextException when trying to lookup the JNDI
name.

  13-06-2008 10:24:46 org.apache.solr.servlet.SolrDispatchFilter init
  INFO: SolrDispatchFilter.init()
  13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir
  INFO: JNDI not configured for Solr (NoInitialContextEx)
  13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir

  Any suggestions for how to solve that?

  Regards
  Kjeld




Re: Problems finding solr/home using JNDI on tomcat

2008-06-13 Thread Kjeld Froberg

Hi,
Same problem.

Contextfile:

  value="/solr/example/solr" override="true"/>



Output.

13-06-2008 11:36:20 org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
13-06-2008 11:36:20 org.apache.solr.core.Config getInstanceDir
INFO: JNDI not configured for Solr (NoInitialContextEx)
13-06-2008 11:36:20 org.apache.solr.core.Config getInstanceDir

Regards
Kjeld


Stefan Oestreicher skrev:
 Hi,

 I'm using tomcat5.5 too. I believe you need to specify override to be 
true.


 

 

 HTH,

 mit freundlichen Grüßen,

 Stefan Oestreicher

 --
 Dr. Maté GmbH
 Stefan Oestreicher / Entwicklung
 [EMAIL PROTECTED]
 http://www.netdoktor.at
 Tel Buero: + 43 1 405 55 75 24
 Fax Buero: + 43 1 405 55 75 55
 Alser Str. 4 1090 Wien Altes AKH Hof 1 1.6.6

 -Ursprüngliche Nachricht-
 Von: Kjeld Froberg [mailto:[EMAIL PROTECTED]
 Gesendet: Freitag, 13. Juni 2008 11:22
 An: solr-user@lucene.apache.org
 Betreff: Problems finding solr/home using JNDI on tomcat

 Hi

 I'm using solr 1.2.0 on a Tomcat 5.5 engine And have copied a solr.xml in
 catalina_home/conf/hostname

 

 

 And Tomcat certainly reads the solr.xml file, because solr is deployed 
fine.

 However it cannot find the environment property, because there is a
 javax.naming.NoInitialContextException when trying to lookup the JNDI 
name.


 13-06-2008 10:24:46 org.apache.solr.servlet.SolrDispatchFilter init
 INFO: SolrDispatchFilter.init()
 13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir
 INFO: JNDI not configured for Solr (NoInitialContextEx)
 13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir

 Any suggestions for how to solve that?

 Regards
 Kjeld



Re: Problems finding solr/home using JNDI on tomcat

2008-06-13 Thread Stefan Oestreicher
Hi,

I'm using tomcat5.5 too. I believe you need to specify override to be true.


   


HTH,

mit freundlichen Grüßen,
 
Stefan Oestreicher
 
--
Dr. Maté GmbH
Stefan Oestreicher / Entwicklung
[EMAIL PROTECTED]
http://www.netdoktor.at
Tel Buero: + 43 1 405 55 75 24
Fax Buero: + 43 1 405 55 75 55
Alser Str. 4 1090 Wien Altes AKH Hof 1 1.6.6

-Ursprüngliche Nachricht-
Von: Kjeld Froberg [mailto:[EMAIL PROTECTED] 
Gesendet: Freitag, 13. Juni 2008 11:22
An: solr-user@lucene.apache.org
Betreff: Problems finding solr/home using JNDI on tomcat

Hi

I'm using solr 1.2.0 on a Tomcat 5.5 engine And have copied a solr.xml in
catalina_home/conf/hostname


   


And Tomcat certainly reads the solr.xml file, because solr is deployed fine.
However it cannot find the environment property, because there is a
javax.naming.NoInitialContextException when trying to lookup the JNDI name.

13-06-2008 10:24:46 org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir
INFO: JNDI not configured for Solr (NoInitialContextEx)
13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir

Any suggestions for how to solve that?

Regards
Kjeld



Problems finding solr/home using JNDI on tomcat

2008-06-13 Thread Kjeld Froberg

Hi

I'm using solr 1.2.0 on a Tomcat 5.5 engine
And have copied a solr.xml in catalina_home/conf/hostname


  value="/solr/example/solr"/>



And Tomcat certainly reads the solr.xml file, because solr is deployed fine.
However it cannot find the environment property, because there is a 
javax.naming.NoInitialContextException when trying to lookup the JNDI name.


13-06-2008 10:24:46 org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir
INFO: JNDI not configured for Solr (NoInitialContextEx)
13-06-2008 10:24:46 org.apache.solr.core.Config getInstanceDir

Any suggestions for how to solve that?

Regards
Kjeld


Re: Tomcat 6.0 solr home not set (solved)

2008-03-22 Thread Chris Hostetter

: Well, just to add to this, the fact is that Tomcat (or any other container)
: will probably never have info about SOLR so while I sympathize with the
: "cleanness" aspect of not providing this info, it sucks when one is trying to
: figure it out.

right ... but generic things about tomcat (like what a context file is, 
what the "path" attribute was for prior to Tomcat 5.5, where the access 
log is kept, etc...) can be found in the tomcat documentation ... putting 
lots of details about things like that in the SolrTomcat wiki isn't really 
appropriate ... that page should focus on stuff about Tomcat you should 
know if you are running Solr that you may not have ever learned about or 
worried about before even if you've been using tomcat for a long time.

: I subscribed to the wiki but I'm a little wary.  Should I (can I?) just change
: the page?  Or should I look at the markup, modify it and send it to you (or
: someone)?

it's a wiki ... edit away.  email notification about all edits go to 
to the colr-commits list, if people disagree with something they'll 
discuss it on solr-dev  ...  or just change it again. :)



-Hoss



Re: Tomcat 6.0 solr home not set (solved)

2008-03-22 Thread David Arpad Geller
Well, just to add to this, the fact is that Tomcat (or any other 
container) will probably never have info about SOLR so while I 
sympathize with the "cleanness" aspect of not providing this info, it 
sucks when one is trying to figure it out.


I subscribed to the wiki but I'm a little wary.  Should I (can I?) just 
change the page?  Or should I look at the markup, modify it and send it 
to you (or someone)?


David

Chris Hostetter wrote:
I guess what I'm saying is: people should add any detail to 
the SolrTomcat page (and the other container pages) that's relevant to 
running Solr, but we should try to organize it in such a way that if you 
are already very knowledgable about Tomcat, you don't have to wade through 
a ton of stuff you already know to get to the stuff that's *really* Solr 
specific.


-Hoss

  

--
They must find it difficult, those who have taken authority as truth, rather 
than truth as authority. - Gerald Massey



Re: Tomcat 6.0 solr home not set (solved)

2008-03-21 Thread Chris Hostetter

: b) the need for a solr home directory and what that is for / what that means

There is some info aboutthis on the general SolrInstall page...

http://wiki.apache.org/solr/SolrInstall

which referes to example/solr (where a README.txtfile goes into more 
details)

If you (coming from the perspective of a new user) would like to elaborate 
on that some more, that would be great ... new users are the best people 
to write intro docs and FAQs because they know from recent experience what 
isn't obvious.

(I'm also going to add "Solr Home" to the SolrTerminology page)


As for the tomcat specific stuff  i'm of two minds on this.  In 
general we should try to keep the container specific information on topic: 
using solr with thatcontainer.  we can't (and shouldn't try to be) a 
general resource for the usage/vocabulary/configuration/quirks of every 
Servlet Container out there ... if someone wants to use Solr on resin, 
then they presumably have a reason for that and alrady know resin ... if 
not, we should just provide them with some handy links toget get more info 
about resin, and stay focused on teh core issue for us: "Solr on Resin" 
... likewise for Tomcat, Jetty, websephere, whatever.

On the other hand: we don't want to frustrate people.  A lot of people 
taking on new projects have to ramp up on multiple technologies -- if 
someone knows they want to use Solr, therefore needs to get a servlet 
container up and running and for whatever reason has a specific need to 
use container XYZ, then we should try to give them *all* the info they 
need to run SOlr on XYZ< even if some of it isn't specific to Solr.

I guess what I'm saying is: people should add any detail to 
the SolrTomcat page (and the other container pages) that's relevant to 
running Solr, but we should try to organize it in such a way that if you 
are already very knowledgable about Tomcat, you don't have to wade through 
a ton of stuff you already know to get to the stuff that's *really* Solr 
specific.

-Hoss



Re: Tomcat 6.0 solr home not set (solved)

2008-03-19 Thread Matthew Runo

Go for it!

Matthew Runo

On Mar 19, 2008, at 12:17 PM, David Arpad Geller wrote:


Hallelujah!

So, it's clear to me that neither the Tomcat docs or the Solr/Tomcat  
wiki page is completely clear on this topic.  Specifically, the  
parts about:
a) the way to specify webapps using Catalina/localhost/.xml  
(and how it relates to solr)
b) the need for a solr home directory and what that is for / what  
that means

c) a general desire not to run a nightly build version

Hopefully this thread will serve others but perhaps the wiki could  
be updated?  I'd be happy to provide changes to the page and provide  
it or make the update myself if allowed if you all agree.


David

Jayson Minard wrote:

I'll take the Tomcat question first:

--- snip ---

Also, the Tomcat page for Context says:
-
You may define as many *Context* elements as you wish. Each such  
Context
MUST have a unique context path. In addition, a Context must be  
present
with a context path equal to a zero-length string. This Context  
becomes

the /default/ web application for this virtual host, and is used to
process all requests that do not match any other Context's context  
path.

--
Which also isn't clear to me.  "...context path equal to a zero- 
length
string?"  I guess I'm misunderstanding what "context path" is.  It  
seems
to me that this describes "localhost/solr.xml."  Am I missing  
something

here?

--- end snip ---

It is just saying there must be at least one blank context which is
the root "/" URL for the Tomcat server.  It is already defined and  
you

can ignore this unless you start deleting other contexts defined
elsewhere.  So pretend you did not read that at all and you'll be
dandy!

The NoClassDefFoundError is an odd one.  You are running JDK 1.6 (not
JDK 1.5) and Tomcat 6 so base classes should be present, and the WAR
contains everything else.

Did you modify the solrconfig.xml file, possibly change any class
names in there that are referenced?  Or in your schema point to a
class that does not exist?  Something there might cause a failure
during that part of the loading.

Or you are not pointing to the right solr home.  In fact, your Solr
home looks wrong and is the likely culprit.  It should point to your
own directory that you created that contains a copy of the conf
directory from the example deployment.

mkdir solr-data
cd solr-data
mkdir conf
cd conf
cp -R /usr/local/apache-solr-1.2.0/example/solr/conf/* .

then set the /solr/home to this new solr-data directory (which now
contains the conf directory)

--j

--j

On Wed, Mar 19, 2008 at 11:37 AM, David Arpad Geller
<[EMAIL PROTECTED]> wrote:


So it seems that I got Tomcat to recognize where solr is with this
conf/Catalina/localhost/solr.xml:



  


But still, there's still some problem (see below).  Thank you for  
all of

the help, it's good stuff to know.

Also, the Tomcat page for Context says:
-
You may define as many *Context* elements as you wish. Each such  
Context
MUST have a unique context path. In addition, a Context must be  
present
with a context path equal to a zero-length string. This Context  
becomes

the /default/ web application for this virtual host, and is used to
process all requests that do not match any other Context's context  
path.

--
Which also isn't clear to me.  "...context path equal to a zero- 
length
string?"  I guess I'm misunderstanding what "context path" is.  It  
seems
to me that this describes "localhost/solr.xml."  Am I missing  
something

here?


---

INFO: HTMLManager: start: Starting web application at '/solr'
Mar 19, 2008 2:07:27 PM org.apache.solr.servlet.SolrDispatchFilter  
init

INFO: SolrDispatchFilter.init()
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getInstanceDir
INFO: Using JNDI solr.home: /usr/local/apache-solr-1.2.0
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config setInstanceDir
INFO: Solr home set to '/usr/local/apache-solr-1.2.0/'
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding
'file:/usr/local/apache-solr-1.2.0/lib/commons-csv-0.1- 
SNAPSHOT.jar' to

Solr classloader
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding
'file:/usr/local/apache-solr-1.2.0/lib/lucene- 
highlighter-2007-05-20_00-04-53.jar'

to Solr classloader
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding
'file:/usr/local/apache-solr-1.2.0/lib/lucene- 
analyzers-2007-05-20_00-04-53.jar'

to Solr classloader
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/easymock.jar' to
Solr classloader
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding
'file:/usr/local/apache-solr-1.2.0/lib/lucene- 

Re: Tomcat 6.0 solr home not set (solved)

2008-03-19 Thread David Arpad Geller

Hallelujah!

So, it's clear to me that neither the Tomcat docs or the Solr/Tomcat 
wiki page is completely clear on this topic.  Specifically, the parts about:
a) the way to specify webapps using Catalina/localhost/.xml (and 
how it relates to solr)

b) the need for a solr home directory and what that is for / what that means
c) a general desire not to run a nightly build version

Hopefully this thread will serve others but perhaps the wiki could be 
updated?  I'd be happy to provide changes to the page and provide it or 
make the update myself if allowed if you all agree.


David

Jayson Minard wrote:

I'll take the Tomcat question first:

--- snip ---

Also, the Tomcat page for Context says:
-
You may define as many *Context* elements as you wish. Each such Context
MUST have a unique context path. In addition, a Context must be present
with a context path equal to a zero-length string. This Context becomes
the /default/ web application for this virtual host, and is used to
process all requests that do not match any other Context's context path.
--
Which also isn't clear to me.  "...context path equal to a zero-length
string?"  I guess I'm misunderstanding what "context path" is.  It seems
to me that this describes "localhost/solr.xml."  Am I missing something
here?

--- end snip ---

It is just saying there must be at least one blank context which is
the root "/" URL for the Tomcat server.  It is already defined and you
can ignore this unless you start deleting other contexts defined
elsewhere.  So pretend you did not read that at all and you'll be
dandy!

The NoClassDefFoundError is an odd one.  You are running JDK 1.6 (not
JDK 1.5) and Tomcat 6 so base classes should be present, and the WAR
contains everything else.

Did you modify the solrconfig.xml file, possibly change any class
names in there that are referenced?  Or in your schema point to a
class that does not exist?  Something there might cause a failure
during that part of the loading.

Or you are not pointing to the right solr home.  In fact, your Solr
home looks wrong and is the likely culprit.  It should point to your
own directory that you created that contains a copy of the conf
directory from the example deployment.

mkdir solr-data
cd solr-data
mkdir conf
cd conf
cp -R /usr/local/apache-solr-1.2.0/example/solr/conf/* .

then set the /solr/home to this new solr-data directory (which now
contains the conf directory)

--j

--j

On Wed, Mar 19, 2008 at 11:37 AM, David Arpad Geller
<[EMAIL PROTECTED]> wrote:
  

So it seems that I got Tomcat to recognize where solr is with this
 conf/Catalina/localhost/solr.xml:

 

   
 

 But still, there's still some problem (see below).  Thank you for all of
 the help, it's good stuff to know.

 Also, the Tomcat page for Context says:
 -
 You may define as many *Context* elements as you wish. Each such Context
 MUST have a unique context path. In addition, a Context must be present
 with a context path equal to a zero-length string. This Context becomes
 the /default/ web application for this virtual host, and is used to
 process all requests that do not match any other Context's context path.
 --
 Which also isn't clear to me.  "...context path equal to a zero-length
 string?"  I guess I'm misunderstanding what "context path" is.  It seems
 to me that this describes "localhost/solr.xml."  Am I missing something
 here?


 ---

INFO: HTMLManager: start: Starting web application at '/solr'
 Mar 19, 2008 2:07:27 PM org.apache.solr.servlet.SolrDispatchFilter init
 INFO: SolrDispatchFilter.init()
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getInstanceDir
 INFO: Using JNDI solr.home: /usr/local/apache-solr-1.2.0
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config setInstanceDir
 INFO: Solr home set to '/usr/local/apache-solr-1.2.0/'
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
 INFO: Adding
 'file:/usr/local/apache-solr-1.2.0/lib/commons-csv-0.1-SNAPSHOT.jar' to
 Solr classloader
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
 INFO: Adding
 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-highlighter-2007-05-20_00-04-53.jar'
 to Solr classloader
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
 INFO: Adding
 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-analyzers-2007-05-20_00-04-53.jar'
 to Solr classloader
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
 INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/easymock.jar' to
 Solr classloader
 Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
 INFO: Adding
 'file:/usr/local/apache-solr-1.2.0/lib/lucene-core-2007-05-20_00-04-53.jar'
 to Solr classloader
 Mar 19, 2008 2:07:27 PM org.apache.solr.core

Re: Tomcat 6.0 solr home not set

2008-03-19 Thread Jayson Minard
I'll take the Tomcat question first:

--- snip ---

Also, the Tomcat page for Context says:
-
You may define as many *Context* elements as you wish. Each such Context
MUST have a unique context path. In addition, a Context must be present
with a context path equal to a zero-length string. This Context becomes
the /default/ web application for this virtual host, and is used to
process all requests that do not match any other Context's context path.
--
Which also isn't clear to me.  "...context path equal to a zero-length
string?"  I guess I'm misunderstanding what "context path" is.  It seems
to me that this describes "localhost/solr.xml."  Am I missing something
here?

--- end snip ---

It is just saying there must be at least one blank context which is
the root "/" URL for the Tomcat server.  It is already defined and you
can ignore this unless you start deleting other contexts defined
elsewhere.  So pretend you did not read that at all and you'll be
dandy!

The NoClassDefFoundError is an odd one.  You are running JDK 1.6 (not
JDK 1.5) and Tomcat 6 so base classes should be present, and the WAR
contains everything else.

Did you modify the solrconfig.xml file, possibly change any class
names in there that are referenced?  Or in your schema point to a
class that does not exist?  Something there might cause a failure
during that part of the loading.

Or you are not pointing to the right solr home.  In fact, your Solr
home looks wrong and is the likely culprit.  It should point to your
own directory that you created that contains a copy of the conf
directory from the example deployment.

mkdir solr-data
cd solr-data
mkdir conf
cd conf
cp -R /usr/local/apache-solr-1.2.0/example/solr/conf/* .

then set the /solr/home to this new solr-data directory (which now
contains the conf directory)

--j

--j

On Wed, Mar 19, 2008 at 11:37 AM, David Arpad Geller
<[EMAIL PROTECTED]> wrote:
> So it seems that I got Tomcat to recognize where solr is with this
>  conf/Catalina/localhost/solr.xml:
>
>  docBase="/usr/local/apache-solr-1.2.0/dist/apache-solr-1.2.0.war"
>
>debug="0"
>crossContext="true" >
>
> value="/usr/local/apache-solr-1.2.0"
>
> type="java.lang.String"
> override="true" />
>  
>
>  But still, there's still some problem (see below).  Thank you for all of
>  the help, it's good stuff to know.
>
>  Also, the Tomcat page for Context says:
>  -
>  You may define as many *Context* elements as you wish. Each such Context
>  MUST have a unique context path. In addition, a Context must be present
>  with a context path equal to a zero-length string. This Context becomes
>  the /default/ web application for this virtual host, and is used to
>  process all requests that do not match any other Context's context path.
>  --
>  Which also isn't clear to me.  "...context path equal to a zero-length
>  string?"  I guess I'm misunderstanding what "context path" is.  It seems
>  to me that this describes "localhost/solr.xml."  Am I missing something
>  here?
>
>
>  ---
>
> INFO: HTMLManager: start: Starting web application at '/solr'
>  Mar 19, 2008 2:07:27 PM org.apache.solr.servlet.SolrDispatchFilter init
>  INFO: SolrDispatchFilter.init()
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getInstanceDir
>  INFO: Using JNDI solr.home: /usr/local/apache-solr-1.2.0
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config setInstanceDir
>  INFO: Solr home set to '/usr/local/apache-solr-1.2.0/'
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
>  INFO: Adding
>  'file:/usr/local/apache-solr-1.2.0/lib/commons-csv-0.1-SNAPSHOT.jar' to
>  Solr classloader
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
>  INFO: Adding
>  
> 'file:/usr/local/apache-solr-1.2.0/lib/lucene-highlighter-2007-05-20_00-04-53.jar'
>  to Solr classloader
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
>  INFO: Adding
>  
> 'file:/usr/local/apache-solr-1.2.0/lib/lucene-analyzers-2007-05-20_00-04-53.jar'
>  to Solr classloader
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
>  INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/easymock.jar' to
>  Solr classloader
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
>  INFO: Adding
>  'file:/usr/local/apache-solr-1.2.0/lib/lucene-core-2007-05-20_00-04-53.jar'
>  to Solr classloader
>  Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader

Re: Tomcat 6.0 solr home not set

2008-03-19 Thread David Arpad Geller
So it seems that I got Tomcat to recognize where solr is with this 
conf/Catalina/localhost/solr.xml:




  


But still, there's still some problem (see below).  Thank you for all of 
the help, it's good stuff to know.


Also, the Tomcat page for Context says:
-
You may define as many *Context* elements as you wish. Each such Context 
MUST have a unique context path. In addition, a Context must be present 
with a context path equal to a zero-length string. This Context becomes 
the /default/ web application for this virtual host, and is used to 
process all requests that do not match any other Context's context path.

--
Which also isn't clear to me.  "...context path equal to a zero-length 
string?"  I guess I'm misunderstanding what "context path" is.  It seems 
to me that this describes "localhost/solr.xml."  Am I missing something 
here?



---
INFO: HTMLManager: start: Starting web application at '/solr'
Mar 19, 2008 2:07:27 PM org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getInstanceDir
INFO: Using JNDI solr.home: /usr/local/apache-solr-1.2.0
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config setInstanceDir
INFO: Solr home set to '/usr/local/apache-solr-1.2.0/'
Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/commons-csv-0.1-SNAPSHOT.jar' to 
Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-highlighter-2007-05-20_00-04-53.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-analyzers-2007-05-20_00-04-53.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/easymock.jar' to 
Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-core-2007-05-20_00-04-53.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/servlet-api-2.4.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/commons-codec-1.3.jar' to Solr 
classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-spellchecker-2007-05-20_00-04-53.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/lucene-snowball-2007-05-20_00-04-53.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/xpp3-1.1.3.4.O.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 'file:/usr/local/apache-solr-1.2.0/lib/commons-io-1.2.jar' 
to Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.solr.core.Config getClassLoader
INFO: Adding 
'file:/usr/local/apache-solr-1.2.0/lib/commons-fileupload-1.2.jar' to 
Solr classloader

Mar 19, 2008 2:07:27 PM org.apache.catalina.core.StandardContext filterStart
SEVERE: Exception starting filter SolrRequestFilter
java.lang.NoClassDefFoundError
   at 
org.apache.solr.servlet.SolrDispatchFilter.init(SolrDispatchFilter.java:74)

..
(Trace omitted)
..
 at java.lang.Thread.run(Thread.java:595)
Mar 19, 2008 2:07:27 PM org.apache.catalina.core.StandardContext start
SEVERE: Error filterStart
Mar 19, 2008 2:07:27 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [/solr] startup failed due to previous errors
Mar 19, 2008 2:07:27 PM org.apache.catalina.core.ApplicationContext log
INFO: HTMLManager: list: Listing contexts for virtual host 'localhost'



--
They must find it difficult, those who have taken authority as truth, rather 
than truth as authority. - Gerald Massey



Re: Tomcat 6.0 solr home not set

2008-03-19 Thread Jayson Minard
David,

I wanted to answer some of your other points so to clarify how Tomcat 6 works:


>> 1. What the heck is a "conf/Catalina/localhost?"  Is it a
directory?  A file?  I have neither a Catalina or a localhost
directory there.

You have to create these directories for Tomcat 6, they already exist
for Tomcat 5.  Under tomcat/conf you create a directory that matches
the engine name ("Catalina" is the engine you are using), and then
under that directory create a directory that matches the host name as
configured for that engine ("localhost" is the default for Catalina).
Therefore you end up with tomcat/conf/Catalina/localhost/ as a
directory to place your context files such as solr.xml which would be
something like:


   


Be sure that solr/home points to the directory that contains the conf
and index dirs and is NOT one of those dirs.

>> 2. Tomcat does absolutely nothing unless I put solr.war in its
webapps directory.  Then I can get it to fail on solr, at least.

Putting the right context file in the right place (see above) will
resolve that for you.  But under webapps is fine if you are only
running one instance, but context files are a best practice.  I avoid
putting anything under my installs and use setting CATALINA_BASE to
relocate conf, webapps, temp, logs and work directories to another
tree (see my previous e-mail which has an example of that).  But if
you want to just get working, then copy the war file in and make sure
you rename it to match the name you want on your URL (i.e. dog.war
would be http://mytomcathost:8080/dog and cat.war would be
http://mytomcathost:8080/cat.

>> 3. I tried putting the following into my server.xml file (no effect):

Don't do that for Tomcat 6.  But if you did, it needs to be inside the
host element.  But repeat, that is the last option to take.

>> 4. I tried putting the same into my context.xml file but then it
just overrode the context for the manager and ruined that whole thing
for me.

Don't do that for Tomcat 6, since all webapps would load those same
settings (and you can't put the whole context tag there but rather
just the settings from one).

See:  http://tomcat.apache.org/tomcat-6.0-doc/config/context.html and
use the option:

"in individual files (with a ".xml" extension) in the
$CATALINA_HOME/conf/[enginename]/[hostname]/ directory. The name of
the file (less the .xml extension) will be used as the context path.
Multi-level context paths may be defined using #, e.g.
context#path.xml. The default web application may be defined by using
a file called ROOT.xml."

Be warned that if you set CATALINA_BASE to something that does not
match CATALINA_HOME then the above example from the Tomcat docs is
invalid, it is actually "$CATALINA_BASE/conf/[enginename]/[hostname]/
" where the context files are placed, but absent a CATALINA_BASE being
explicitly defined, it defaults to the same as CATALINA_HOME.

--j

On Tue, Mar 18, 2008 at 10:54 PM, David Arpad Geller
<[EMAIL PROTECTED]> wrote:
> (Sorry for the double post - I committed one of my pet peeves - I didn't
>  create a descriptive subject)
>
>  I normally wouldn't just signup to a list and post immediately but...
>
>  I hope there are some Tomcat experts here.
>  I'm trying to setup solr and tomcat.  I get the following:
>
>  INFO: HTMLManager: start: Starting web application at '/solr'
>  Mar 19, 2008 12:57:26 AM org.apache.solr.servlet.SolrDispatchFilter init
>  INFO: SolrDispatchFilter.init()
>  Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config getInstanceDir
>  INFO: No /solr/home in JNDI
>  Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config getInstanceDir
>  INFO: Solr home defaulted to 'null' (could not find system property or JNDI)
>  Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config setInstanceDir
>  INFO: Solr home set to 'solr/'
>  Mar 19, 2008 12:57:26 AM org.apache.catalina.core.StandardContext
>  filterStart
>  SEVERE: Exception starting filter SolrRequestFilter
>
>
>  I get that I should be specifying my solr home somewhere and some have
>  suggested that it should be specified in
>  $CATALINA_HOME/conf/Catalina/localhost  Others have mentioned specifying
>   in a solr.xml file placed in the $CATALINA_HOME/conf
>  directory.  Others have said that solr.war is a special webapp that
>  should not be placed in the standard Tomcat webapps directory and
>  JAVA_OPTS should have solr.solr.home set.  Huh?  Where? I tried setting
>  it in the ENV before starting Tomcat to no avail. Sigh.
>
>  Help!
>
>  I'm running Tomcat 6.0.16 and SOLR 1.2.0
>
>  1. What the heck is a "conf/Catalina/localhost?"  Is it a directory?  A
>  file?  I have neither a Catalina or a localhost directory there.
>  2. Tomcat does absolutely

Re: Tomcat 6.0 solr home not set

2008-03-19 Thread Jayson Minard
David,

Here are notes on running under Tomcat 6...

First, untar Tomcat somewhere.

Now you can run tomcat either directly from the binary directories, or
relocate the CATALINA_BASE and run it elsewhere sharing the binaries
(good for multiple instances).

If running Tomcat, as-is out of the binary directories:

- modify ./conf/server.xml to adjust any ports otherwise run on
default 8080 with shutdown port 8005
- copy the solr*.war file to ./webapps while renaming to solr.war if
it isn't already called that in your build.
- create a startup script that looks something like the following:

export JAVA_OPTS="$JAVA_OPTS
-Dsolr.solr.home=/place/where/my/solr/conf/dir/is
-Dsolr.data.dir=/place/where/my/index/dir/is -Xms256m -Xmx800m"
exec ./tomcat-current/bin/startup.sh

Adjusting the memory settings how you like, and set solr.solr.home to
the folder containing your conf directory (but not directly to the
conf directory, it should be one level up).  The solr.data.dir will
point to a directory that will contain the index directory (but not
the index directory itself, it should be one level up).

So for a tree that looks like:

/search
./conf   (copy all Solr config files here including XSL
directories or link to those)
./index  (omit this directory and let Solr create it for you, or
copy in a valid index to this directory)

You can run Tomcat with:

export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=/search
-Dsolr.data.dir=/search -Xms256m -Xmx800m"
exec ./tomcat-current/bin/startup.sh

If you wish to run Tomcat outside of the binary directory, and
possibly multiple instances, use a structure such as:

/search
   shared
   solr
   conf   (copy solr/conf for your configuration here)

   instance1
   solr
   conf -> ../../../shared/solr/conf
   index
   tomcat
   conf (contents copied from tomcat/conf)
   logs (empty initially)
   temp (empty initially)
   webapps  (only include solr.war and other files from
tomcat/webapps that you wish to keep)
   work (empty initially)

For this, your Tomcat startup would be:

export JAVA_OPTS="$JAVA_OPTS -Dsolr.solr.home=/search/instance1/solr
-Dsolr.data.dir=/search/instance1/solr -Xms256m -Xmx1000m"
export CATALINA_BASE=/search/instance/tomcat
exec ./tomcat-current/bin/startup.sh

A few tricks to keep in mind:

Use symbolic links to share things, for example if you have a file in
your tomcat config that will be identical to the base installed
tomcat's version and same for all instances, just link to it rather
than copying it.  The same for the webapps directory, don't copy if
you can link.


--j

On Tue, Mar 18, 2008 at 10:54 PM, David Arpad Geller
<[EMAIL PROTECTED]> wrote:
> (Sorry for the double post - I committed one of my pet peeves - I didn't
>  create a descriptive subject)
>
>  I normally wouldn't just signup to a list and post immediately but...
>
>  I hope there are some Tomcat experts here.
>  I'm trying to setup solr and tomcat.  I get the following:
>
>  INFO: HTMLManager: start: Starting web application at '/solr'
>  Mar 19, 2008 12:57:26 AM org.apache.solr.servlet.SolrDispatchFilter init
>  INFO: SolrDispatchFilter.init()
>  Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config getInstanceDir
>  INFO: No /solr/home in JNDI
>  Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config getInstanceDir
>  INFO: Solr home defaulted to 'null' (could not find system property or JNDI)
>  Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config setInstanceDir
>  INFO: Solr home set to 'solr/'
>  Mar 19, 2008 12:57:26 AM org.apache.catalina.core.StandardContext
>  filterStart
>  SEVERE: Exception starting filter SolrRequestFilter
>
>
>  I get that I should be specifying my solr home somewhere and some have
>  suggested that it should be specified in
>  $CATALINA_HOME/conf/Catalina/localhost  Others have mentioned specifying
>   in a solr.xml file placed in the $CATALINA_HOME/conf
>  directory.  Others have said that solr.war is a special webapp that
>  should not be placed in the standard Tomcat webapps directory and
>  JAVA_OPTS should have solr.solr.home set.  Huh?  Where? I tried setting
>  it in the ENV before starting Tomcat to no avail. Sigh.
>
>  Help!
>
>  I'm running Tomcat 6.0.16 and SOLR 1.2.0
>
>  1. What the heck is a "conf/Catalina/localhost?"  Is it a directory?  A
>  file?  I have neither a Catalina or a localhost directory there.
>  2. Tomcat does absolutely nothing unless I put solr.war in its webapps
>  directory.  Then I can get it to fail on solr, at least.
>  3. I tried putting the following into my server.xml file (no effect):
>
>  docBase="/usr/local/solr/dist/apache-solr-1.2.0.war"
>debug="0"
>

Re: Tomcat 6.0 solr home not set

2008-03-18 Thread Chris Hostetter

: Honestly.  Any help would be *much* appreciated but shouldn't Tomcat be
: the easiest way to run SOLR?

The *easiest* way to get Solr up and running is to follow the example on 
the tutorial to start the Jetty server included with the release

(the tutorial assumes you are using a nightly build, but the same thing 
works with the official releases)...

http://lucene.apache.org/solr/tutorial.html

   cd example
   java -jar start.jar

...it really is that easy.

If that works for you, and you want to try tomcat next, then you should 
start by understanding why you're seeing differnet docs talking about 
solr.solr.home system properties, and JNDI, and context files.  Solr is 
very flexible in how you cna tell it where to find it's configuration 
files -- called the "Solr Home" -- just pick the one that meets your 
needs...

http://wiki.apache.org/solr/SolrInstall

If you look at the Solr wikipage on Tomcat...

http://wiki.apache.org/solr/SolrTomcat

...you'll see a "Simple Example Install" which works a lot like the out of 
hte box jetty install -- it assumes the solr home dir is ./solr relative 
where you start tomcat from. (As written it uses tomcat 5.5.25 but the 
steps would be exactly the same for tomcat 6).  For a more "permenant" 
Tomcat installation, I would suggest using JNDI ... which means creating a 
context file.  See the "Configuring Solr Home with JNDI" section of the 
same wiki page.

(NOTE: the JNDI section had some very missleading comments about Tomcat 6 
which I just (re)moved)


-Hoss



Tomcat 6.0 solr home not set

2008-03-18 Thread David Arpad Geller
(Sorry for the double post - I committed one of my pet peeves - I didn't 
create a descriptive subject)


I normally wouldn't just signup to a list and post immediately but...

I hope there are some Tomcat experts here.
I'm trying to setup solr and tomcat.  I get the following:

INFO: HTMLManager: start: Starting web application at '/solr'
Mar 19, 2008 12:57:26 AM org.apache.solr.servlet.SolrDispatchFilter init
INFO: SolrDispatchFilter.init()
Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config getInstanceDir
INFO: No /solr/home in JNDI
Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config getInstanceDir
INFO: Solr home defaulted to 'null' (could not find system property or JNDI)
Mar 19, 2008 12:57:26 AM org.apache.solr.core.Config setInstanceDir
INFO: Solr home set to 'solr/'
Mar 19, 2008 12:57:26 AM org.apache.catalina.core.StandardContext
filterStart
SEVERE: Exception starting filter SolrRequestFilter


I get that I should be specifying my solr home somewhere and some have
suggested that it should be specified in
$CATALINA_HOME/conf/Catalina/localhost  Others have mentioned specifying
 in a solr.xml file placed in the $CATALINA_HOME/conf
directory.  Others have said that solr.war is a special webapp that
should not be placed in the standard Tomcat webapps directory and
JAVA_OPTS should have solr.solr.home set.  Huh?  Where? I tried setting
it in the ENV before starting Tomcat to no avail. Sigh.

Help!

I'm running Tomcat 6.0.16 and SOLR 1.2.0

1. What the heck is a "conf/Catalina/localhost?"  Is it a directory?  A
file?  I have neither a Catalina or a localhost directory there.
2. Tomcat does absolutely nothing unless I put solr.war in its webapps
directory.  Then I can get it to fail on solr, at least.
3. I tried putting the following into my server.xml file (no effect):



  



4. I tried putting the same into my context.xml file but then it just
overrode the context for the manager and ruined that whole thing for me.

Honestly.  Any help would be *much* appreciated but shouldn't Tomcat be
the easiest way to run SOLR?

Thank you,
David


Re: solr/home

2007-10-01 Thread yo_keller

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 
 

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

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

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:
> 
>  crossContext="true" >
> 
> 
> 
> 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.



Re: context-relative solr/home

2007-09-17 Thread Chris Hostetter

: As you can see, Iÿÿve used a variable called ${context.name}, so that 
: the different contexts can use the same fragment, but be named something 
: different. This allows for a much simpler deployment, where no 
: context.xml needs to be generated and packaged into the war at deploy 
: time. Unfortunately, as far as I know, a variable like this does not 

why would you want to package a context.xml (or the solr home directory 
forthat matter)inside the war itself?  you should be able to reuse the 
same war many many times without any modifications by having seperate 
context.xml files ... you don't even need multiple copies of the war, you 
can reuse the exact same instance for multiple contexts.

: exist. So my question is this, is there a way to specify a variable like 
: this relative to the context root? Currently I am experimenting with 
: adding something to the config that makes solr home relative to the 
: getServletContext.getRealPath(). Is this my only option?

this may work in some cases, but i wouldn't count on it being very 
portable or future proof ... getRealPath specificly points out that it may 
not work for resources served out of a WAR ... i wouldn't be surpised if 
it got deprecated in the next vew API revisions.



-Hoss


context-relative solr/home

2007-09-12 Thread Arnone, Anthony
Hello all,

 

I sent this message to the Tomcat users group, and I was wondering if I’d have 
any more luck by asking people who might have had this problem: 

 

I’m trying to set up a system where I can deploy a single .war under multiple 
context names (using the ant deploy extensions). For example:

 

ant -Ddeploy-path=/solr-01 deploy

ant -Ddeploy-path=/solr-02 deploy

 

Both deploy commands use the same .war. However, I’m trying to do something 
that I’ve been unable to find a proper method for. solr/home points to a 
directory that is packed inside the .war. So, I would like to have a context 
fragment that looks like this:

 

In META-INF/context.xml

 







 

Or in WEB-INF/web.xml

 



solr/home

java.lang.String

 webapps/${context.name}/app-01/solr/



 

As you can see, I’ve used a variable called ${context.name}, so that the 
different contexts can use the same fragment, but be named something different. 
This allows for a much simpler deployment, where no context.xml needs to be 
generated and packaged into the war at deploy time. Unfortunately,  as far as I 
know, a variable like this does not exist. So my question is this, is there a 
way to specify a variable like this relative to the context root? Currently I 
am experimenting with adding something to the config that makes solr home 
relative to the getServletContext.getRealPath(). Is this my only option?

 

 

Thanks, any help would be appreciated.

Anthony Arnone



Re: solr/home

2007-09-06 Thread Erik Hatcher

Matt - hey!

In your Solr console, which of these three messages do you see?

* log.info("JNDI not configured for Solr  
(NoInitialContextEx)");

* log.info("No /solr/home in JNDI");
* log.warning("Odd RuntimeException while testing for JNDI: "
+ ex.getMessage());

before you see either this:

  log.info("using system property solr.home: " + home );

or this:

log.info("Solr home defaulted to '" + instanceDir +  
"' (could not find system property or JNDI)");


???

Thanks,
Erik


On Sep 6, 2007, at 3:41 PM, Matt Mitchell wrote:

Here you go:

crossContext="true" >
   



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







Re: solr/home

2007-09-06 Thread Matt Mitchell

Here you go:

crossContext="true" >
   



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





  1   2   >