How to Install Traccar server on AWS Amazon step by step (Tutorial)

Anton Tananaev7 years ago

Port 8082 is ONLY for web interface. Port 5055 is for Traccar Client, so you need it if you want to use Traccar Client app.

johns7 years ago

Hello, I have this message in log file, and I do not see any device. What I could do?, in the traccart port check the port 5005 is open. I test with android application
Thank you

2017-07-21 19:11:03  INFO: Operating system name: Linux version: 3.10.0-514.26.2.el7.x86_64 architecture: amd64
2017-07-21 19:11:03  INFO: Java runtime name: OpenJDK 64-Bit Server VM vendor: Oracle Corporation version: 25.141-b16
2017-07-21 19:11:03  INFO: Memory limit heap: 444mb non-heap: 0mb
2017-07-21 19:11:03  INFO: Character encoding: UTF-8 charset: UTF-8
2017-07-21 19:11:03  INFO: Version: 3.12-SNAPSHOT
2017-07-21 19:11:13  INFO: Starting server...
2017-07-21 19:11:58  INFO: [1C7FFC45] connected
2017-07-21 19:11:58 DEBUG: [1C7FFC45: 5001 < 194.168.1.1] HEX: 474554202f3f69643d3132333435362674696d657374616d703d31353030363830333336266c61743d342e363533363230266c6f6e3d2d37342e3035393637372673706565643d302662656172696e673d3026616c7469747564653d323538342e343226626174743d31303020485454502f312e310d0a486f73743a203139302e302e362e37303a353035350d0a4163636570743a202a2f2a0d0a4163636570742d4c616e67756167653a2065732d65730d0a436f6e6e656374696f6e3a206b6565702d616c6976650d0a4163636570742d456e636f64696e673a20677a69702c206465666c6174650d0a557365722d4167656e743a2054726163636172436c69656e742f34322043464e6574776f726b2f3831312e352e342044617277696e2f31362e362e300d0a0d0a
2017-07-21 19:12:21  INFO: [09881D88] connected
2017-07-21 19:12:21 DEBUG: [09881D88: 5001 < 194.168.1.1] HEX: 474554202f3f69643d3132333435362674696d657374616d703d31353030363830333336266c61743d342e363533363230266c6f6e3d2d37342e3035393637372673706565643d302662656172696e673d3026616c7469747564653d323538342e343226626174743d31303020485454502f312e310d0a486f73743a203139302e302e362e37303a353035350d0a4163636570743a202a2f2a0d0a4163636570742d4c616e67756167653a2065732d65730d0a436f6e6e656374696f6e3a206b6565702d616c6976650d0a4163636570742d456e636f64696e673a20677a69702c206465666c6174650d0a557365722d4167656e743a2054726163636172436c69656e742f34322043464e6574776f726b2f3831312e352e342044617277696e2f31362e362e300d0a0d0a
2017-07-21 19:12:58  INFO: [1C7FFC45] disconnected
2017-07-21 19:13:22  INFO: [09881D88] disconnected
2017-07-21 19:13:45  INFO: [E742AA8C] connected
2017-07-21 19:13:45 DEBUG: [E742AA8C: 5001 < 194.168.1.1] HEX: 474554202f3f69643d3132333435362674696d657374616d703d31353030363830333336266c61743d342e363533363230266c6f6e3d2d37342e3035393637372673706565643d302662656172696e673d3026616c7469747564653d323538342e343226626174743d31303020485454502f312e310d0a486f73743a203139302e302e362e37303a353035350d0a4163636570743a202a2f2a0d0a4163636570742d4c616e67756167653a2065732d65730d0a436f6e6e656374696f6e3a206b6565702d616c6976650d0a4163636570742d456e636f64696e673a20677a69702c206465666c6174650d0a557365722d4167656e743a2054726163636172436c69656e742f34322043464e6574776f726b2f3831312e352e342044617277696e2f31362e362e300d0a0d0a
2017-07-21 19:14:45  INFO: [E742AA8C] disconnected
2017-07-21 19:15:17  INFO: [B0BB6333] connected
2017-07-21 19:15:17 DEBUG: [B0BB6333: 5001 < 194.168.1.1] HEX: 474554202f3f69643d3132333435362674696d657374616d703d31353030363830333336266c61743d342e363533363230266c6f6e3d2d37342e3035393637372673706565643d302662656172696e673d3026616c7469747564653d323538342e343226626174743d31303020485454502f312e310d0a486f73743a203139302e302e362e37303a353035350d0a4163636570743a202a2f2a0d0a4163636570742d4c616e67756167653a2065732d65730d0a436f6e6e656374696f6e3a206b6565702d616c6976650d0a4163636570742d456e636f64696e673a20677a69702c206465666c6174650d0a557365722d4167656e743a2054726163636172436c69656e742f34322043464e6574776f726b2f3831312e352e342044617277696e2f31362e362e300d0a0d0a
2017-07-21 19:16:17  INFO: [B0BB6333] disconnected
Anton Tananaev7 years ago

I'm confused. You mention port 5005, then you actually use port 5001, but what you should be using for Traccar Client app is port 5055. Also, log indicates that you are using iOS device, not Android.

johns7 years ago

My aplogies, you are right, I verify also the port 5055 is open and is a IOS device. Thanks

johns7 years ago

Hello, finally traccar works, I can access to traccar with publicIP:8082, however I want access to my web page how www.mysite.com and traccar with traccar.mysite.com, how I configure virtual host in apache? Thank you

Anton Tananaev7 years ago

You can configure it using proxy:

https://www.traccar.org/secure-connection/

johns7 years ago

Hello, I follow the instructions, however I have the message: 503 Service Unavailable. Thank you

Anton Tananaev7 years ago

If Traccar port works directly, then there must be some proxy configuration issue.

johns7 years ago

Hello, your example of secure connection works for proxy apache, I realized that in Centos is necesary disabled SELinux on /etc/sysconfig/selinux. Thank you for your help

Juan Montoya7 years ago

For my Ubuntu AWS version Ubuntu 16.04 I did this and the traccar version 3.13

# sudo su  
# apt - get update
# wget https://github.com/tananaev/traccar/releases/download/v3.13/traccar-linux-3.13.zip
#unzip traccar-linux-3.13.zip
#sudo ./traccar.run
#apt-get install mysql-server phpmyadmin unzip  (here you configure your database passwords)
#vi /opt/traccar/conf/linux.cfg
<entry key="database.driver"> com.mysql.jdbc.Driver</entry>
<entry key="database.datasource"> com.MySQL.JDBC.jdbc2.optional.MysqlDataSource</entry>
<entry key="database.url"> jdbc:mysql://localhost/anyusername allowMultiqueries = true & autoreconnect =</entry>
<entry key='database.user'> anyusername</entry>
<entry key='database.password'> youphpmyadminpassword</entry>}
ESC
:wq
ENTER
sudo /opt/traccar/bin/startDaemon.sh

to stop my Traccar:

sudo /opt/traccar/bin/stopDaemon.sh

Looks that is working fine.

Sunny 6 years ago

I am using Ubuntu 16
After unzip file then below command gives error
#sudo ./traccar.run

error is command not found.

Anton Tananaev6 years ago

Which command is not found?

Sunny 6 years ago

#sudo ./traccar.run

Anton Tananaev6 years ago

Yes, but is it "sudo" or "./traccar.run"?

Sunny 6 years ago

rybash: ./traccar.run: No such file or directory