Please never duplicate your questions between multiple threads.
Sorry Anton about it.
Can you please let me know a solution for the above problem.
Try this<entry key='database.driver'>com.mysql.cj.jdbc.Driver</entry>
Dear all,
Any help please, I installed openGTS and I want to integrate traccar in it, I had already installed and I configured the traccar.xml file as you can show here:
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE properties SYSTEM 'http://java.sun.com/dtd/properties.dtd'>
<properties>
<entry key='config.default'>./conf/traccar.xml</entry>
<entry key='web.enable'>false</entry>
<entry key='web.port'>8082</entry>
<entry key='web.path'>/opt/traccar/web</entry>
<entry key='geocoder.enable'>true</entry>
<entry key='geocoder.type'>google</entry>
<entry key='decoder.ignoreSessionCache'>true</entry>
<entry key='processing.computedAttributes.enable'>true</entry>
<entry key='logger.enable'>true</entry>
<entry key='logger.level'>all</entry>
<entry key='logger.file'>/opt/traccar/logs/tracker-server.log</entry>
<entry key='database.driver'>com.mysql.cj.jdbc.Driver</entry>
<entry key='database.url'>jdbc:mysql://MY-ADRESSE-IP:5027/gts?allowMultiQueries=true</entry>
<entry key='database.user'>gts</entry>
<entry key='database.password'>opengts</entry>
<entry key='database.selectDevices'>
SELECT CONCAT('1', imeiNumber) AS id, imeiNumber AS uniqueId FROM Device WHERE imeiNumber REGEXP '^[0-9]+$';
</entry>
<entry key='database.selectAllDevices'>
SELECT CONCAT('1', imeiNumber) AS id, imeiNumber AS uniqueId FROM Device WHERE imeiNumber REGEXP '^[0-9]+$';
</entry>
<entry key='database.insertPosition'>
START TRANSACTION;
UPDATE Device SET lastValidLatitude = :latitude, lastValidLongitude = :longitude, lastGPSTimestamp = UNIX_TIMESTAMP(:fixTime), lastUpdateTime = UNIX_TIMESTAMP(NOW()) WHERE imeiNumber = SUBSTRING(CAST(:deviceId AS CHAR(32)), 2);
SELECT @accountID := accountID, @deviceID := deviceID FROM Device WHERE imeiNumber = SUBSTRING(CAST(:deviceId AS CHAR(32)), 2);
INSERT INTO EventData (accountID, deviceID, timestamp, statusCode, latitude, longitude, speedKPH, heading, altitude, rawData, creationTime, address)
VALUES (@accountID, @deviceID, UNIX_TIMESTAMP(:fixTime), 0, :latitude, :longitude, :speed * 1.852, :course, :altitude, '', UNIX_TIMESTAMP(NOW()), :address);
COMMIT;
</entry>
</properties>
When I restart the traccar server and look at the tracker-server.log I got error message as follow:
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
2021-06-21 07:14:27 DEBUG: HikariPool-1 - Cannot acquire connection from data source - Connection refused (Connection refused) - ConnectException (... < DataManager:126 < *:85 < Context:290 < Main:120 < ...)
2021-06-21 07:14:28 ERROR: HikariPool-1 - Exception during pool initialization. - Connection refused (Connection refused) - ConnectException (... < DataManager:126 < *:85 < Context:290 < Main:120 < ...)
2021-06-21 07:14:28 ERROR: Main method error - Connection refused (Connection refused) - ConnectException (... < DataManager:126 < *:85 < Context:290 < Main:120 < ...)
Any Help Please !!
Your issue doesn't seem to be related to this topic.
Hi People ,
I really require an advice asap, my traccar service is running, but when i'm trying to run the localhost:8082 it says refused to connect.
This was not happening before, it just started to happen now.
I recently modified the traccar.xml file with my SQL configurations.
<entry key='database.driver'>com.mysql.jdbc.Driver</entry> <entry key='database.url'>jdbc:mysql://localhost:3306/traccar?serverTimezone=UTC&useSSL=false&allowMultiQueries=true&autoReconnect=true&useUnicode=yes&characterEncoding=UTF-8&sessionVariables=sql_mode=''</entry> <entry key='database.user'>root</entry> <entry key='database.password'>Omarzoha2014.</entry>
Over here "traccar" is the name of the database I created in the connection test which has the user root and password Omarzoha2014.
My log file shows:
Does anybody know what could be the reason for the refused connection ?
Urgent help required.