Issue in setting up Tarccae Server

singhal.vipin77 years ago

Hey,
I am trying to setup Traccar server on ubuntu 16.04
So I did ran the following command -

sudo ./traccar.run

It setup everything. Then i ran the following command -

sudo /opt/traccar/bin/startDaemon.sh

Again, everything seems to be setup fine.
Below are the logs :

++++++++++ YAJSW SET ENV ++++++++++
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)
wrapper home : /opt/traccar
configuration: /opt/traccar/conf/wrapper.conf
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)
---------- YAJSW SET ENV ----------
++++++++++ YAJSW SET ENV ++++++++++
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)
wrapper home : /opt/traccar
configuration: /opt/traccar/conf/wrapper.conf
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)
---------- YAJSW SET ENV ----------
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/glazedlists-1.8.0_java15.jar
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/commons-beanutils-1.8.2.jar
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/commons-beanutils-1.8.2.jar
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/glazedlists-1.8.0_java15.jar
YAJSW: yajsw-stable-12.09
OS   : Linux/4.4.0-1020-aws/amd64
JVM  : Oracle Corporation/1.8.0_131//usr/lib/jvm/java-8-oracle/jre/64
Jul 30, 2017 12:00:49 PM org.apache.commons.vfs2.VfsLog info
INFO: Using "/tmp/vfs_cache" as temporary files store.
Jul 30, 2017 12:00:49 PM org.rzo.yajsw.os.posix.PosixService init
INFO: /etc/init.d/traccar already exists
************* STARTING traccar ***********************

Jul 30, 2017 12:00:49 PM org.rzo.yajsw.os.posix.PosixService getPid
INFO: wrapper pid file: /run/wrapper.traccar.pid
Jul 30, 2017 12:00:53 PM org.rzo.yajsw.os.posix.PosixService start
INFO: Starting traccar ...
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/glazedlists-1.8.0_java15.jar
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/commons-beanutils-1.8.2.jar
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/commons-beanutils-1.8.2.jar
INFO: lib not found: /opt/traccar/lib/extended/glazedlists/glazedlists-1.8.0_java15.jar
YAJSW: yajsw-stable-12.09
OS   : Linux/4.4.0-1020-aws/amd64
JVM  : Oracle Corporation/1.8.0_131//usr/lib/jvm/java-8-oracle/jre/64
************* STARTING traccar ***********************

Service traccar started

Jul 30, 2017 12:00:53 PM org.rzo.yajsw.os.posix.PosixService getPid
INFO: wrapper pid file: /run/wrapper.traccar.pid
Jul 30, 2017 12:00:54 PM org.rzo.yajsw.os.posix.PosixService getPid
INFO: wrapper pid file: /run/wrapper.traccar.pid
Jul 30, 2017 12:00:54 PM org.rzo.yajsw.os.posix.PosixService getPid
INFO: wrapper pid file: /run/wrapper.traccar.pid

Service traccar started

It also say that the service is started.

But when I ping the IP of my server, it opens up nothin. I am unalbe to view the tracking dashboard and anything else.
Please let me know what am I missing here and how to get things working ?

Thanks

Anton Tananaev7 years ago

First thing you should do before asking for help is to check log files for errors and warnings.

singhal.vipin77 years ago

Here are the logs from the traccar-server.log file. Everything seems fine to me -

2017-07-30 12:00:54  INFO: Operating system name: Linux version: 4.4.0-1020-aws architecture: amd64
2017-07-30 12:00:54  INFO: Java runtime name: Java HotSpot(TM) 64-Bit Server VM vendor: Oracle Corporation version: 25.131-b11
2017-07-30 12:00:54  INFO: Memory limit heap: 239mb non-heap: 0mb
2017-07-30 12:00:54  INFO: Character encoding: UTF-8 charset: UTF-8
2017-07-30 12:00:54  INFO: Version: 3.12-SNAPSHOT
2017-07-30 12:01:00  INFO: Starting server...

It says server started successfully.

What's the minimum configuration of server required to run the traccar server ?
I am running it on EC2 t2.micro. Would that be a problem ?

Anton Tananaev7 years ago

EC2 t2.micro should be enough for a small number of devices.

You should check wrapper log file as well.

singhal.vipin77 years ago

Here's my wrapper log file logs -

