Command Line Tools

mdavis95 edited this page Apr 20, 2014 · 4 revisions

For command line tools to create a cluster see Cluster Tutorial

Get Current Cluster Members

bash indexadmin.sh --command getCurrentMembers

Get Indexes

bash indexadmin.sh --command getIndexes

Get Index Document Count

bash indexadmin.sh --command getCount --index myIndex'

Get Fields Used By an Index

bash indexadmin.sh --command getFields --index myIndex

Clear Index

bash indexadmin.sh --command clearIndex --index myIndex

Delete Index

bash indexadmin.sh --command deleteIndex --index myIndex

Optimize Index (only recommended for content that is not frequently updated)

bash indexadmin.sh --command optimize --index myIndex

Search

Basic Search

bash search.sh --index someIndex --query "title:water" --amount 10

Search without realtime (faster under load, but shows only changes since last commit)

bash search.sh --index someIndex --query "title:water" --amount 10 --realTime false

Fetch Document

bash fetch.sh --uid someUniqueId > myOutput.file

Associated Documents

Store Associated Document (Uses rest interface to allow streaming of large documents)

bash storeassociated.sh --uniqueId someUniqueId --fileName myAssociatedDocumentName
     --fileToStore /tmp/myFileToStore 

Fetch Associated Document (Uses rest interface to allow streaming of large documents)

bash fetchassociated.sh --uniqueId someUniqueId --fileName myAssociatedDocumentName
     --outputFile /home/user/myDocument

Get Terms

Get Terms For Index

bash terms.sh --index myIndex --field title

Get Terms For Index Starting with a Term

bash terms.sh --index myIndex --field title --startTerm yellow

Get Terms For Index With Minimum Document Frequency

bash terms.sh --index myIndex --field title --minDocFreq 10000
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.