could not login in the web interface

zmitya10 years ago

Hi Gents,

After one day I could not login to the web interface. The server runs and it recorded the positions properly (as far as I could see from the DB)

Here is my log:

http://pastebin.com/raw.php?i=YcBBJt9B

After I restarted the server I could login and I can see the trip properly..

Thanks,
Mitya

Anton Tananaev10 years ago

It looks like you have a problem with database connection. What database are you using?

zmitya10 years ago

I am using a MySQL from Debian (Wheezy) package. Theoretically the DB server ran well during the day. It is strange because I could not login to the web interface, but ther tracker server logged down my trip properly.

Here is my config:

http://pastebin.com/raw.php?i=sLaYP24T

Note 1:
Please note that I removed all the unnecessary protocols from the config.. I hope that this is not a problem...

Could this issue this ?

Note 2:
http://stackoverflow.com/questions/9201574/hibernate-couldnt-reconnect-to-mysql-after-connection-closed-by-timeout

I have only one GPS device, and it sits in my garage at the moment ,so it does not send position data in the whole day..

Thanks.
Mitya

Anton Tananaev10 years ago
  1. Removing protocol is definitely not a problem.

  2. I was going to suggest autoReconnect=true, but you already have it. Usually it helps. Have you restarted the service after adding it?

zmitya10 years ago

no, it was always there ..
I meant: from the beggining, this is how I started traccar at the very first time. ..

zmitya10 years ago

do you have a kind of keepalive select or something similar ? to avoid the timeout ? or should I increase the timeout ?

Anton Tananaev10 years ago

There is no keepalive, but c3p0 library should automatically check connections periodically. Try to increase MySQL timeout.

zmitya10 years ago

Ok, I did it. I also increased the loglevel in the MySQL server to see whether it closes any connection because of timeout. We will see.

Other question (if possible in this thread):
do you have performance informations of traccar somewhere ?

Lets say all the devices use gt06 protocol. How many req/sec could be serverd ?

thanks in advance,
Mitya

Anton Tananaev10 years ago

I haven't done load testing, but I know some people use Traccar (only device communication back-end) with 10k+ devices.

zmitya10 years ago

great, that sounds pretty impressive ;)
if I can convince my partner to use your stuff, we will not forget about the donation.

thanks for this great stuff and keep up with this HQ work!

zmitya10 years ago

Hi Anton,

Let me continue this thread please, because this morning we could not login again. This time I did not see any MySQL connection errors, but this:

http://pastebin.com/ijQFyVX7

I the other side the tracker-server logged down the requests properly, however it logged down this message for long time:

2015-06-03 17:07:55 INFO: device: 6, time: Thu Jun 04 01:07:53 CEST 2015, lat: 47.xxxxxxxxx, lon: 19.xxxxxxx
2015-06-03 17:07:55 WARN: Cannot add or update a child row: a foreign key constraint fails (traccar.positions, CONSTRAINT FK65C08C6ADB0C3B8A FOREIGN KEY (device_id) REFERENCES devices (id)) - co
m.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException (null:-1)

This could happen because we deleted this device. It seems that the cache clearing does not work dor some reason, because after few hours the server still knew about the device 6 id.

Additionally after 23:30 the server stopped responding and 23:47 the server stopped logging and storing positions :(

After a restart everything worked again properly. Do you how this could happen ? Is there any known bug related to this ?

How can I help you to figure out these issues ? I really like your project, it would be nice to go over these issues..

Thanks,
Mitya

Anton Tananaev10 years ago

I found one problem with database sessions clean-up. It will be fixed in the next version of Traccar.