Memory issue, interesting. There are other team members looking at a Kodi memory use issue, so is it OK to post your debug log link here incase so more eyes can check it? I don't think there is anything too private in there, but obviously your choice.
If you had a crash do you have a crash log too? Although I rarely seem to get any useful info from them someone else might.
The log only shows ~1 hour of use, was that from the last crash or did you truncate the log to paste?
Quote:I had kodi hanging some times and after restart, I see mem usage in system-info screen go up rapidly until kodi hangs.
Was this always connected with scanning music into the lib? On restart what Kodi screen was on display, or what actions had you taken?
For the db errors in the log
Running MySQL version 5.5.54-0ubuntu0.14.04.1
Error 1205 is "Lock wait timeout exceeded"
Error is logged at 08:31:32.326 after Mysql execute: delete from path... at 08:30:41.808, that is 50.518s later. This makes sense as the default value for innodb_lock_wait_timeout is 50 seconds. But I guess the question is why was the delete of a record taking more than 50s? Was the server busy doing something else (playback of a video perhaps) or temp locked my something? Is that reasonable, and so should the timeout be set to longer on your MySQL server?
The next timeout is at 08:32:24.336 on an insert attempted at 08:31:33.602, (50.734s delay) interrupted by an EPG scan. The subsequent timeout errors all seem to have PVR/EPG tasks, or skin widget data requests happening at a similar time.
My intital suggestion is that you increase the
innodb_lock_wait_timeout on your MySQL server, say to 60s at least.
Unfortunately MySQL timeout errors by default do not rollback transactions.This means that there will be music that is incompletely added e.g. have the song entry but not the album genre. I am uncertain how much a library update will be able to fix this, it will depend on what action timed out. So it probably means dropping the music source and starting again just to be sure, but I would test out some scanning first to ensure the timeout errors are gone.
EDIT: It also could be worth starting the server with the --innodb_rollback_on_timeout option so that timeouts do rollback transactions.
At the end of this may well be a "best pratice" guide on setting up Kodi on MySQL server.
Regarding your music collection.
I know you have a lot of music files, and I can see from the log that some previously scanned into the library OK. Can we get some numbers on how many of your files are in the library so far. Either look at the (very very slow) songs node, or look inside the MySQL database directly and check the total number of records in the song table. Also how many music files were on the music source(s)?
Have you added multiple music sources, splitting your collection into chunks, or just one that contains everything?
So that leaves the memory use. Maybe it was related to the db errors in some way, but I don't see why that would be the case. Probably need to exclude it by getting scanning working without MySQL timeout, and then see if you still get memory use problem.