Kodi Community Forum
MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - 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: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library (/showthread.php?tid=85654)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Basje - 2012-11-12

(2012-11-12, 00:34)Martijn Wrote: Why would we spend our time documenting things like db bumps in nightly versions while there are better things to do.
The bump are there because they are needed and not just for fun. If you know where they are follow the commits on github.

None of the new platforms have an official release so they are still in alpha version (or not even that) so why would we go restricting development just because a couple of users find it difficult to understand that the bumps are needed to improve. Backwards compatible would perhaps be possible but why should we do that. Again these are not even alpha versions.

And when should we do a database changed when we shouldn't do that over night? Never? You might as well stop developing and improving then.

I stand to my original point. If you don't like the version bumps don't use nightly versions!
You want to use the new platforms you do so at your own risk!
I get your point, sure, like I already said. But I think the XBMC team also gets a lot of feedback from those users that take the effort to try out those fresh new nightlies (or alphas) on multiple platforms. So, no, don't put too much effort in it. But having a dev update a list when he or she changes the database schema's would not be too much work I guess. If you tell me what files to watch in the code, I am even willing to keep that list up to date.



RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - jmarshall - 2012-11-12

We never change the database just because we can - we always change it because we have to. Yes, it's a pain in the arse for those using nightlies with shared mysql databases on multiple platforms where builds are not done by our buildbot, but we have no control over that at all.

Personally I would have ditched the insanity of trying to use a common database long ago. UPnP works well enough that the quirks where it doesn't really don't matter as much as the hassles you're getting trying to use a central database on all these different platforms.

About the only thing that really stops it atm is the watched status not being transferred back to the server. Something that alcoheca will hopefully have done by Frodo time.


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - jmarshall - 2012-11-12

@Basje: If you keep an eye on MusicDatabase.h/VideoDatabase.h that's all you need. In particular, the line is GetMinVersion().

I'm sure those running into these issues would appreciate your effort.


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Martijn - 2012-11-12

Something like this:
https://github.com/xbmc/xbmc/commit/481bb8e7ffe16e40646cbd2051cdb510e4b8d2c2#xbmc/video/VideoDatabase.cpp


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - proteus - 2012-11-12

UPnP works fine for certain users. But UPnP is not always available. It requires that either you have another UPnP server running somewhere in the network, or you keep on XBMC up all times. Neither are ideal.

And yes, database structure changes are occasionally necessary. Emphasis on "occasionally".

That change you just showed, that was not requiring a database version/name change. If I'm reading the code right, you didn't modify any table's structure, you're just updating the data in there, in particular the URLs. That could have been easily handled in the code, without requiring a change in database name.


Re: RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Martijn - 2012-11-12

(2012-11-12, 01:21)proteus Wrote: UPnP works fine for certain users. But UPnP is not always available. It requires that either you have another UPnP server running somewhere in the network, or you keep on XBMC up all times. Neither are ideal.

And yes, database structure changes are occasionally necessary. Emphasis on "occasionally".

That change you just showed, that was not requiring a database version/name change. If I'm reading the code right, you didn't modify any table's structure, you're just updating the data in there, in particular the URLs. That could have been easily handled in the code, without requiring a change in database name.

and so polluting the core code with something that will be useless for the rest of time till the end of days....

this is how the team has chosen it to if you agree or not.
This keeps core code clean of one time needed changes.
which will only happen on upgrade.

for mysql you also need a computer /nasty running so what's the difference with upnp? nothing, just that we haven't got a server like upnp


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Ned Scott - 2012-11-12

It seems like the only people who bitch about the DB bump are those with R-Pis. I've said this before, and it fits here perfectly, so I'm just going to directly quote myself:

Quote:YOU ARE USING EXPERIMENTAL DEVELOPMENT BUILDS. The fact that ANYTHING works at all is something to be thankful for.

On top of that, you're using a totally new device for XBMC, so things are even more unstable than using a development build on a desktop. What did you expect to happen here?

