• Welcome to the Chevereto user community!

    Here users from all over the world gather around to learn the latest about Chevereto and contribute with ideas to improve the software.

    Please keep in mind:

    • 😌 This community is user driven. Be polite with other users.
    • 👉 Is required to purchase a Chevereto license to participate in this community (doesn't apply to Pre-sales).
    • 💸 Purchase a Pro Subscription to get access to active software support and faster ticket response times.

Increasing number of image table deadlocks

Status
Not open for further replies.

filearmy

Chevereto Member
https://file.army
I'm getting an increasing number of deadlocks on the image table. I have not modified the image table or any SQL that hits the image table. As a result I don't want to try to fix it unless it's clear that this problem occurs permanently out of the box. I was surprised that there are no posts for this yet...ideas?


#4 /home/filearmy/public_html/index.php(20): include_once('/home/filearmy/...')
#5 {main}" while reading response header from upstream, client: 51.15.144.92, server: file.army, request: "GET /i/ELlS5 HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "file.army", referrer: "http://cointurkk.blogspot.fr/2017/01/deneme.html"
2017/01/29 14:42:46 [error] 4359#0: *956252 FastCGI sent in stderr: "PHP message: exception 'CHV\ImageException' with message 'SQLSTATE[40001]: Serialization failure: 1213 Deadlock found when trying to get lock; try restarting transaction' in /home/filearmy/public_html/app/lib/classes/class.image.php:128
Stack trace:
#0 /home/filearmy/public_html/app/routes/route.image.php(49): CHV\Image::getSingle('54283', true, true, NULL)
#1 /home/filearmy/public_html/lib/G/classes/class.handler.php(216): G\Handler->{closure}(Object(G\Handler))
#2 /home/filearmy/public_html/lib/G/classes/class.handler.php(120): G\Handler->processRequest()
#3 /home/filearmy/public_html/app/loader.php(491): G\Handler->__construct(Array)
#4 /home/filearmy/public_html/index.php(20): include_once('/home/filearmy/...')
#5 {main}" while reading response header from upstream, client: 52.37.221.221, server: file.army, request: "GET /i/ELNXE HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "file.army", referrer: "http://cointurkk.blogspot.com.tr/2017/01/deneme.html"
 
I was surprised that there are no posts for this yet...ideas?

I'm not surprised because this doesn't look as an actual issue of the system. The fact that you are the first person to with this issue tells that is mostly likely a local issue.

Also, Chevereto only uses transactions for settings table, nothing else.

You should try checking your innodb settings, maybe you are using a configuration that causes this conflict.
 
Thanks Rodolfo, your product is fantastic. I think the cause is a combination of X+ requests per second for a particular image (on my system it was 8 per second for a single image) and the system performing an update on that row in the same operation.

It seems that in a very high traffic environment it would be good to not update the record in association with the select, but instead to insert the image view event to a new table and run batch updates back to the image table.
 
There are websites using Chevereto with huge traffic, never heard about this deadlocks.
 
Status
Not open for further replies.
Back
Top