I've installed Drupal 6.11 into my development environment, this site will be replacing another site that we currently have hosted on PostNuke. I've written some modules that import the data from the PostNuke Database into my own custom CCK nodes and they show up fine. The reason i mention this is that the only nodes i have on the site are these custom CCK nodes. Not sure if that makes a difference or not.

I installed ApacheSolr (Nightly 05-05-2009) according to the instructions in the ReadMe.TXT and have a Solr Instance up and running. On the ApacheSolr Search index page (/admin/settings/apachesolr/index) its reads like this.

The search index is generated by running cron. 0% of the site content has been sent to the server. There are 1015 items left to send.

No matter how many times I run cron, it never seems to update the index.

I have made sure i've copied the schema.xml and solrconfig.xml over to the right directory in Solr.
I'm running PHP 5.2.0 and have also applied the CoreSearches patch.

Not sure what i'm doing wrong here. Any help would be appreciated.

Comments

pwolanin’s picture

Check watchdog for errors. Also, not sure about the core searches patch - though I think it's fine.

nathangervais’s picture

Watchdog has no errors or warning regarding Search or Solr. I think i'll try a fresh install today and see where that gets me.

janusman’s picture

Also, check admin/reports/status in your site; there should be a line for "Apache Solr" telling you if it can contact your Solr instance.

nathangervais’s picture

Apache Solr Your site has contacted the Apache Solr server.

* Host: localhost
* Port: 8983
* Path: /solr

I can connect fine to http://localhost:8983/solr/admin/, and it shows me the admin panel and its telling me im using drupal-0.9.2. Im assuming this version comes from the schema.xml and/or solrconfig.xml that i overwrote.

pwolanin’s picture

Hmm, silly question, but do you ahve the Apache Solr search module enabled as well as the framework module? The framework module does not itself index any content. It' only provides the framework for indexing content.

nathangervais’s picture

I have the following modules enabled

Apache Solr framework
Apache Solr more like this
Apache Solr node access
Apache Solr search

And the following disabled (not enabled)
Apache Solr image module integration
Apache Solr Organic Groups

pwolanin’s picture

ok, well if there are no error messages in your Drpal logs, double check that Solr has write access to the index directory and other basics.

You can also use the CLI tools that come with Solr or curl to directly add some content to Solr.

nathangervais’s picture

My test environment is Windows so i dont think write access is an issue.

May 6, 2009 2:05:37 PM org.apache.solr.core.SolrCore execute
INFO: [] webapp=/solr path=/admin/luke params={numTerms=0&wt=json} status=0 QTim
e=15

This is what i see in the console of Solr when i run cron. Does this provide you with any information?

Also should i try going back to using Solr 1.3.0 /w a previous build of the ApacheSolr module and see if that will work?

pwolanin’s picture

Version: 6.x-1.0-beta9 » 6.x-1.x-dev

Solr 1.3.0 won't work - see above suggestions - try to index some content using provided CLI tools in the Solr package.

nathangervais’s picture

Version: 6.x-1.x-dev » 6.x-1.0-beta9

i ran java -jar post.jar *.xml and it posted some data to Solr. I can now see that there is data in the Solr Index.

From what i can gleam it looks like my cron job is never actually sending anything to Solr for it to index. Another thing i've noticed is that the drupal core search isnt being indexed either. I'll see what i can figure out from here.

Thanks for your help so far.

nathangervais’s picture

Status: Active » Closed (works as designed)

Interesting, once all the data on the site was indexed by core search i started to see the data being indexed by Solr. Did i miss this in the documentation somewhere?

Todd Young’s picture

Just to confirm, I think so - I found the same to be true. Once my "regular" search caught up, Solr kicked in normally.

roCKeshwar’s picture

same problem subscribing... any help is appreciated.... thanks

Itsu’s picture

Same problem. Did anyone found a solution for this?

Every time I add a Story node, I get 3 new items in Indexing status (where it says XX% of the site has been indexed. There are YY items left to index.) After cron, only 2 of those elements are removed from the "items left" number. Could not figure out which content is indexed, but I could not find the node content in solr index (I checked solr admin GUI for that).

I think that I started to have this problem after patching with multiple_node_access.patch - but I'm not sure.

I'm using similar configuration (php 5.2, apache solr integration with node access)

penyaskito’s picture

Same problem here, subscribing.

penyaskito’s picture

Status: Closed (works as designed) » Active
pwolanin’s picture

Status: Active » Closed (works as designed)
penyaskito’s picture

My problem was solved by fixing cron. Cron was not being executed correctly.
Remember to check your dblog if you have this same problem.

leanazulyoro’s picture

I'm having this same issue, apachesolr's index is not updating, I have the regular search index disabled (set to index 0 items on cron). I haven't yet tried what #11 suggested because I have a lot of nodes, I'll try it on a new drupal install later. Nevertheless that is not the desired behavior.

oknate’s picture

pressing "queue all content for reindexing" moved things along.

rs3876’s picture

Issue summary: View changes

I have the same issue as described in description AND
I am getting following notice/error in watchdog table.

select wid,variables,location from watchdog order by wid DESC limit 0,2;

| wid | variables | location |
+--------+-----------------------------------------------------------------------------------------------------------------------
| 111670 | a:5:{s:5:"%type";s:6:"Notice";s:8:"%message";s:27:"Undefined index: base theme";s:9:"%function";s:25:"system_find_base_themes()";s:5:"%file";s:55:"/var/www/web/noc/drupal/modules/system/system.module";s:5:"%line";i:977;} | http://localhost/admin/settings/apachesolr/index |
| 111669 | a:5:{s:5:"%type";s:6:"Notice";s:8:"%message";s:28:"Undefined index: description";s:9:"%function";s:20:"theme_taskbar_item()";s:5:"%file";s:87:"/var/www/web/noc/drupal/sites/all/modules/contrib/taskbar/includes/taskbar.theme.inc";s:5:"%line";i:46;} | http://localhost/admin/settings/apachesolr/index |

rs3876’s picture

Never mind. Cron was not setup properly.