Solved Shared MySQL - Update library from another client results in duplicates
#1
I've had a shared library running on a central server for a long time now, but I've always manually updated the library from a single client(1).  That clients gong to be removed from the network, so now looking to update library from the others but this results in duplicate entries (stop the update as soon as I see this).  Followed the guide section 5 here, additionally copying over the these files "sources.xml", "mediasources.xml" as well as the "advancedsettings" (which was already on the other clients), but problem remains.  Welcome any ideas on how to solve this. Thanks in advance.

System:
Client 1 - Acer Revo RL80 (LibraElec - Kodi 18.6)
Client 2 - Firestick 4k (Kodi 18.6)
Client 3 - Firestick 4k (Kodi 18.6)

SQL dbs - Hosted on server (192.168.0.63)
Content - Hosted on server (192.168.0.63 or //OMV)

Advanced settings file added into userdata on all clients:-
Quote:<advancedsettings>
  <videodatabase>
    <type>mysql</type>
    <host>192.168.0.63</host>
    <port>3306</port>
    <user>****</user>
    <pass>****</pass>
  </videodatabase> 
  <musicdatabase>
    <type>mysql</type>
    <host>192.168.0.63</host>
    <port>3306</port>
    <user>****</user>
    <pass>****</pass>
  </musicdatabase>
  <videolibrary>
    <importwatchedstate>true</importwatchedstate>
    <importresumepoint>true</importresumepoint>
  </videolibrary>
</advancedsettings>
 

mediasources.xml  (Not sure why I used IP address in once case but hostname in another, but its always worked ok)
Quote:<mediasources>
    <network>
        <location id="0">smb://192.168.0.63/Movies</location>
        <location id="1">smb://omv/TV</location>
    </network>
</mediasources>

sources.xml
Quote:<sources>
    <programs>
        <default pathversion="1"></default>
    </programs>
    <video>
        <default pathversion="1"></default>
        <source>
            <name>Movies</name>
            <path pathversion="1">smb://192.168.0.63/Movies/</path>
            <allowsharing>true</allowsharing>
        </source>
        <source>
            <name>TV</name>
            <path pathversion="1">smb://omv/TV/</path>
            <allowsharing>true</allowsharing>
        </source>
    </video>
    <music>
        <default pathversion="1"></default>
    </music>
    <pictures>
        <default pathversion="1"></default>
    </pictures>
    <files>
        <default pathversion="1"></default>
    </files>
    <games>
        <default pathversion="1"></default>
    </games>
</sources>
Reply
#2
"Duplicate" entries always have a difference one way or the other. An extra forward slash, a space char...
Try comparing the full paths of a couple of your duplicates, I'm sure there is something off between them.
Got a Kodi problem? Provide us with a full Debug log (wiki) || Usefull pages: First time user (wiki) || Troubleshooting (wiki) || Free content (wiki) || Forum rules (wiki) || VPN policy (wiki)
Reply
#3
(2020-05-19, 10:57)Klojum Wrote: "Duplicate" entries always have a difference one way or the other. An extra forward slash, a space char...
Try comparing the full paths of a couple of your duplicates, I'm sure there is something off between them.

Sorry what do you mean compare the full paths, you mean of the entries in SQL dbs?  Not sure how to do this.  Given the identical source path's are being used on all machines (as I'm copying over the xml rather than adding the sources manually) surely this shouldnt be an issue :-)
Reply
#4
(2020-05-19, 11:27)johnyb Wrote: you mean of the entries in SQL dbs?  Not sure how to do this.

Database entries would be nice... Smile

But you can start by opening the information page of the videos, and highlight the last 'tab' button (which is Refresh in Estuary), and the full path of the video should appear.
Image
Got a Kodi problem? Provide us with a full Debug log (wiki) || Usefull pages: First time user (wiki) || Troubleshooting (wiki) || Free content (wiki) || Forum rules (wiki) || VPN policy (wiki)
Reply
#5
(2020-05-19, 15:41)Klojum Wrote:
(2020-05-19, 11:27)johnyb Wrote: you mean of the entries in SQL dbs?  Not sure how to do this.

Database entries would be nice... Smile

But you can start by opening the information page of the videos, and highlight the last 'tab' button (which is Refresh in Estuary), and the full path of the video should appear.
Image 
Thanks for this.  So I checked and the duplicate entries had 'smb://omv/Movies/x'  whereas the existing one had 'smb://192.168.0.63/Movies/x' 
But I couldn't for the life of me figure out why, because the source for movies was configured as 'smb://192.168.0.63/Movies'.  Where is it getting this path from?


Anyway, decided to tidy this up a bit.  So exported the library (single files), created a new SQL instance (easy as on docker), used the SMB://omv/x for both TV & Movies this time.
Scanning for files picked up all the content, and now after copying the master  "sources.xml", "mediasources.xml", "advancedsettings" files to the other client its working fine.
(Only point worth noting is the TV scrapper plug in isnt installed by default to need to add this first).

Thanks for your help.
Reply
#6
Thread marked solved.
Got a Kodi problem? Provide us with a full Debug log (wiki) || Usefull pages: First time user (wiki) || Troubleshooting (wiki) || Free content (wiki) || Forum rules (wiki) || VPN policy (wiki)
Reply
 
Thread Rating:
  • 0 Vote(s) - 0 Average



Logout Mark Read Team Forum Stats Members Help
Shared MySQL - Update library from another client results in duplicates00
This forum uses Lukasz Tkacz MyBB addons.