Support Questions
Find answers, ask questions, and share your expertise

Ranger solr script missing

Super Guru

According to Ranger Solr install guide the script


Should be available for execution. This file does not exist. Where can I find this shell script to

create my solr collection?


Accepted Solutions

Super Collaborator

Super Collaborator

Super Collaborator

Any luck with that @Sunile Manjee? It must have been moved from the install guide you are looking at. These instructions ^^^^ create a template and once you follow the instructions will create the script.

Super Collaborator

Hi @Sunile Manjee. That's weird. I just followed those instructions and it worked and all was there. I think you may have been looking at different instructions. It says to work with this directory: /usr/local/solr_for_audit_setup. Did your steps start with this?

wget -O /usr/local/solr_for_audit_setup_v3.tgz

cd /usr/local
tar xvf solr_for_audit_setup_v3.tgz

cd /usr/local/solr_for_audit_setup

After editing the file, you run ./ and then execute this: /opt/solr/ranger_audit_server/scripts/

That just uploads the config set to Zookeeper.

The Create script you were looking for should be this one (not in the path you originally looked at): /opt/solr/ranger_audit_server/scripts/

Here is all that it does.

curl --negotiate -u : "${SOLR_HOST_URL}/solr/admin/collections?action=CREATE&name=${COLLECTION_NAME}&numShards=${SHARDS}&replicationFactor=${REPLICATION}&collection.configName=$CONF_NAME&maxShardsPerNode=100"

Super Guru

@james.jones I have done this twice during new cluster setup and both times the script does not exist in location you have identified. It is good to know what the script is doing which is a acceptable work around.

Super Collaborator

Really weird, but I'm glad you got it worked out. Cheers

Super Guru

@james.jones I followed those instructions during install and the script does not exist. Not sure why and if this is a bug. Eitherway I manually created a solr colleciton for the audit. Not sure what else the script did.