2016-01-10, 23:21
I'm stumped on this, even after looking at several pages of a search in this forum about MySql and came back without answers, I'm beginning to think that something is broke.
Details:
New Raspbery Pi 2, 8GB microsd, 16GB thumb drive 2.5 power supply
Installed with latest OSMC & Kodi (all updates applied)
MySql is installed on a separate system and is in use for several databases by other systems on my local network.
I've been using Raspberry Pis' (1s and 2s) XMBC and Kodi for a long time.
Movie and TV files (about 4.5 TB) are on 16TB FreeNAS in a single NFS share in 4 directories below the share.
The share is tested and I can see it from all systems on my local network and can access the share on the Pi after creating a "Network Location" and then creating a source for each of the 4 sub-directories. I can access the videos and play them, or update the files from any device on the network.
I was already aware that I could put an advancedsettings.xml file in the /.kodi/userdata folder and use a MySql database to share the database to all of my devices. I figured that would be the smartest way to re-create it on my new Pi2s. My old Pis' on the network are all using an older version of Kodi and I didn't want to mix versions especially when trying to use a MySql database. I went with creating a new database on a different server so that I had a clear migration path without confusion. Since I wanted to keep my old data as well I exported the data (many files to each folder) for re-import into the new database.
I started the re-scan on the movies directory and could see the progress on the Kodi screen I could also see the records being added to the database as well as the interface traffic on the NAS as Kodi was getting data. It all looked happy. My initial optimism was short lived when I attempted to look in Movies Recently Added and got nothing but a menu (that I shouldn't have gotten) no movies just a menu that looped back to its self from any pick. It didn't improve when I looked in the Kodi Movies interface and saw nothing except that same menu. I allowed the scan to complete in the hopes that it would then show me the movies it had scanned but no joy. The movies all exist in the database and appear to have gotten the exported information but do not show in the Movies interfaces.
Did this same behavior exist for TV Shows? Why yes. Yes it does. I thought that perhaps this was just Movies that were having problems so I scanned/imported the TV Shows from the same share different sub-directory expecting to see something different and was able to prove that Einstein was correct that "Expecting different results from the same tests is insanity" (to paraphrase). I did notice some where in here that it doesn't seem to be remembering the folder contents settings as it has to be set/reset each time its tried.
I decided that I must have done something wrong and opened the Videos>Files the NFS share and then on into the movies directory and was able to play one of the movies that it had made a record for in the database but would not show me in the user interface. Still thinking something wasn't right potentially with my setup (permissions maybe) I wiped the microsd and the thumb drive dropped the databases and did it all again. Still wrong, during the times I was waiting for the import I googled and read lots of bug repports and other problems posted about MySql without finding this issue.
Thinking that perhaps it was just me or my setup I tested by wiping the microsd and thumb drive again and then installing without adding the advancedsettings.xml. I allowed it to create the local (default) database. WooHoo! It did scan and add the movies to the local database it shows them in the Kodi user interface almost immediately. It did not get the watched marks from the .nfo files created by the export.
At different points in this excercise in futility (for me) I have tried other themes to see if the same problem persists and it does. I have tried it with and without assorted add-ons and most everything I can think of. The end result for me was that nothing mattered except for the use of the MySql Database, advancedsettings.xml and "Network Location" to connect to the NFS share.
A summary of my delima: I want to use a MySql database to share watched marks and such. The end run would be to connect 4 additional Pi 2s to the network (replacing the older Pis' I have now) and use the same sources from my NAS and the data from the MYSql database on all. This does not appear to work properly on Kodi using the network location and share/sources from my NAS even though the paths to the files appear to be correct in the database after scanning/import. It does work using the local database from a single Kodi installation. Is there another procedure I should be trying, or something I sound like I'm doing wrong?
I expect that the problem is a difference in the handling of the paths (especially when using Network Locations) between the Kodi interface and the scan/import process.
If there are tests I can perform or files I can provide I will do that but scanning in the shares/sources again to answer a question is very time consuming.
Details:
New Raspbery Pi 2, 8GB microsd, 16GB thumb drive 2.5 power supply
Installed with latest OSMC & Kodi (all updates applied)
MySql is installed on a separate system and is in use for several databases by other systems on my local network.
I've been using Raspberry Pis' (1s and 2s) XMBC and Kodi for a long time.
Movie and TV files (about 4.5 TB) are on 16TB FreeNAS in a single NFS share in 4 directories below the share.
The share is tested and I can see it from all systems on my local network and can access the share on the Pi after creating a "Network Location" and then creating a source for each of the 4 sub-directories. I can access the videos and play them, or update the files from any device on the network.
I was already aware that I could put an advancedsettings.xml file in the /.kodi/userdata folder and use a MySql database to share the database to all of my devices. I figured that would be the smartest way to re-create it on my new Pi2s. My old Pis' on the network are all using an older version of Kodi and I didn't want to mix versions especially when trying to use a MySql database. I went with creating a new database on a different server so that I had a clear migration path without confusion. Since I wanted to keep my old data as well I exported the data (many files to each folder) for re-import into the new database.
I started the re-scan on the movies directory and could see the progress on the Kodi screen I could also see the records being added to the database as well as the interface traffic on the NAS as Kodi was getting data. It all looked happy. My initial optimism was short lived when I attempted to look in Movies Recently Added and got nothing but a menu (that I shouldn't have gotten) no movies just a menu that looped back to its self from any pick. It didn't improve when I looked in the Kodi Movies interface and saw nothing except that same menu. I allowed the scan to complete in the hopes that it would then show me the movies it had scanned but no joy. The movies all exist in the database and appear to have gotten the exported information but do not show in the Movies interfaces.
Did this same behavior exist for TV Shows? Why yes. Yes it does. I thought that perhaps this was just Movies that were having problems so I scanned/imported the TV Shows from the same share different sub-directory expecting to see something different and was able to prove that Einstein was correct that "Expecting different results from the same tests is insanity" (to paraphrase). I did notice some where in here that it doesn't seem to be remembering the folder contents settings as it has to be set/reset each time its tried.
I decided that I must have done something wrong and opened the Videos>Files the NFS share and then on into the movies directory and was able to play one of the movies that it had made a record for in the database but would not show me in the user interface. Still thinking something wasn't right potentially with my setup (permissions maybe) I wiped the microsd and the thumb drive dropped the databases and did it all again. Still wrong, during the times I was waiting for the import I googled and read lots of bug repports and other problems posted about MySql without finding this issue.
Thinking that perhaps it was just me or my setup I tested by wiping the microsd and thumb drive again and then installing without adding the advancedsettings.xml. I allowed it to create the local (default) database. WooHoo! It did scan and add the movies to the local database it shows them in the Kodi user interface almost immediately. It did not get the watched marks from the .nfo files created by the export.
At different points in this excercise in futility (for me) I have tried other themes to see if the same problem persists and it does. I have tried it with and without assorted add-ons and most everything I can think of. The end result for me was that nothing mattered except for the use of the MySql Database, advancedsettings.xml and "Network Location" to connect to the NFS share.
A summary of my delima: I want to use a MySql database to share watched marks and such. The end run would be to connect 4 additional Pi 2s to the network (replacing the older Pis' I have now) and use the same sources from my NAS and the data from the MYSql database on all. This does not appear to work properly on Kodi using the network location and share/sources from my NAS even though the paths to the files appear to be correct in the database after scanning/import. It does work using the local database from a single Kodi installation. Is there another procedure I should be trying, or something I sound like I'm doing wrong?
I expect that the problem is a difference in the handling of the paths (especially when using Network Locations) between the Kodi interface and the scan/import process.
If there are tests I can perform or files I can provide I will do that but scanning in the shares/sources again to answer a question is very time consuming.