If you change(upgrade) what version of XBMC you are using then you are the one who has caused the video db version to change and make things difficult. If you don't like it then stick with stable builds and don't buy things like the Raspberry Pi until there is a stable version for it. Stable builds only bump that video db about once a year, and that's only if you choose to upgrade to the new version. There's a reason we give big scary warnings to people about using development builds (wiki) and say that most people should stick with stable ones.

But wait, we're not done yet. The official XBMC MySQL (wiki) guide clearly states that, even using that feature with stable versions of XBMC, it's still considered experimental.

The fact that this set up hasn't burnt your house down and stolen your credit cards is a miracle.



RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Basje - 2012-11-12

For people that are interested. Here are 2 RSS feeds that will notify you on a database version change.

Video: http://feed43.com/6825312828858004.xml
Music: http://feed43.com/6842865065477822.xml


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - proteus - 2012-11-12

Far from me to say that the work on XBMC is anything short of extraordinaire. That being said, one can always keep an open ear to what others are saying. I, personally, think there would have been better ways of handling that particular database change, but let's just agree to disagree there.

As for blaming the Raspberry PI users, you're on to something there, but maybe not in the way you think. The PIs make it much easier for people to have more than one XBMC device in the house. And I think that this tendency will only go up, and the types of devices will grow more and more diverse. Which means that: 1) there will be an ever growing need for shared library; and 2) it will become harder and harder to keep the versions in sync.

Which way is better to share libraries: MySQL or UPnP? Hard to say. I didn't have a good experience with UPnP, I found MySQL easier to run, especially on low-powered devices. But things might have changed. I will take your advice and see how's XMBC as UPnP server.



RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Basje - 2012-11-12

As promised I created a simple page to keep track of database version. It can be found here: http://www.rieter.net/pages/XBMC:Database_Versions. I first wanted to add it to the XBMC Wiki, but, taking the view of the devs into account, I did not yet put it there.

Devs: Please let me know if this page would be a good addition to the XBMC wiki. If so, I will transfer it there?


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Ned Scott - 2012-11-12

(2012-11-12, 23:28)proteus Wrote: As for blaming the Raspberry PI users, you're on to something there, but maybe not in the way you think. The PIs make it much easier for people to have more than one XBMC device in the house. And I think that this tendency will only go up, and the types of devices will grow more and more diverse. Which means that: 1) there will be an ever growing need for shared library; and 2) it will become harder and harder to keep the versions in sync.

There's nothing special about the R-Pi. It will get a stable build with v12, just like all the other platforms. It will not become harder to keep versions in sync because most people will stick with v12 final when it comes out at the end of the year.



RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Ned Scott - 2012-11-12

(2012-11-12, 23:44)Basje Wrote: As promised I created a simple page to keep track of database version. It can be found here: http://www.rieter.net/pages/XBMC:Database_Versions. I first wanted to add it to the XBMC Wiki, but, taking the view of the devs into account, I did not yet put it there.

Devs: Please let me know if this page would be a good addition to the XBMC wiki. If so, I will transfer it there?

I have no opposition to adding that info, but most users probably won't find it useful because they still don't know what commit their version of XBMC is using. They'll ether want to know a date range or in the case of the R-Pi, they'll want to know what version of OpenELEC, Raspbmc, or XBian = what DB version.


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - TechLife - 2012-11-16

Deleted


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - asturnauta - 2012-11-18

HI,

I am using XBMC 11.0 Eden and i configured it for share databases on my NAS

I have a question: if i want to sync sources too, have i to add on advancedsettings.xml this?
Code:
<substitute>
    <from>special://profile/sources.xml</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/sources.xml</to>
  </substitute>
  <substitute>
    <from>special://profile/mediasources.xml</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/mediasources.xml</to>
  </substitute>

Or it is like thumbnail/fanart that the sync is auto?


Thanks.


RE: MySQL Database: Multiple XBMC HTPC's with 1 Shared Library - Ned Scott - 2012-11-18

You can either pathsub them like that example or copy the sources.xml file between XBMC boxes. It's not really required for a smooth set up, but is a convenience thing.