Menu

[f1ac8f]: / shell / start.sh  Maximize  Restore  History

Download this file

32 lines (24 with data), 797 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/sh
# Move to the directory containing this script
cd `dirname "$0"`
#
LANG=en_US.UTF-8
export LANG
JAVA_OPTS="$JAVA_OPTS -Dfile.encoding=UTF-8"
# The directory containing the indexes (must be exported)
OPENSEARCHSERVER_DATA=data
export OPENSEARCHSERVER_DATA
# The TCP port used by the server
SERVER_PORT=9090
# Any JAVA option. Often used to allocate more memory. Uncomment this line to allocate 1GB.
#JAVA_OPTS="$JAVA_OPTS -Xms1G -Xmx1G"
# Starting the server
eval java $JAVA_OPTS -jar opensearchserver.jar \
-extractDirectory server \
-httpPort ${SERVER_PORT} \
-Djava.protocol.handler.pkgs=jcifs \
-Doss.externalparser.classpath=lib/ext/* \
-uriEncoding UTF-8 \
>> "logs/oss.log" 2>&1 "&"
# Writing the PID
echo $! > "logs/oss.pid"