MediaPortal TV Server and Kodi media source issues

Discussion in 'General' started by Jimixter, November 7, 2019.

  1. Jimixter

    Jimixter New Member

    Joined:
    November 3, 2019
    Messages:
    14
    Likes Received:
    0
    Gender:
    Male
    Ratings:
    +0 / 0
    Home Country:
    England England
    We are using MediaPortal 2 TV Server as the back end, with Kodi as the client.

    MediaPortal 2 can save Movies and TV Series to their own designated folders, which Kodi maps as "sources". Kodi requires this, in order to correctly scrape the respective Movie and TV metadata.



    However, we have noticed that MediaPortal 2 is saving TV series (e.g. "Masterchef: The Professionals") to the Movies folder, which means Kodi has not picked it up. However, I would have thought that this would have been classed as a TV series!

    Obviously there are MediaPortal and Kodi limitations here. How are others managing to get the two to work together?
     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. CyberSimian
    • Team MediaPortal

    CyberSimian Test Group

    Joined:
    June 10, 2013
    Messages:
    1,687
    Likes Received:
    558
    Gender:
    Male
    Location:
    Southampton
    Ratings:
    +985 / 3
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    I use MP1, but my understanding is that MP1 and MP2 use the same "TV Server" code, although packaged differently (so you cannot use an MP1 TV Server from an MP2 client, or vice versa).

    As far as I know, TV Server has no understanding of the nature of what it is recording. What it does distinguish is the type of recording request -- either a single ("one off") recording or a repeated ("series") recording. You can specify the recording location on this panel in "TV Server Config":

    Recording

    Notice that for the first drop-down menu, it shows Movies (manual or single type recordings). The use of the word Movies here is misleading, as TV server does not know when it is recording a movie. So, I think that the only choices that you have are:

    (1) Store all one-off recordings in the same folder.
    (2) Store repeated recordings in a different folder for each recording request (by using folder notation with substitutions in the template).

    I record quite a few one-off documentaries, which (of course) are stored in the same folder as movies, since that is the only capability that TV Server provides.

    It may be that MP2 provides some post-processing to identify movies using information from the EPG or downloaded from the internet, but I have never used MP2 so cannot advise. However I am fairly sure that TV Server does not provide this capability.

    -- from CyberSimian in the UK
     
  4. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,903
    Likes Received:
    2,151
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,628 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    In MP2 all "one time only" recordings are treated as a "movie" and all "recurring" recordings are treated as "Series". If you want to recognize those as series or movies you need to define different sub- folders for both types of recordings. Means you have one recordings folder but in "custom path and filename" you need to define sub- folders for both types, Example how this could look for movies:
    upload_2019-11-8_14-23-42.png

    At first there is a static (means with a fixed name, no variables used here) folder named "movies". This is the same for all movies. Then there is another folder with name and year of the movie. This is different for every movie. In there finally the recording can be found. It's he same naming scheme that I use for cleaned movies in my library...

    For series you also need to define this sub-folder (a different one than the movies sub- folder of course)
    upload_2019-11-8_14-9-39.png

    If those folders are "static" then MP2 automatically imports both types accordingly. To have the same effect in Kodi you need to define 2 video sources, one for movies pointing to the "movies sub-folder" and one for series pointing to the "Series sub-folder". As long as you record all your series with "recurring" recordings and your moves as one time only everything is working as it should. Only the online lookup can be a bit of an issue, if the TV station don't name their program properly (happens very often here in Germany). With "wrong" names the movies/series can't be found during online lookup...

    I'm using Kodi 18.4 together with MediaPortal 2.1.3 for TV. It's working flawlessly and opposite to the MP1 "standalone" TV server you don't need to install a full blown MySQL database server only to serve the tiny little TVE database...
     

    Attached Files:

  5. CyberSimian
    • Team MediaPortal

    CyberSimian Test Group

    Joined:
    June 10, 2013
    Messages:
    1,687
    Likes Received:
    558
    Gender:
    Male
    Location:
    Southampton
    Ratings:
    +985 / 3
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    @Lehmden has provided a good explanation of how to specify the custom folder paths (y).

    However, not all of the substitution codes are usable, as some of these may not be present in the EPG information that you are using. Although %title% is virtually certain to be present, codes such as those listed below may not be present in the EPG; in particular they are not present in the UK broadcast EPG (which is the EPG that I use):

    %series%, %episode%, %name%, %part%, %startyear%, ...others

    If you use a different EPG source, these substitution codes may be usable. So try them and see what happens.

    Tiny? Doesn't the TV Server database store the EPG? (Likely to be several thousand entries for the UK.)

    -- from CyberSimian in the UK
     
  6. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,903
    Likes Received:
    2,151
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,628 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    Yes, tiny, at least compared to the media database. The TVE database (including all EPG data) is only about 10-20 Mbyte where the (my) media database is around 4-6 GByte of size... In MP2 you can easily see the size of the db as MP2 uses SQLite and here the database is a single file (ok, two files, a tiny one for the TVE and a huge one for the media library)...

    SQLite is capable of handling Terrabyte sized databases with ease. But MP2 can't handle this big databases due to performance issues. My media database is on the edge of what MP2 can handle on a low to mid- range PC. If you have a lot bigger database than mine you need a high- end CPU for the server.

    MP1 can not use the much faster (about 10 times as fast as MySQL) SQLite database engine as the MP1 TV client plugin has not very good code and does some direct database accesses instead of using the TV engine for all access (as it has to be). Those nasty direct access from outside is the only real reason for the need of a full blown database server in MP1 and it also is the only reason why MP1 can not access MP2 TV engine.

    For this the [] are there. substitution codes in [] are optional and the filename still is valid even if some things are missing. The season and episodes numbers are only very seldom included in EPG data. This is one of the reasons why I wrote EPG-Buddy as EPG-Buddy adds season and episodes numbers for most (some episodes can not be recognized and for this they get no numbers) of the episodes in the EPG data. And this way nearly all recordings will have proper season and episodes numbers and could easily be scrapped...
     
  7. CyberSimian
    • Team MediaPortal

    CyberSimian Test Group

    Joined:
    June 10, 2013
    Messages:
    1,687
    Likes Received:
    558
    Gender:
    Male
    Location:
    Southampton
    Ratings:
    +985 / 3
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    :eek: :eek: :eek:

    At some point in the past, MP1 changed from MySQL 5.2 to MySQL 5.6, which on my system caused a very noticeable slowdown in the EPG grabbing, due entirely to the database updates :(.

    MySQL 5.6 is roughly a factor of three slower than 5.2. I understand that this was due to a different internal structure to the database in 5.6 compared to 5.2. The benefit of 5.6 is that it is less vulnerable to database corruption due to applications not accessing or updating it correctly (or something like that). So I suppose the price of a more robust database is worse performance. :(

    -- from CyberSimian in the UK
     
  8. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,903
    Likes Received:
    2,151
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,628 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    600 series with about 25.000 episodes, 2500 movies, 250.000 songs and 500.000 pictures... Not really that much...;) I have slow internet so I can't use Netflix or the like with good picture quality. That's why I need to store anything locally...

    Probably. But the SQLIte is very robust. Database corruptions are very rare. The only thing SQLite did not "like" is multiple write access at the same time (multiple read access is no problem at all). That's why it is not possible to use SQLite for MP1 as here more than one client may write to the TV database at the same time. With MP2 this can not happen as all database access only is done by the MP2 server itself...
     
  9. Jimixter

    Jimixter New Member

    Joined:
    November 3, 2019
    Messages:
    14
    Likes Received:
    0
    Gender:
    Male
    Ratings:
    +0 / 0
    Home Country:
    England England
    How do you do this in Kodi? Some of my TV recordings are ending up in the Movies folder (where they cannot be scaped). I have done as you suggest but so many recordings cannot be scraped properly!
     
  10. Jimixter

    Jimixter New Member

    Joined:
    November 3, 2019
    Messages:
    14
    Likes Received:
    0
    Gender:
    Male
    Ratings:
    +0 / 0
    Home Country:
    England England
    Incidentally, using %startyear% just adds the current year (i.e. 2019) to the filename. Surely this is likely to cause scraper issues, since the scaper needs the date the movie was released instead?
     
  11. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,903
    Likes Received:
    2,151
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,628 / 28
    Home Country:
    Germany Germany
    Show System Specs
    This only happens, when you do a one time only recording. If this happens also you are using recurring recordings then you probably are using TVWishlist for scheduling. TVWishlist always does a "one time only" recording, even for series...

    Personally I don't use this feature at all. I don't like unfinished TV recordings with pre and post recording time and lots of commercials added to my well shaped media library. The only thing that is important to me are the season and episodes numbers. If I want to keep a recording then I trim and cut it first, remove all commercials and pre- post recordings. Then I use Media-Buddy to transcode the videos to HEVC in MKV container. TV recordings are way too big (at least 4 times as big as necessary) for the quality they have. Then Media-Buddy renames the video to my naming scheme and add .nfo files and local fanart to them. Once done I move the prepared videos into my library folder and scrap them in Kodi. This way I only have clean and lean videos inside my library and I always have a 100% match (due to the .nfo files), even if very new episodes are not (yet) added to TVDB.

    Also I don't use it for real I've tested this feature as it was added some time ago. That's why I know it is working. When you schedule a series recording you always need to use "Add Timer" with type "always record on..." or "daily, weekly,..." but not "one time..." and you never should use "Record" instead of "Add Timer", if you want to get your series recordings into the "series" subfolder... The rest is simply adding video sources to Kodi

    Most often the ugly EPG data is the reason for this... On the air EPG normally don't have season and episodes numbers included, often even the series and or episodes title is wrong. Web- based EPG data generally are better but most often lacking the numbers too... Those recordings never can be scrapped properly without further manual actions from the user.. This is the main reason why I have written EPG-Buddy as it adds proper season and episodes numbers to as much episodes as possible. The remaining 20 to 30% without numbers I need to match manually while cutting or editing them...

    If you want a good result you need to do a good preparation. Anything else is a gamble with way to often bad luck.
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!