Please be aware that you can only use these commands if you have terminal access to INDICA.


Split shard:

http://localhost:8983/solr/admin/collections?action=SPLITSHARD&collection=1&shard=shard1&async=1111

http://localhost:8983/solr/admin/collections?action=REQUESTSTATUS&requestid=1111


Sometimes you manually have to set the leader:

http://localhost:8983/solr/admin/collections?action=FORCELEADER&collection=1&shard=shard1


Upgrade index:

cd /net/apache.org/solr/server/solr-webapp/webapp/WEB-INF/lib/

java -cp lucene-core-7.5.0.jar:lucene-backward-codecs-7.5.0.jar org.apache.lucene.index.IndexUpgrader [-delete-prior-commits] [-verbose] /net/index/data/shardBlaBla/data/index/



Manualy edit cluster state: (Mostly after a fuckup)

cd /net/apache.org/solr/server/scripts/cloud-scripts 


./zkcli.sh  -zkhost localhost -cmd getfile /collections/1/state.json /tmp/state.json

Edit /tmp/state.json

You can manually set the active shard after a failed sharding)


./zkcli.sh  -zkhost localhost -cmd putfile /collections/1/state.json /tmp/state.json 



Index corruption

Check

 java -cp lucene-core-7.5.0.jar -ea:org.apache.lucene... org.apache.lucene.index.CheckIndex /net/index/data/1_shard1_replica_n1/data/index/

Fix

java -cp lucene-core-7.5.0.jar -ea:org.apache.lucene... org.apache.lucene.index.CheckIndex /net/index/data/1_shard1_replica1/data/index/ -exorcise


Force optimize in 1 segment

http://localhost:8983/solr/1/update?optimize=true&maxSegments=1&waitFlush=false&async=4111