2017-02-16, 12:07
Code:
NOTICE: My Music: Scanning for music info using worker thread, operation took 18:57:21
NOTICE: My Music: Scanning for music info using worker thread, operation took 18:57:21
(2017-02-16, 12:07)Rusendusen Wrote:Code:NOTICE: My Music: Scanning for music info using worker thread, operation took 18:57:21
Quote:I am unsure if the memory issue was because of the unplayed song queries grabbing huge amounts of memory and then releasing it (and some kind of fragmentation was happening), or because of some leakage during scanning itself. It would be nice to know this.
Quote:Your vast music collection is a great test resources as long as you have the patience tooSure
Quote:I would have liked to see if we have RPi/LE specific issue of any kind.Yes, a cross test would be good, but honestly no Windows here, only Linux ;(
Quote:As an aside I have just discovered that a smart playlist that includes all songs is 3 times slower to display than the already slow songs node - do not try such a playlist on your huge library!! Something I had never timed, it was a shock. Having fetched and sorted the data (15% of time, 1% is actual DB) the UI waits (interruptably on a different thread) while Kodi does lord knows what - I am investigating. Music playback is uninterrupted..Hmm... I'll see how the DB will perform...
Quote:26089 Query CREATE TEMPORARY TABLE tmp_delartists (idArtist integer) CHARACTER SET utf8 COLLATE utfThe bold line indicates the, from my view, beginning of the problem. After that query there are 4 queries following for each artist, I guess: DELETE FROM album_artist, song_artist, discography, and art. These individual sets of 4 queries for each artist takes from a minute up to multiple hours each :-(
_general_ci
26089 Query INSERT INTO tmp_delartists select idArtist from song_artist
170221 11:11:10 26089 Query INSERT INTO tmp_delartists select idArtist from album_artist
170221 11:11:11 26089 Query INSERT INTO tmp_delartists VALUES(1)
26089 Query delete from artist where idArtist not in (select idArtist from tmp_delartists)
170221 11:11:14 26089 Query DELETE FROM album_artist WHERE album_artist.idArtist = old.idArtist
26089 Query DELETE FROM song_artist WHERE song_artist.idArtist = old.idArtist
26089 Query DELETE FROM discography WHERE discography.idArtist = old.idArtist
26089 Query DELETE FROM art WHERE media_id=old.idArtist AND media_type='artist'
(2017-02-21, 20:39)Rusendusen Wrote: Is your last PR improving the cleanup?Sorry no. :p
(2017-02-21, 21:05)DaveBlake Wrote: Cleaning up a huge db is a whole new can of worms. It is not something I get to test first hand, have to wait for a willing volunteer. I'll take a look tomorrow at what you sent.
Quote:Meanwhile just drop the db and start again if clean isn't. You must be well practiced at that!!