Kodi Community Forum
Transfer old storage location to new storage loc. / MySql import - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111)
+---- Forum: OS independent / Other (https://forum.kodi.tv/forumdisplay.php?fid=228)
+---- Thread: Transfer old storage location to new storage loc. / MySql import (/showthread.php?tid=373439)



Transfer old storage location to new storage loc. / MySql import - dsl55dsl - 2023-06-10

Hello Guys,

I am trying to move my media sources from my old NAS to my new NAS and I noticed that if I import the new source it simply doubles my scraped data. How do I simply make Kodi know that the data is exactly the same and it keeps track what I watched? 

My other question is how to I import my Kodi Database to a mysql DB so that I could free up space on my nVidia Shield. 

Thank you,


RE: Transfer old storage location to new storage loc. / MySql import - Klojum - 2023-06-10

(2023-06-10, 15:28)dsl55dsl Wrote: and I noticed that if I import the new source it simply doubles my scraped data.
Yep, works as advertised... Kodi stores the full path of each of your videos into the video database. It does not automagically insert new entries in previous locations. So different file locations result into different video database entries.

(2023-06-10, 15:28)dsl55dsl Wrote: How do I simply make Kodi know that the data is exactly the same and it keeps track what I watched? 
You now probably have a bit messed up video library with entries from both/two source locations.
Running the "Clean Library" action should clean up most old entries.

A couple of add-ons/tools have options to replace paths in the video library. Doing such actions manually is possible and could be done quickly, but requires knowledge of SQL query language.

(2023-06-10, 15:28)dsl55dsl Wrote: My other question is how to I import my Kodi Database to a mysql DB so that I could free up space on my nVidia Shield. 
The size of the video database is not your problem when running off an Nvidia Shield.
The biggest storage swallower by far is the Kodi's thumbnails cache.


RE: Transfer old storage location to new storage loc. / MySql import - dsl55dsl - 2023-06-11

I searched all over the boards and cant seem to find a best practice to add a new location for my source video files. 

My goal is just to have my viewed files imported so I dont have to think about if I watched episode 2 of Season 3 of Law and Order. 

Any help would be fantastic. 

Thank you,


RE: Transfer old storage location to new storage loc. / MySql import - scott967 - 2023-06-12

It sounds like what you can do is export your existing video library to separate files.  Depending on how you manage artwork (mainly if you curate your own local art or just let Kodi pull a scraped url image to thumbnail cache) you could also export the art.  Then delete the source and tell Kodi to remove the source items from the library.  Then add your new source set the content as appropriate and update the library.  In the past (prior to Kodi v 20/Nexus) you needed an advanced setting to get resume points so you might create/ edit advancedsettings.xml
xml:

<videolibrary>
    <importwatchedstate>true</importwatchedstate> <!-- import previously exported playdate and playcount from .nfo files. Defaults to false -->
    <importresumepoint>true</importresumepoint> <!-- import previously exported resume point from .nfo files. Defaults to false -->
</videolibrary>

Again, since Kodi 20 default is now true.

scott s.
.