Solr Error (Search API):
The datasource with ID 'elstut--entity:node' could not be retrieved for index 'myindex123'
Solr Error (Search API):
The datasource with ID 'elstut--entity:node' could not be retrieved for index 'myindex123'
Error:
Drupal\search_api_solr\SearchApiSolrException while maintaining Solr server Solr Server: Solr endpoint http://localhost:8983/ internal Solr server error (code: 500, body: { "error":{ "msg":"Document contains at least one immense term in field=\"exacttext\" (whose UTF8 encoding is longer than the max length 32766),
Shell script :
#!/bin/bash
cd /var/www/vhosts/example.com/httpdocs
drush="php -c /var/www/vhosts/example.com/httpdocs/drush.ini /var/www/vhosts/example.com/httpdocs/vendor/drush/drush/drush"
$drush sapi-c
$drush sapi-i --batch-size=500
$drush ws
$drush status
drush.ini:
safe_mode =
open_basedir =
max_execution_time = 3600
max_file_uploads = 20
max_input_time = 3600
memory_limit = 8G
Cronjob (++)
Um Apache Solr zu installieren bzw. zu aktualisieren (Update/Upgrade) :
wget https://dlcdn.apache.org/lucene/solr/8.11.1/solr-8.11.1.tgz
tar xzf solr-8.11.1.tgz solr-8.11.1/bin/install_solr_service.sh --strip-components=2
./install_solr_service.sh solr-8.11.1.tgz -f
/etc/init.d/solr restart
service solr restart
Um die Sicherheitslücke für Apache Solr 8.x zu schließen:
export LOG4J_FORMAT_MSG_NO_LOOKUPS=true
Alte Dateien (in /opt/solr/server/lib/ext)
log4j-1.2-api-2.14.1.jar
log4j-api-2.14.1.jar
log4j-core-2.14.1.jar
log4j-slf4j-impl-2.14.1.jar
log4j-web-2.14.1.jar
ersetzen durch neue Dateien:
Alle Verbindungen, die nicht aus dem IP 127.0.0.1 kommen, werden ignoriert (Reihenfolge ist wichtig).
iptables -A INPUT -p tcp -s localhost --dport 8983 -j ACCEPT
iptables -A INPUT -p tcp --dport 8983 -j DROP
service solr status
https://lucene.apache.org/solr/guide/8_5/taking-solr-to-production.html
*** [WARN] *** Your open file limit is currently 1024. It should be set to 65000 to avoid operational disruption.
If you no longer wish to see this warning, set SOLR_ULIMIT_CHECKS to false in your profile or solr.in.sh
Error: Solr requires java, please install or set JAVA_HOME properly
Was ist die Lösung?
Solarium 5.0.2 is too old and has known issues. In order to get composer to upgrade solarium to a recent version a core patch or a workaround is required. Have a look at this Core issue and this Search API Solr issue.