Last change
on this file since 6082 was
6082,
checked in by Twan Goosen, 9 years ago
|
VLO distribution creates a 'log' directory. Importer start script sets a JVM variable so that log4j knows where to log.
Fixes #741
|
File size:
1.1 KB
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | # Get the script's source directory |
---|
4 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" |
---|
5 | |
---|
6 | # Filter of the Error stream from which to prevent the admins from getting daily |
---|
7 | # "can't find java" emails |
---|
8 | JAVA=`which java 2>/dev/null` |
---|
9 | if [ -z $JAVA ]; then |
---|
10 | #set java for mpi servers |
---|
11 | JAVA=/lat/java/bin/java |
---|
12 | fi |
---|
13 | |
---|
14 | # try to get the configuration file name from the command line options |
---|
15 | if [ 1 -eq $# ]; then |
---|
16 | CONFIG=$1 |
---|
17 | else |
---|
18 | # fall back to default location |
---|
19 | echo No configuration location specified, using default |
---|
20 | CONFIG=${DIR}/"../config/VloConfig.xml" |
---|
21 | fi |
---|
22 | |
---|
23 | LOGDIR=${DIR}/../log/ |
---|
24 | echo Logging in ${LOGDIR} |
---|
25 | |
---|
26 | # Please specify the configuration to the importer via a system property or via |
---|
27 | # the command line. In case of a property add |
---|
28 | # |
---|
29 | # -DconfigFile=<pathToConfigFile> |
---|
30 | # |
---|
31 | # and in case of the command line, add |
---|
32 | # |
---|
33 | # -c <pathToConfigFile> |
---|
34 | # |
---|
35 | # to the JAVA command. Please note the a specification on the command line will |
---|
36 | # take preference over a specification as a property. |
---|
37 | |
---|
38 | $JAVA -Xmx2024M \ |
---|
39 | -cp "${DIR}:${DIR}/vlo-importer-3.2-SNAPSHOT-importer.jar" \ |
---|
40 | -DIMPORTER_LOG_DIR=${LOGDIR} \ |
---|
41 | eu.clarin.cmdi.vlo.importer.MetadataImporter -c "$CONFIG" |
---|
42 | |
---|
Note: See
TracBrowser
for help on using the repository browser.