Posts: 17,855
Joined: Jan 2011
Reputation:
1,056
Milhouse
Retired Team-Kodi Member
Posts: 17,855
2015-03-05, 05:00
(This post was last modified: 2015-03-05, 05:14 by Milhouse.)
Then your systems are broken, and you should fix them.
Use "texturecache.py jd sets" to view the Movie Sets artwork urls on each of your clients, and - if your clients are all using the same videodb schema - you'll see the urls are all the same on each client. If the urls are different on some or all clients then those clients are not using the same MySQL server or schema you think they are, and you need to fix that.
Assuming the urls are correct on your clients, if any client is not displaying the correct images in the GUI then that is most likely a caching issue rather than a media library issue (try "texturecache.py C sets" on such clients).
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Posts: 627
Joined: Dec 2011
Reputation:
12
Are you using same Kodi/XBMC version?! It's important when sharig MySQL Shared library.
Posts: 1
Joined: Mar 2015
Reputation:
0
Hi,
I've written this script to manager my kodi thumbnails and it does exactly what I want. I hope it will do what you want also.
Brian.
#!/usr/bin/python
# filename: flush.py
# As a safeguard stop kodi before use.
import sqlite3
import sys
import os
# Set up home directory
home = os.getenv("HOME")
count = 0
# Connect sqlite3 to database
try:
conn = sqlite3.connect(home + '/.kodi/userdata/Database/Textures13.db')
choice = conn.execute("SELECT DISTINCT url from texture") # get distinct entries from database
for row in choice: # as a guide to which to flush
print row[0]
category = raw_input("Please select a keyword from above list for which category to flush >>> ")
cursor = conn.execute("SELECT id, url, cachedurl, imagehash, lasthashcheck from texture")
# read database
for row in cursor: # loop through all entries in database
target = row[1] # get url as target
if category in target: # test if target contains our category
record = row[0] # yes, get record id number
print "Deleting record no.", record
conn.execute("DELETE from texture where id=?",(record,)) # delete this entry
conn.commit() # commit change
file = home + '/.kodi/userdata/Thumbnails/' + row[2] # get cachedurl filename
if os.path.exists(file): # make sure it exists
print "Removing file ", file
os.remove(file) # remove file
count += 1 # count how many thumbnails have been removed
print "Number of thumbnails removed ", count
# Failed to open database, report error
except sqlite3.Error as e:
print "Error %s:" % e.args[0]
sys.exit(1)
# That's all folks
finally:
if conn:
conn.close()
Posts: 7,135
Joined: Oct 2012
un1versal
Out of Memory (1939–2016)
Posts: 7,135
@
Milhouse, that freeze on scan initiated via script is completely fixed... Neither freeze nor stutter nor blocking input of anything during video playback (smooth like butter)... Just as it should, in fact you cant tell at all anything is going on.. Perfect, , say thx to Sasha for me
fantastic fix and quick too. Cheers bud.
Posts: 90
Joined: Feb 2014
Reputation:
2
Milhouse, i've been running your script remotely lately and noticed a huge lag. Just a simple texturecache.py C movies "whatever" takes about 3.5 minutes to complete. Running the same command locally through SSH only takes about 30 +/- seconds. I'm just curious if this is expected behavior. This is on a Pi, so maybe it has to do with being underpowered. Any thoughts?
Posts: 17,855
Joined: Jan 2011
Reputation:
1,056
Milhouse
Retired Team-Kodi Member
Posts: 17,855
@garderd4me: Upload texturecache.py logfiles (one for local, one for remote) as that would indicate where the delay is occurring. Check your Pi is not running out of memory, although this is much less likely to happen when using the script remotely, so the behaviour you're seeing is a bit odd. Maybe your network is having problems.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.