|
osdir.com mailing list archive F.A.Q. -since 2001! |
|
|
|
Subject: Re: access denied to solr home lib dir - msg#01071List: solr-user.lucene.apache.org
by Date: Prev Next Date Index by Thread: Prev Next Thread Index
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 <hossman_lucene@xxxxxxxxx> 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.<init>(SolrResourceLoader.java:97) > : >> Â Â Â at > org.apache.solr.core.SolrResourceLoader.<init>(SolrResourceLoader.java:195) > : >> Â Â Â at org.apache.solr.core.Config.<init>(Config.java:93) > : >> Â Â Â at > org.apache.solr.servlet.SolrDispatchFilter.<init>(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. > --------------------------------------------------------------------- > >
Thread at a glance:
Previous Message by Date:PatternTokenizer questionI have defined a comma-delimited pattern tokenizer as follows: <fieldType name="text_comma" class="solr.TextField" positionIncrementGap="100"> <analyzer> <tokenizer class="solr.PatternTokenizerFactory" pattern=","/> <filter class="solr.LowerCaseFilterFactory"/> </analyzer> </fieldType> <field name="commafld" type="text_comma" indexed="true" stored="true"/> This appears to work fine when adding documents, since if I add a field commafld as "word1,WORD2,word 3" I see terms in the index as expected: "word1", "word2", and "word 3". When I query, I am expecting that the same tokenization would take place, so a query that has 'commafld:(word 3)' would match term "word 3". However, I find I have to submit the query as 'commafld:("word 3")'. That is, it seems as if whitespace tokenization is taking place, not the comma-delimited tokenization. Am I misunderstanding what should be happening or making some basic mistake? Thanks. -- View this message in context: http://old.nabble.com/PatternTokenizer-question-tp26497675p26497675.html Sent from the Solr - User mailing list archive at Nabble.com. Next Message by Date:Re: Migrating to SolrThis is really a great source of migration. I guess i will have good questions after trying. But what i know that will be a little harder will be the use of collections (facets in Solr) and hierarquical navigators. On Tue, Nov 24, 2009 at 1:05 PM, Shashi Kant <skant@xxxxxxxxxxxxx> wrote: > Here is a link that might be helpful: > > http://sesat.no/moving-from-fast-to-solr-review.html > > The site is choc-a-bloc with great information on their migration > experience. > > > On Tue, Nov 24, 2009 at 8:55 AM, Tommy Molto <tommymolto@xxxxxxxxx> wrote: > > > Hi, > > > > I'm new at Solr and i need to make a "test pilot" of a migration from > Fast > > ESP to Apache Solr, anyone had this experience before? > > > > > > Att, > > > Previous Message by Thread:Re: access denied to solr home lib dir: 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.<init>(SolrResourceLoader.java:97) : >> Â Â Â at org.apache.solr.core.SolrResourceLoader.<init>(SolrResourceLoader.java:195) : >> Â Â Â at org.apache.solr.core.Config.<init>(Config.java:93) : >> Â Â Â at org.apache.solr.servlet.SolrDispatchFilter.<init>(SolrDispatchFilter.java:65) : >> Â Â Â ... 40 more -Hoss Next Message by Thread:Weighting of synonymsHowdy, I recently rolled a custom WordNet synonym filter that pulls synonyms from WordNet during indexing. All that is nice and dandy; however, it causes problems in the sorting. Sometimes, the top match will come from a synonym rather than the original word. An example in our system is a search on the word "party". The first match was a doc with the word "company" which, in WordNet, has "party" as a synonym. So the question is: is there a way to weight original word matches more than synonym matches? In other words, I want all docs with "party" in the text to come up first, then docs whose terms have "party" as a synonym. I'm hoping there is a way ;) It would seem this would be a common enough issue. However, from my looking at the source code I fear the worst as I don't see that you can do this unless it would make sense to utilize the "type" field of Token. Thanks, Lajos
blog comments powered by Disqus
|
|