mirror of https://github.com/apache/lucene.git
SOLR-7349: Update cloud-dev scripts for Jetty 9.
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1676546 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
736a9b6934
commit
1a7cf2fc85
|
@ -34,14 +34,14 @@ start() {
|
||||||
|
|
||||||
setports $1
|
setports $1
|
||||||
cd ../server$1
|
cd ../server$1
|
||||||
java $JAVA_OPTS -Djetty.port=$PORT $OPT -DSTOP.PORT=$STOP_PORT -DSTOP.KEY=key -jar start.jar 1>server$1.log 2>&1 &
|
java $JAVA_OPTS -Djetty.port=$PORT $OPT -jar start.jar --module=http STOP.PORT=$STOP_PORT STOP.KEY=key jetty.base=. 1>server$1.log 2>&1 &
|
||||||
}
|
}
|
||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
echo "Stopping instance $1"
|
echo "Stopping instance $1"
|
||||||
setports $1
|
setports $1
|
||||||
cd ../server$1
|
cd ../server$1
|
||||||
java -DSTOP.PORT=$STOP_PORT -DSTOP.KEY=key -jar start.jar --stop
|
java -jar start.jar --module=http STOP.PORT=$STOP_PORT STOP.KEY=key --stop
|
||||||
}
|
}
|
||||||
|
|
||||||
do_kill() {
|
do_kill() {
|
||||||
|
|
|
@ -1,47 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# TODO: !OUT OF DATE!
|
|
||||||
|
|
||||||
zkaddress = localhost:2181/solr
|
|
||||||
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
rm -r -f server2
|
|
||||||
rm -r -f server3
|
|
||||||
rm -r -f server4
|
|
||||||
rm -r -f server5
|
|
||||||
rm -r -f server6
|
|
||||||
|
|
||||||
rm -r -f dist
|
|
||||||
rm -r -f build
|
|
||||||
rm -r -f server/solr/zoo_data
|
|
||||||
rm -r -f server/solr/collection1/data
|
|
||||||
rm -f server/server.log
|
|
||||||
|
|
||||||
ant server dist
|
|
||||||
|
|
||||||
cp -r -f server server2
|
|
||||||
cp -r -f server server3
|
|
||||||
cp -r -f server server4
|
|
||||||
cp -r -f server server5
|
|
||||||
cp -r -f server server6
|
|
||||||
|
|
||||||
java -classpath "server/solr-webapp/webapp/WEB-INF/lib/*:server/lib/ext/" org.apache.solr.cloud.ZkController "$zkaddress" 8983 server/solr/conf conf1
|
|
||||||
|
|
||||||
cd server
|
|
||||||
java -DzkHost="$zkaddress" -DnumShards=2 -DSTOP.PORT=7983 -DSTOP.KEY=key -jar start.jar 1>server.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server2
|
|
||||||
java -Djetty.port=7574 -DzkHost="$zkaddress" -DSTOP.PORT=6574 -DSTOP.KEY=key -jar start.jar 1>server2.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server3
|
|
||||||
java -Djetty.port=7575 -DzkHost="$zkaddress" -DSTOP.PORT=6575 -DSTOP.KEY=key -jar start.jar 1>server3.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server4
|
|
||||||
java -Djetty.port=7576 -DzkHost="$zkaddress" -DSTOP.PORT=6576 -DSTOP.KEY=key -jar start.jar 1>server4.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server5
|
|
||||||
java -Djetty.port=7577 -DzkHost="$zkaddress" -DSTOP.PORT=6577 -DSTOP.KEY=key -jar start.jar 1>server5.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server6
|
|
||||||
java -Djetty.port=7578 -DzkHost="$zkaddress" -DSTOP.PORT=6578 -DSTOP.KEY=key -jar start.jar 1>server6.log 2>&1 &
|
|
|
@ -1,47 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# TODO: !OUT OF DATE!
|
|
||||||
|
|
||||||
# starts up the multicore example
|
|
||||||
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
rm -r -f server2
|
|
||||||
rm -r -f server3
|
|
||||||
rm -r -f server4
|
|
||||||
rm -r -f server5
|
|
||||||
rm -r -f server6
|
|
||||||
|
|
||||||
rm -r -f dist
|
|
||||||
rm -r -f build
|
|
||||||
rm -r -f server/solr/zoo_data
|
|
||||||
rm -r -f server/solr/collection1/data
|
|
||||||
rm -f server/server.log
|
|
||||||
|
|
||||||
ant server dist
|
|
||||||
|
|
||||||
cp -r -f server server2
|
|
||||||
cp -r -f server server3
|
|
||||||
cp -r -f server server4
|
|
||||||
cp -r -f server server5
|
|
||||||
cp -r -f server server6
|
|
||||||
|
|
||||||
java -classpath "server/solr-webapp/webapp/WEB-INF/lib/*:server/lib/ext/" org.apache.solr.cloud.ZkCLI -cmd upconf -zkhost 127.0.0.1:9983 -solrhome example/multicore -runzk 8983
|
|
||||||
|
|
||||||
cd server
|
|
||||||
java -DzkRun -DnumShards=2 -DSTOP.PORT=7983 -DSTOP.KEY=key -Dsolr.solr.home=../example/multicore -jar start.jar 1>server.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server2
|
|
||||||
java -Djetty.port=7574 -DzkHost=localhost:9983 -DnumShards=2 -DSTOP.PORT=6574 -DSTOP.KEY=key -Dsolr.solr.home=multicore -jar start.jar 1>server2.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server3
|
|
||||||
java -Djetty.port=7575 -DzkHost=localhost:9983 -DnumShards=2 -DSTOP.PORT=6575 -DSTOP.KEY=key -Dsolr.solr.home=multicore -jar start.jar 1>server3.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server4
|
|
||||||
java -Djetty.port=7576 -DzkHost=localhost:9983 -DnumShards=2 -DSTOP.PORT=6576 -DSTOP.KEY=key -Dsolr.solr.home=multicore -jar start.jar 1>server4.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server5
|
|
||||||
java -Djetty.port=7577 -DzkHost=localhost:9983 -DnumShards=2 -DSTOP.PORT=6577 -DSTOP.KEY=key -Dsolr.solr.home=multicore -jar start.jar 1>server5.log 2>&1 &
|
|
||||||
|
|
||||||
cd ../server6
|
|
||||||
java -Djetty.port=7578 -DzkHost=localhost:9983 -DnumShards=2 -DSTOP.PORT=6578 -DSTOP.KEY=key -Dsolr.solr.home=multicore -jar start.jar 1>server6.log 2>&1 &
|
|
|
@ -20,7 +20,7 @@ cd ..
|
||||||
cd serverzk
|
cd serverzk
|
||||||
stopPort=1313
|
stopPort=1313
|
||||||
jettyPort=8900
|
jettyPort=8900
|
||||||
exec -a jettyzk java -Xmx512m $JAVA_OPTS -Djetty.port=$jettyPort -DhostPort=$jettyPort -DzkRun -DzkHost=localhost:9900/$ZK_CHROOT -DzkRunOnly=true -DSTOP.PORT=$stopPort -DSTOP.KEY=key -jar start.jar 1>serverzk.log 2>&1 &
|
exec -a jettyzk java -Xmx512m $JAVA_OPTS -Djetty.port=$jettyPort -DhostPort=$jettyPort -DzkRun -DzkHost=localhost:9900/$ZK_CHROOT -DzkRunOnly=true -jar start.jar --module=http STOP.PORT=$stopPort STOP.KEY=key jetty.base=. 1>serverzk.log 2>&1 &
|
||||||
|
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
|
@ -32,5 +32,5 @@ do
|
||||||
cd ../server$i
|
cd ../server$i
|
||||||
stopPort=`expr $baseStopPort + $i`
|
stopPort=`expr $baseStopPort + $i`
|
||||||
jettyPort=`expr $baseJettyPort + $i`
|
jettyPort=`expr $baseJettyPort + $i`
|
||||||
exec -a jetty java -Xmx1g $JAVA_OPTS -Djetty.port=$jettyPort -DzkHost=localhost:9900/$ZK_CHROOT -DSTOP.PORT=$stopPort -DSTOP.KEY=key -jar start.jar 1>server$i.log 2>&1 &
|
exec -a jetty java -Xmx1g $JAVA_OPTS -Djetty.port=$jettyPort -DzkHost=localhost:9900/$ZK_CHROOT -jar start.jar --module=http STOP.PORT=$stopPort STOP.KEY=key jetty.base=. 1>server$i.log 2>&1 &
|
||||||
done
|
done
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
# These scripts are best effort developer scripts. No promises.
|
||||||
|
|
||||||
# To run on hdfs, try something along the lines of:
|
# To run on hdfs, try something along the lines of:
|
||||||
# export JAVA_OPTS="-Dsolr.directoryFactory=solr.HdfsDirectoryFactory -Dsolr.lock.type=hdfs -Dsolr.hdfs.home=hdfs://localhost:8020/solr -Dsolr.hdfs.confdir=/etc/hadoop_conf/conf"
|
# export JAVA_OPTS="-Dsolr.directoryFactory=solr.HdfsDirectoryFactory -Dsolr.lock.type=hdfs -Dsolr.hdfs.home=hdfs://localhost:8020/solr -Dsolr.hdfs.confdir=/etc/hadoop_conf/conf"
|
||||||
|
|
||||||
|
@ -35,8 +37,8 @@ rm -r -f build
|
||||||
rm -r -f server/solr/zoo_data
|
rm -r -f server/solr/zoo_data
|
||||||
rm -f server/server.log
|
rm -f server/server.log
|
||||||
|
|
||||||
ant -f ../build.xml clean
|
#ant -f ../build.xml clean
|
||||||
ant server dist
|
#ant server dist
|
||||||
|
|
||||||
rm -r server/solr-webapp/*
|
rm -r server/solr-webapp/*
|
||||||
unzip server/webapps/solr.war -d server/solr-webapp/webapp
|
unzip server/webapps/solr.war -d server/solr-webapp/webapp
|
||||||
|
@ -54,7 +56,7 @@ rm -r -f serverzk/solr/collection1/core.properties
|
||||||
cd serverzk
|
cd serverzk
|
||||||
stopPort=1313
|
stopPort=1313
|
||||||
jettyPort=8900
|
jettyPort=8900
|
||||||
exec -a jettyzk java -Xmx512m $JAVA_OPTS -Djetty.port=$jettyPort -DhostPort=$jettyPort -DzkRun=localhost:9900/solr -DzkHost=$zkAddress -DzkRunOnly=true -DSTOP.PORT=$stopPort -DSTOP.KEY=key -jar start.jar 1>serverzk.log 2>&1 &
|
exec -a jettyzk java -Xmx512m $JAVA_OPTS -Djetty.port=$jettyPort -DhostPort=$jettyPort -DzkRun=localhost:9900/solr -DzkHost=$zkAddress -DzkRunOnly=true -jar start.jar --module=http STOP.PORT=$stopPort STOP.KEY=key jetty.base=. 1>serverzk.log 2>&1 &
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
# upload config files
|
# upload config files
|
||||||
|
@ -68,5 +70,5 @@ do
|
||||||
cd ../server$i
|
cd ../server$i
|
||||||
stopPort=`expr $baseStopPort + $i`
|
stopPort=`expr $baseStopPort + $i`
|
||||||
jettyPort=`expr $baseJettyPort + $i`
|
jettyPort=`expr $baseJettyPort + $i`
|
||||||
exec -a jetty java -Xmx1g $JAVA_OPTS -DnumShards=$numShards -Djetty.port=$jettyPort -DzkHost=$zkAddress -DSTOP.PORT=$stopPort -DSTOP.KEY=key -jar start.jar 1>server$i.log 2>&1 &
|
exec -a jetty java -Xmx1g $JAVA_OPTS -DnumShards=$numShards -Djetty.port=$jettyPort -DzkHost=$zkAddress -jar start.jar --module=http STOP.PORT=$stopPort STOP.KEY=key jetty.base=. 1>server$i.log 2>&1 &
|
||||||
done
|
done
|
||||||
|
|
|
@ -18,7 +18,7 @@ do
|
||||||
stopPort=`expr $baseStopPort + $i`
|
stopPort=`expr $baseStopPort + $i`
|
||||||
echo "stopping server$i, stop port is $stopPort"
|
echo "stopping server$i, stop port is $stopPort"
|
||||||
cd ../server$i
|
cd ../server$i
|
||||||
java -DSTOP.PORT=$stopPort -DSTOP.KEY=key -jar start.jar --stop
|
java -jar start.jar --module=http STOP.PORT=$stopPort STOP.KEY=key --stop
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
|
@ -46,7 +46,7 @@ do
|
||||||
done
|
done
|
||||||
|
|
||||||
# stop zk runner
|
# stop zk runner
|
||||||
java -DSTOP.PORT=1313 -DSTOP.KEY=key -jar start.jar --stop
|
java -jar start.jar --module=http STOP.PORT=1313 STOP.KEY=key --stop
|
||||||
|
|
||||||
echo "wait for port to be available: $baseJettyPort"
|
echo "wait for port to be available: $baseJettyPort"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue