spellcheck in dismax
I put the following into dismax requestHandler, but no suggestion field is returned. lst name=defaults str name=spellcheck.onlyMorePopulartrue/str str name=spellcheck.extendedResultsfalse/str str name=spellcheck.count1/str /lst arr name=last-components strspellcheck/str /arr But everything works if I put it as a separate requestHandler. Did I miss something? Thanks Richard
Re: Solr 3.2.0 is not writing log
It works perfectly! Thank you so much!!! Ruixiang On Sun, Jul 31, 2011 at 7:56 PM, tmahesh mah...@tmahesh.com wrote: In etc/jetty.xml, at line 204, you should remove the comment (delete line 204 and line 218) 204 -- View this message in context: http://lucene.472066.n3.nabble.com/Solr-3-2-0-is-not-writing-log-tp3208945p3214774.html Sent from the Solr - User mailing list archive at Nabble.com.
Solr 3.2.0 is not writing log
I'm using Solr 1.4 with jetty for my site, it writes log into files in example/logs. Now I'm testing Solr 3.2.0 with jetty on another server, but no log is written into this folder: example/logs. It is always empty. Do I need to do something to turn on the log? Any hint will be appreciated. Ruixiang
Index rows with NULL value
Hi It seems that solr does not index a row when some column of this row has NULL value. How can I make solr index these rows? Thanks Ruixiang
Where to find the Log file
Where can I find the log file of solr? Is it turned on by default? (I use Jetty) Thanks Ruixiang
Re: How to upgrade to Solr4.0 to use Result Grouping?
Hi Erick Thanks for your reply. 3.1 should be OK for me. When will it be release and where is the link to download it? Thanks Richard On Mon, Mar 21, 2011 at 7:20 AM, Erick Erickson erickerick...@gmail.comwrote: Get the release and re-index? You can get a trunk version either through SVN or from the nightly build at https://builds.apache.org/hudson/view/S-Z/view/Solr/ Note that 3.1 also has result grouping, and is currently being released, so you might want to consider that version. Best Erick On Sun, Mar 20, 2011 at 9:28 PM, Ruixiang Zhang rxzh...@gmail.com wrote: I want to use the Result Grouping feature that's only available for Solr4.0. Currently, I have Solr1.4.1 installed. I want to know how to upgrade it to Solr4.0 so that I can use Result Grouping? Thanks a lot!!! Richard
Re: How to upgrade to Solr4.0 to use Result Grouping?
Thanks. Then where is the link to download the latest 4.0? Richard On Mon, Mar 21, 2011 at 11:57 AM, Yonik Seeley yo...@lucidimagination.comwrote: On Mon, Mar 21, 2011 at 10:20 AM, Erick Erickson erickerick...@gmail.com wrote: Get the release and re-index? You can get a trunk version either through SVN or from the nightly build at https://builds.apache.org/hudson/view/S-Z/view/Solr/ Note that 3.1 also has result grouping Result grouping / field collapsing is in trunk (4.0-dev) only. -Yonik http://www.lucenerevolution.org -- Lucene/Solr User Conference, May 25-26, San Francisco
Re: How to upgrade to Solr4.0 to use Result Grouping?
Is it the file apache-solr-4.0-2011-03-18_08-07-35-src.tgzhttps://builds.apache.org/hudson/job/Solr-trunk/lastSuccessfulBuild/artifact/artifacts/apache-solr-4.0-2011-03-18_08-07-35-src.tgz on page https://builds.apache.org/hudson/job/Solr-trunk/lastSuccessfulBuild/artifact/artifacts/? Thanks Richard On Mon, Mar 21, 2011 at 12:30 PM, Ruixiang Zhang rxzh...@gmail.com wrote: Thanks. Then where is the link to download the latest 4.0? Richard On Mon, Mar 21, 2011 at 11:57 AM, Yonik Seeley yo...@lucidimagination.com wrote: On Mon, Mar 21, 2011 at 10:20 AM, Erick Erickson erickerick...@gmail.com wrote: Get the release and re-index? You can get a trunk version either through SVN or from the nightly build at https://builds.apache.org/hudson/view/S-Z/view/Solr/ Note that 3.1 also has result grouping Result grouping / field collapsing is in trunk (4.0-dev) only. -Yonik http://www.lucenerevolution.org -- Lucene/Solr User Conference, May 25-26, San Francisco
How to upgrade to Solr4.0 to use Result Grouping?
I want to use the Result Grouping feature that's only available for Solr4.0. Currently, I have Solr1.4.1 installed. I want to know how to upgrade it to Solr4.0 so that I can use Result Grouping? Thanks a lot!!! Richard
Problem of results ordering
When I search guitar center 94305, it gives the results: guitar center guitar center Hollywood guitar center 94305 guitar center 94305 location But I want results to be like this: guitar center 94305 guitar center 94305 location guitar center guitar center Hollywood How can I make the results that match all keywords come first? Or how can I reduce the weight of the word that appears the second or more time? Thanks Ruixiang
Crontab for delta-import
I want to run delta-import in Crontab but don't know how. I used php file in Crontab before, like: command: php /home/user/public_html/auto.php I tried: command: /home/user/public_html/solr/apache-solr-1.4.1/example/example-DIH/solr/db/dataimport?command=delta-import It didn't work. The url I run in browser is: http://181.163.64.228:8983/solr/db/dataimport?command=delta-import Thanks Richard
Re: Crontab for delta-import
Thanks for your quick reply. I couldn't find the wget on my server. Do you know where it should be located or how I can check if I have it on my server? If not, can I install one? Thanks On Wed, Dec 22, 2010 at 3:38 AM, Stefan Moises moi...@shoptimax.de wrote: Hi, you can use wget if available on your server, e.g. command wget --quiet ' http://181.163.64.228:8983/solr/db/dataimport?command=delta-import' Cheers, Stefan Am 22.12.2010 12:31, schrieb Ruixiang Zhang: I want to run delta-import in Crontab but don't know how. I used php file in Crontab before, like: command: php /home/user/public_html/auto.php I tried: command: /home/user/public_html/solr/apache-solr-1.4.1/example/example-DIH/solr/db/dataimport?command=delta-import It didn't work. The url I run in browser is: http://181.163.64.228:8983/solr/db/dataimport?command=delta-import Thanks Richard -- *** Stefan Moises Senior Softwareentwickler shoptimax GmbH Guntherstraße 45 a 90461 Nürnberg Amtsgericht Nürnberg HRB 21703 GF Friedrich Schreieck Tel.: 0911/25566-25 Fax: 0911/25566-29 moi...@shoptimax.de http://www.shoptimax.de ***
Print highlighting descriptions
I want to print the highlighting descriptions: {responseHeader:{status:0, QTime:2,params:{hl.fl:description,json.wrf:jsonp1293069622009,wt:json,q:target,hl:true}},response:{numFound:7945,start:0,maxScore:6.9186745,docs:[{description:target,url:target,id:269653,score:6.9186745},{description:Target The Woodlands,url:Target_The_Woodlands,id:37277,score:4.3241715},{description:Target Kent,url:Target_Kent,id:37275,score:4.3241715}]}, highlighting:{269653:{description:[emtarget/em ]},37277:{description:[emTarget/em The Woodlands]},37275:{description:[emTarget/em Kent]}}} I know the descriptions in docs is: response.response.docs[i].description But I don't know how to print out the highlighting descriptions, such as emTarget/em Kent (No need to highlight, just print out). Thanks Ruixiang
Re: Print highlighting descriptions
Thanks Koji. Actually my question is: We can use response.response.docs[i].description to print the description in docs. What expression should we use to print the description in highlighting?
Re: Print highlighting descriptions
Hi Koji I figured it out. I can use response.highlighting[response.response.docs[0].id].description[0] to print the description in highlighting. (Actually, it's not a solr question, sorry for that.) Thanks Ruixiang On Wed, Dec 22, 2010 at 10:05 PM, Koji Sekiguchi k...@r.email.ne.jp wrote: (10/12/23 14:10), Ruixiang Zhang wrote: Thanks Koji. Actually my question is: We can use response.response.docs[i].description to print the description in docs. What expression should we use to print the description in highlighting? Ruixiang, I cannot understand your question. Is it Solr question? :) You said No need to highlight, just print out in your previous mail, then asked above??? What do you mean by expression and print? Koji -- http://www.rondhuit.com/en/
Dataimport: Could not load driver: com.mysql.jdbc.Driver
*I got the following error for dataimport:* *Full Import failed org.apache.solr.handler.dataimport.DataImportHandlerException: Could not load driver: com.mysql.jdbc.Driver* I have the following files: \example-DIH\solr\db\conf\ solrconfig.xml, schema.xml, db-data-config.xml, dataimport.properties \example-DIH\solr\db\lib\ mysql-connector-java-5.1.13-bin.jar *I put this code to solrconfig.xml:* requestHandler name=/dataimport class=org.apache.solr.handler.dataimport.DataImportHandler lst name=defaults str name=configdb-data-config.xml/str /lst /requestHandler *And these in db-data-config.xml:* ?xml version=1.0 encoding=iso-8859-1? dataConfig dataSource type=JdbcDataSource driver=com.mysql.jdbc.Driver url=jdbc:mysql://localhost/mydata user=myuser password=/ document entity name=id query=select id,title,url from title_copy field column=id name=id / field column=title name=title / field column=url name=url / /entity /document /dataConfig Solr server has been restarted after these change. Any hint or suggestions will be appreciated!!! Thanks Richard
Re: Dataimport: Could not load driver: com.mysql.jdbc.Driver
Thanks Koji. I just tried to change the permission of the driver file to 777, still can not found the driver. I put the driver into the folder with the original driver is and deleted the original one. I don't know why solr can find the original one (if I don't change anything), but not this one. Thanks Richard On Sun, Dec 5, 2010 at 2:46 AM, Koji Sekiguchi k...@r.email.ne.jp wrote: (10/12/05 18:38), Ruixiang Zhang wrote: *I got the following error for dataimport:* *Full Import failed org.apache.solr.handler.dataimport.DataImportHandlerException: Could not load driver: com.mysql.jdbc.Driver* I have the following files: \example-DIH\solr\db\conf\ solrconfig.xml, schema.xml, db-data-config.xml, dataimport.properties \example-DIH\solr\db\lib\ mysql-connector-java-5.1.13-bin.jar I guess the problem is the permission of the driver file? Koji -- http://www.rondhuit.com/en/
Re: Dataimport: Could not load driver: com.mysql.jdbc.Driver
.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:579) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:242) at org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.java:359) ... 34 more Dec 5, 2010 2:00:23 AM org.apache.solr.update.DirectUpdateHandler2 rollback INFO: start rollback Dec 5, 2010 2:00:23 AM org.apache.solr.update.DirectUpdateHandler2 rollback INFO: end_rollback Thanks Richard On Sun, Dec 5, 2010 at 2:56 AM, Ruixiang Zhang rxzh...@gmail.com wrote: Thanks Koji. I just tried to change the permission of the driver file to 777, still can not found the driver. I put the driver into the folder with the original driver is and deleted the original one. I don't know why solr can find the original one (if I don't change anything), but not this one. Thanks Richard On Sun, Dec 5, 2010 at 2:46 AM, Koji Sekiguchi k...@r.email.ne.jp wrote: (10/12/05 18:38), Ruixiang Zhang wrote: *I got the following error for dataimport:* *Full Import failed org.apache.solr.handler.dataimport.DataImportHandlerException: Could not load driver: com.mysql.jdbc.Driver* I have the following files: \example-DIH\solr\db\conf\ solrconfig.xml, schema.xml, db-data-config.xml, dataimport.properties \example-DIH\solr\db\lib\ mysql-connector-java-5.1.13-bin.jar I guess the problem is the permission of the driver file? Koji -- http://www.rondhuit.com/en/
Re: Dataimport: Could not load driver: com.mysql.jdbc.Driver
Hi Koji I finally found the reason for this problem: I download the tar file of the driver and unzip it in windows. Then I put the jar file into the server. I don' t know why, but it doesn't work. It works when I put the tar file and unzip it in the server. Thanks a lot for your time!!! Richard On Sun, Dec 5, 2010 at 3:02 AM, Ruixiang Zhang rxzh...@gmail.com wrote: And here are the logs: Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImportHandler processConfiguration INFO: Processing configuration from solrconfig.xml: {config=db-data-config.xml} Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter loadDataConfig INFO: Data Configuration loaded successfully Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter verifyWithSchema INFO: The field :title present in DataConfig does not have a counterpart in Solr Schema Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter verifyWithSchema INFO: The field :url present in DataConfig does not have a counterpart in Solr Schema Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter doFullImport INFO: Starting Full Import Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.SolrWriter readIndexerProperties INFO: Read dataimport.properties Dec 5, 2010 2:00:23 AM org.apache.solr.handler.dataimport.DataImporter doFullImport SEVERE: Full Import failed *org.apache.solr.handler.dataimport.DataImportHandlerException: Could not load driver: com.mysql.jdbc.Driver* Processing Document # 1 at org.apache.solr.handler.dataimport.DataImportHandlerException.wrapAndThrow(DataImportHandlerException.java:72) at org.apache.solr.handler.dataimport.JdbcDataSource.createConnectionFactory(JdbcDataSource.java:114) at org.apache.solr.handler.dataimport.JdbcDataSource.init(JdbcDataSource.java:62) at org.apache.solr.handler.dataimport.DataImporter.getDataSourceInstance(DataImporter.java:304) at org.apache.solr.handler.dataimport.ContextImpl.getDataSource(ContextImpl.java:94) at org.apache.solr.handler.dataimport.SqlEntityProcessor.init(SqlEntityProcessor.java:52) at org.apache.solr.handler.dataimport.EntityProcessorWrapper.init(EntityProcessorWrapper.java:71) at org.apache.solr.handler.dataimport.DocBuilder.buildDocument(DocBuilder.java:319) at org.apache.solr.handler.dataimport.DocBuilder.doFullDump(DocBuilder.java:242) at org.apache.solr.handler.dataimport.DocBuilder.execute(DocBuilder.java:180) at org.apache.solr.handler.dataimport.DataImporter.doFullImport(DataImporter.java:331) at org.apache.solr.handler.dataimport.DataImporter.runCmd(DataImporter.java:389) at org.apache.solr.handler.dataimport.DataImportHandler.handleRequestBody(DataImportHandler.java:203) at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131) at org.apache.solr.core.SolrCore.execute(SolrCore.java:1316) at org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:338) at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:241) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:285) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:821) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:513) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:208) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378) at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:226) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) *Caused by: java.lang.ClassNotFoundException: Unable to load com.mysql.jdbc.Driver or org.apache.solr.handler.dataimport.com.mysql.jdbc.Driver* at org.apache.solr.handler.dataimport.DocBuilder.loadClass(DocBuilder.java:738
Cannot start Solr anymore
Hi, I'm new here. First, could anyone tell me how to restart solr? I started solr and killed the process. Then when I tried to start it again, it failed: $ java -jar start.jar 2010-12-02 14:28:00.011::INFO: Logging to STDERR via org.mortbay.log.StdErrLog 2010-12-02 14:28:00.099::INFO: jetty-6.1.3 2010-12-02 14:28:00.231::WARN: Failed startup of context org.mortbay.jetty.webapp.webappcont...@73901437 {/solr,jar:file:/.../solr/apache-solr-1.4.1/example/webapps/solr.war!/} java.util.zip.ZipException: invalid END header (bad central directory offset) Thanks Richard
Re: solr/admin/dataimport Not Found
Hi Koji Thanks for your reply. I pasted the wrong link. Actually I tried this fist http://mydomain.com:8983/solr/dataimport It didn't work. The page should be there after installation, right? Did I miss something? Thanks a lot! Richard On Thu, Dec 2, 2010 at 4:23 PM, Koji Sekiguchi k...@r.email.ne.jp wrote: (10/12/03 8:58), Ruixiang Zhang wrote: I tried to import data from mysql. When I tried to run http://mydomain.com:8983/solr/admin/dataimport , I got these error message: HTTP ERROR: 404 NOT_FOUND RequestURI=/solr/admin/dataimport *Powered by Jetty://http://jetty.mortbay.org/ * Any help will be appreciated!!! Thanks Richard Richard, Usually, it should be http://mydomain.com:8983/solr/dataimport Koji -- http://www.rondhuit.com/en/
Re: solr/admin/dataimport Not Found
Thank you so much, Koji, the example-DIH works. I'm reading for details... Richard On Thu, Dec 2, 2010 at 4:39 PM, Koji Sekiguchi k...@r.email.ne.jp wrote: (10/12/03 9:29), Ruixiang Zhang wrote: Hi Koji Thanks for your reply. I pasted the wrong link. Actually I tried this fist http://mydomain.com:8983/solr/dataimport It didn't work. The page should be there after installation, right? Did I miss something? Thanks a lot! Richard To work that URL, you have to have a request handler in your solrconfig.xml: requestHandler name=/dataimport class=org.apache.solr.handler.dataimport.DataImportHandler lst name=defaults str name=configdb-data-config.xml/str /lst /requestHandler If you try DIH for the first time, please read solr/example/example-DIH/README.txt and try example-DIH first. Koji -- http://www.rondhuit.com/en/