View Issue Details

IDProjectCategoryView StatusLast Update
0018818MMW 5DB / Backuppublic2022-04-24 20:47
ReporterLudek Assigned To 
PriorityurgentSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Version5.0 
Target Version5.0.3Fixed in Version5.0.3 
Summary0018818: Add SQLite's INI switch for paging to memory
DescriptionIn previous MM4 versions we used this SQLite's config:
PRAGMA temp_store = MEMORY;
which forces all the DB to be paged to RAM, but with this paged to memory e.g. VACUUM fails ( see 0016432 ) with "out of memory" exception on large databases (7 GB, 2.2 million of tracks).

We disabled this PRAGMA in MM5 with a note that there should not be a negative impact on performance (just where the pages are written with default page size 2048000 bytes), but we haven't tested DB on a NAS.

In the ticket # 3615 it was found that having MM5.DB stored in a NAS location is very slow when deleting tracks, most probably because a lot of network traffic is needed when writing/reading DB and it is slower.

With this in mind we may want to add INI switch to re-enable paging to memory to reduce the network penalty when DN is stored on NAS.
Additional Informationhttps://www.mediamonkey.com/forum/viewtopic.php?t=101193
TagsNo tags attached.
Fixed in build2607

Relationships

related to 0016432 closedLudek Optimize database (complete) fails on databases larger than 4 GB 
related to 0018894 closedLudek Removing large number of tracks from DB is slow when DB is located on NAS 

Activities

Ludek

2022-02-07 13:17

developer   ~0066873

Added switch

[SYSTEM]
SQLitePageToMemory=0;

changing it to 1 enables paging to memory (like in MM4).

Ludek

2022-02-07 13:23

developer   ~0066874

Added the switch in 2607

@Peke please update corresponding docs.

peke

2022-03-05 02:15

developer   ~0067209

Verified switch functionality 2610

@Rusty
I have not found any KB article that optimize DB access speed and https://www.mediamonkey.com/support/knowledge-base/mediamonkey-install-config/modifying-the-mediamonkey-db-and-ini-files/ do not cover that case.

New KB article needs to be created to explain how and what this switch do in order to improve DB Behavior, but that sudden loss of access to DB can (but unlikely) result in corruption eg. Removing External hdd from PC or permanent loss of WiFi/Wired connection.

Test note: Tested on WiFi reconnect or switching from Wired to WiFi and it does not result in corruption, but UI gets frozen for 1-2 seconds till New IP/Connection is confirmed,

NOTE: I also tested when MM Portable is started from USB2.0 HDD where large number Randon HDD read/write IOPS is low this switch can increase speed by 30%

rusty

2022-03-09 18:19

administrator   ~0067221

Based on the comments above, I've updated: https://www.mediamonkey.com/support/knowledge-base/mediamonkey-install-config/mediamonkey-in-a-shared-networked-environment/

peke

2022-04-24 20:47

developer   ~0067727

Re Verified 2616

Closing