One Database on multiple computers...? (1 Viewer)

fkm

Portal Member
February 4, 2007
6
0
Can't seem to find an answer to this so appreciate if anyone could help out!

I'm looking to setup a few HTPC's with mediaportal as the front end. I want to have the same movies database on all of the computers.

Therefore, is there any way to save/backup the database (to export/import) and/or can mediaportal access the one database from a central NAS?

Thanks
 

freeflyer

New Member
March 15, 2008
4
0
just set them up on the network path and offline synch.. or am i missing something? I've got my main stored files on a pc upstairs, with the HTPC networked downstairs.. MP picks up on the networked files no prob in vista one you have redone the locations of the user shortcuts.

To make them available when the upstairs PC is off , simply set up an offline synch which will store a copy of the files onthe local machine, and automatically update accordingly.
 

fkm

Portal Member
February 4, 2007
6
0
Thanks though maybe I wasn't being specific enough!

It's not about access to my shares/networked files which I am already able add to each HTPC eg 'View by shares'.

Rather, I'm talking about the movie database where you manually add movie files from your shares and then Mediaportal collects IMDB info, cover art etc.. for each one. Thus from within Mediaportal, I can then view the database by 'View by title' or 'View by genre' etc and also get a movie synopsis by pressing F3 etc...

Creating this can take a while and thus was wondering where this movie database file is saved and if there is some export/import function to transfer it between HTPC's (or even just for backup purposes). Alternatively, it would be great if all HTPC's would read from the same movie database.


Thanks for any help...!
 

Bagal

MP Donator
  • Premium Supporter
  • December 15, 2006
    229
    16
    Home Country
    United Kingdom United Kingdom
    The movie database (and all MediaPortal DBs) are stored in the following location (at least on WinXP): C:\Program Files\Team MediaPortal\MediaPortal\database.

    You can change the location of the databases by editing the mediaportaldirs.xml file which is located: C:\Program Files\Team MediaPortal\MediaPortal
    Look for <Dir id = "Database"> and change the path to be a share on your NAS, subsequently copying the databases from your local path to the NAS as well.

    Then change the paths on all your HTPCs to be the same and they'll all be using the one database. The only thing to be aware of is that the database can only be updated by one client at a time, it's a restriction with SQLite, however I haven't had any major problems with this and I don't seem to have a problem with multiple clients reading from the DB file at the same time.

    One other thing I should point out, which you've probably already realised, is that all the databases live in the same location, so changing the location of the movies DB means changing the location of all DBs, which you may or may not want.
     

    fkm

    Portal Member
    February 4, 2007
    6
    0
    Aboslutely fantastic, exactly what I was hoping for!

    Vista has the database files in a hidden folder 'Program Data' --> Mediaportal but otherwise, it seems to work fine.


    Thanks again!

    By the way, can anybody confirm that Mediaportal has a T9 search function via remote control in the database?
     

    spxero

    New Member
    June 18, 2007
    3
    0
    Home Country
    United States of America United States of America
    Thank you!!!

    Thank you for posting this! It has made managing my three (soon to be four) media portals soooooo much easier! Thanks!


    :D
     

    bwg

    Portal Pro
    December 25, 2007
    145
    38
    Home Country
    The only thing to be aware of is that the database can only be updated by one client at a time, it's a restriction with SQLite
    I'm currently doing this, and am in need of a little clarification. Does this restriction mean that when I have 2instances running that I will not see changes made to the database until I restart? Or does the instance that was running first tie-up the db, so that I will only see the changes made by that instance, not the 2nd instance?

    This is a problem for me as I leave mediaportal running on both my front-ends (with a s3 stand-by on one of them). It would be nice if the 'watched' status of videos could be updated from both, but this is not happening properly at the moment. Does anyone know if there are any planned changes that will affect this?
     

    spxero

    New Member
    June 18, 2007
    3
    0
    Home Country
    United States of America United States of America
    The only thing to be aware of is that the database can only be updated by one client at a time, it's a restriction with SQLite
    I'm currently doing this, and am in need of a little clarification. Does this restriction mean that when I have 2instances running that I will not see changes made to the database until I restart? Or does the instance that was running first tie-up the db, so that I will only see the changes made by that instance, not the 2nd instance?

    This is a problem for me as I leave mediaportal running on both my front-ends (with a s3 stand-by on one of them). It would be nice if the 'watched' status of videos could be updated from both, but this is not happening properly at the moment. Does anyone know if there are any planned changes that will affect this?

    From what I have seen, the updates are instant. I can press 'stop' on a video in one room, go to the other room, and when I open that video up, it asks me if I want to resume from where I left off on the original media center.

    In addition, every 'imdb update' I do (changing pictures, etc.) is also picked up on the other media centers.
     

    Bagal

    MP Donator
  • Premium Supporter
  • December 15, 2006
    229
    16
    Home Country
    United Kingdom United Kingdom
    It should only be a restriction if the 2 instances try to write to the DB at the same time, as stated in the wiki docs: 'Only one person can edit the database at anyone time. This is a limitation with SQLite Databases.'
    i.e. most of the time you shouldn't have a problem, however as you can see from yourself and others responses it can vary.

    For my part, most of the time it works well, the one DB I seem to have a problem with is My TV Series, although I'm convinced this is something to do with the NIC resuming from S3 standby on one machine...
     

    Users who are viewing this thread

    Top Bottom