FINEST|16756/0|Service traccar|17-07-30 12:00:59|INFO 7/30/17 12:00 PM: liquibase: ./schema/changelog-master.xml: changelog-3.12::changelog-3.12-notmssql::author: ChangeSet changelog-3.12::changelog-3.12-notmssql::author ran successfully in 2ms
FINEST|16756/0|Service traccar|17-07-30 12:00:59|INFO 7/30/17 12:00 PM: liquibase: ./schema/changelog-master.xml: changelog-3.12::changelog-3.12-pgsql::author: Marking ChangeSet: changelog-3.12::changelog-3.12-pgsql::author ran despite precondition failure due to onFail='MARK_RAN': 
FINEST|16756/0|Service traccar|17-07-30 12:00:59|          ./schema/changelog-master.xml : DBMS Precondition failed: expected postgresql, got h2
FINEST|16756/0|Service traccar|17-07-30 12:00:59|
FINEST|16756/0|Service traccar|17-07-30 12:00:59|INFO 7/30/17 12:00 PM: liquibase: Successfully released change log lock
FINEST|16756/0|Service traccar|17-07-30 12:00:59|[main] INFO org.eclipse.jetty.util.log - Logging initialized @6742ms
FINEST|16756/0|Service traccar|17-07-30 12:01:00|[main] INFO org.eclipse.jetty.server.Server - jetty-9.2.22.v20170606
FINEST|16756/0|Service traccar|17-07-30 12:01:02|[main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@1e3df614{/api,null,AVAILABLE}
FINEST|16756/0|Service traccar|17-07-30 12:01:02|[main] INFO org.eclipse.jetty.server.ServerConnector - Started ServerConnector@558e383f{HTTP/1.1}{0.0.0.0:8082}
FINEST|16756/0|Service traccar|17-07-30 12:01:02|[main] INFO org.eclipse.jetty.server.Server - Started @9380ms

Looks working normal to me.
This is my IP address - http://52.10.20.133/
and this loads the default apache page

Anton Tananaev7 years ago

Traccar uses port 8082 by default for the web interface. Your log file looks fine, so you should be able to access the web app.

singhal.vipin77 years ago

Yes, i am able to access it on the 8082 port. Thanks.
And apologies for the trivial issue, should have figured that out myself. Thanks :)

Vipin Jakhar7 years ago

Hi singhal ,
I am facing same issue .Can you tell me how you fixed it?

singhal.vipin77 years ago

@Vipin Jakhar : Have you completed the setup on your server ? If yes, you can acces the web portal at <<YOUR_IP>>:8082
If there's anything else, please send in more details.

Vipin Jakhar7 years ago

Ok,
Yes i have completed all setup as
http://35.197.159.98 running apache
http://35.197.159.98/phpmyadmin

http://35.197.159.98:8082/ enable to access

Vipin Jakhar7 years ago
----@vjakhar:/opt/traccar# java -jar tracker-server.jar conf/traccar.xml
[main] INFO com.zaxxer.hikari.HikariDataSource - HikariPool-1 - Starting...
[main] INFO com.zaxxer.hikari.HikariDataSource - HikariPool-1 - Start completed.
INFO 11/9/17 4:58 AM: liquibase: Clearing database change log checksums
INFO 11/9/17 4:58 AM: liquibase: Successfully acquired change log lock
INFO 11/9/17 4:58 AM: liquibase: Successfully released change log lock
INFO 11/9/17 4:58 AM: liquibase: Successfully acquired change log lock
INFO 11/9/17 4:58 AM: liquibase: Reading from PUBLIC.DATABASECHANGELOG
INFO 11/9/17 4:58 AM: liquibase: Reading from PUBLIC.DATABASECHANGELOG
INFO 11/9/17 4:58 AM: liquibase: ./schema/changelog-master.xml: changelog-3.8::changelog-3.8-dropuniquetoken::author: Change set changelog-3.8::changelog-3.8-dropuniquetoken::author failed, but failOnError was false.  Error: Constraint "UK_USER_TOKEN" not found; SQL statement:
ALTER TABLE PUBLIC.users DROP CONSTRAINT uk_user_token [90057-196] [Failed SQL: ALTER TABLE PUBLIC.users DROP CONSTRAINT uk_user_token]
INFO 11/9/17 4:58 AM: liquibase: Successfully released change log lock
[main] INFO org.eclipse.jetty.util.log - Logging initialized @6121ms
[main] INFO org.eclipse.jetty.server.Server - jetty-9.2.22.v20170606
[main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@61ab89b0{/api,null,AVAILABLE}
[main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started o.t.w.@521bb1a4{/,null,AVAILABLE}
[main] INFO org.eclipse.jetty.server.ServerConnector - Started ServerConnector@208b9c30{HTTP/1.1}{0.0.0.0:8082}
[main] INFO org.eclipse.jetty.server.Server - Started @9953ms

showing this .....

:/opt/traccar# java -version
java version "1.8.0_151"
Java(TM) SE Runtime Environment (build 1.8.0_151-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.151-b12, mixed mode)

Please suggest me where i have been missing

Anton Tananaev7 years ago

Your server is running. There is no problem.

Vipin Jakhar7 years ago

Yes, server is running but i m unable to access at port :8082
http://35.198.238.130:8082
How i fix this plz suggest

Anton Tananaev7 years ago

Probably firewall or router issue.

Vipin Jakhar7 years ago

But i have checked using
https://help.ubuntu.com/lts/serverguide/firewall.html
and allow port no 8082 also