SOLR Common Commands Summary

Source: Internet
Author: User
Tags solr

Prerequisites:Installing SOLR Version: 4.8.0 deployment SOLR Path:/data/solr-4.8.01. Upload some configuration information via zookeeper:Upload configuration information to the ZK environment via the ZK command/data/solr-4.8.0/node/scripts/cloud-scripts/zkcli.sh-zkhost solr1-cmd upconfig-confdir/data/ Solr-conf/article_recent-confnamearticle_recentSOLR1: Represents the current host named Solr1, which has a configured, represented server IP address in the/etc/hosts file. /data/solr-conf/article_recent: Represents the path address of the configuration information file you want to uploadArticle_recent: This name represents the configuration file name that you need to create the cluster later2. Create a clusterCurl "http://192.168.11.70:8983/solr/admin/collections?action=create&name=article_201701&Numshards=2&Replicationfactor=2&Maxshardspernode=2&collection.configname=article_recent&Createnodeset=192.168.11.70:8983_SOLR,192.168.11.90:8983_SOLR "3. Deleting a clusterCurl "http://192.168.11.70:8983/solr/admin/collections?action=DELETE&name=article_201701"4. Re-update the clusterCurl "http://192.168.11.70:8983/solr/admin/collections?action=RELOAD&name=article_201701"5. Modify Aliases (alias)Curl "http://192.168.11.70:8983/solr/admin/collections?action=createalias&name=union_article_newest& collections=article_201701,article_201612 "6. Remove aliases (alias)Curl "Http://192.168.11.70:8983/solr/admin/collections?action=DELETEALIAS&name=union_article_newest"7. Increase ReplicaCurl "http://192.168.11.70:8983/solr/admin/collections?action=addreplica&collection=article_201701& SHARD=SHARD2&NODE=192.168.11.130:7574_SOLR "8. Delete ReplicaCurl "http://192.168.11.70:8983/solr/admin/collections?action=deletereplica&collection=article_201701& Shard=shard2&replica=core_node4 "Here the Replica=core_node4 is found from the tree in the/clusterstate.json, as shown in: specific what questions can I leave a message, I will answer them all!

SOLR Common Commands Summary

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.