help me! I can not start startdaemon.sh

hello,

someone could give me the steps to be able to repair this error. thank you very much.

root@vps [/]# sudo ./opt/traccar/bin/startDaemon.sh
++++++++++ YAJSW SET ENV ++++++++++
./opt/traccar/bin/setenv.sh: line 44: java: command not found
wrapper home : /opt/traccar
configuration: /opt/traccar/conf/wrapper.conf
./opt/traccar/bin/setenv.sh: line 56: java: command not found
---------- YAJSW SET ENV ----------
++++++++++ YAJSW SET ENV ++++++++++
/opt/traccar/bin/setenv.sh: line 44: java: command not found
wrapper home : /opt/traccar
configuration: /opt/traccar/conf/wrapper.conf
/opt/traccar/bin/setenv.sh: line 56: java: command not found
---------- YAJSW SET ENV ----------
/opt/traccar/bin/wrapper.sh: line 7: java: command not found
Anton Tananaev6 years ago

You are missing Java or Java is misconfigured.

root@vps [/opt]# java -version
java version "1.7.0_67"
Java(TM) SE Runtime Environment (build 1.7.0_67-b01)
Java HotSpot(TM) 64-Bit Server VM (build 24.65-b04, mixed mode)

how can I set java to traccar

Anton Tananaev6 years ago

You need to install Java properly so it's available on the path for all users. Remember that Traccar runs as a system service. It's not the same environment as your shell.

in which directory must be installed jdk?

Anton Tananaev6 years ago

Just install it using package manager.

I have linux centos

Anton Tananaev6 years ago

This is how you install Java on CentOS:

sudo yum install java-1.7.0-openjdk

I'm not sure what directories you are talking about.

Thank you very kind and expert!.