简体   繁体   中英

How to run SOLR on amazon ec2 instance?

I am able to successfully start SOLR on windows by using following command:

solr-5.2.1/bin/solr.cmd start -p 9393 -s eposro/solr

This doesn't work on amazon linux. I get following errors.

@echo: command not found
solr-5.2.1/bin/solr.cmd: line 19: IF: command not found
solr-5.2.1/bin/solr.cmd: line 21: REM: command not found
solr-5.2.1/bin/solr.cmd: line 42: IF: command not found
solr-5.2.1/bin/solr.cmd: line 75: IF: command not found
solr-5.2.1/bin/solr.cmd: line 76: syntax error near unexpected token `('
solr-5.2.1/bin/solr.cmd: line 76: `IF NOT EXIST "%JAVA_HOME%\bin\java.exe" ('

Java_HOME has been set as follows:

echo $JAVA_HOME /usr/java/jdk1.8.0_101/

Is there a different way to run SOLR on amazon linux or am I doing anthing wrong?

Navigate to solr directory & make sure solr home path you are starting with is correct. enter bin/solr start -p 9393 -s esposro/solr try updating Java version if you dont have latest.

And also check the port number(9393) you using with Amazon EC2 to start solr is enabled with firewall.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM