Tuner assignment (1 Viewer)

PoBear

Portal Pro
April 17, 2006
78
0
Northants, United Kingdom
Hi

I hope this is in a suitable forum.

I'm using MP Server to record UK Freeview on three tuners each writing to it's own disk.

The facility to record everything being broadcast on a single MUX is fantastic but has introduced a unique problem that I'm wondering if there is anyway around.

MUX 1 and 2 carry the channels that I record the most and I often end up with the situation that I am recording 3 or even 4 programmes simultaneously on one tuner leaving the other two free, I'd like to limit the number of simultaneous recordings to 2 on any tuner so that I can spread the load better, I realise that this could introduce conflicts when I actually need all 3 turners available, but feel I can manage this more easily in the software I use to manage the EPG (I use Digiguide for this).

Is this a possibility and if so, how do I go about it?

Thanks
 

mm1352000

Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Hi PoBear

    As I recall, this is the first time somebody has asked for more tuners to be used than necessary.
    Can you help me understand: what benefit is there to "spreading the load"?

    To directly answer your question: it isn't possible to do it nicely. I can think of two options which will do something similar, but they're not exactly what you've asked for... and they involve some faffing around.

    The first option is the most "elegant" from a load spreading perspective, but it may not work.
    Mark all your channels as encrypted. This may be quite time-consuming if you manually edit each channel. If you know how to use an SQL database editor (phpMyAdmin, MySQL Workbench etc.) you could simply run the following query:
    UPDATE TuningDetail SET FreeToAir = True

    If not, you could try to use the import/export functions to help (export, replace all occurrences of FreeToAir="True" in the export file with FreeToAir="False", delete all channels in TV Server, then reimport)... but this may screw up your schedules and channel groups.
    In any case, after marking all channels as encrypted, you then need to configure each of the tuners (ie. repeat for all 3):
    http://wiki.team-mediaportal.com/1_...nfiguration/02_TV_Servers#Edit_Tuner_Settings

    Tick "CAM enabled and present..." and set CAM "decode" limit to the maximum number of channels you want each to handle simultaneously. Note that I said channels, not streams/users. If you had 100 people connecting to your TV Server and they all wanted to view the same channel, they'd all share the same tuner. Also note that this limit will apply to all channels, not only channels from MUX 1 and 2.


    The second option is to use the TV mappings section to control which tuners can tune each channel. For example, if MUX 1 and 2 each carry 6 channels, you could allocate a pair from each MUX to each of your 3 tuners. This doesn't hard-limit the number of recordings to 2 per tuner as requested, but if you choose the pairs carefully (ie. spread the channels that you record most often over different tuners) then it will force TV Server to spread the load somewhat.


    Note both options will introduce artificial restrictions on the numbers or combinations of channels you can timeshift/record simultaneously. There's no way to avoid that.

    Regards,
    mm
     

    CyberSimian

    Test Group
  • Team MediaPortal
  • June 10, 2013
    2,873
    1,801
    Southampton
    Home Country
    United Kingdom United Kingdom
    I'm using MP Server to record UK Freeview on three tuners each writing to it's own disk. ... I'd like to limit the number of simultaneous recordings to 2 on any tuner so that I can spread the load better
    I am also curious as to why you want to do this. I also use Freeview, but I have 8 DVB-T/T2 tuners, and (on occasion) make 8 simultaneous recordings to the same hard disk! :eek:

    Eight standard-definition recordings are no problem, and since starting to use MP, some of those recordings are now high definition (perhaps 4 HD plus 4 SD). I don't think that I have tried 8 HD recordings yet. (Thinks: I must try that!) The hard disk that I use (my "capture" disk) is a 750GB 7200rpm 3.5inch disk which I keep mostly empty (so that Windows can quickly allocate disk blocks to the recordings, and there are large contiguous areas of unused space), but otherwise the disk is nothing special. I would avoid using:

    (1) A laptop disk (2.5inch disk)
    (2) A 5400rpm or 4200rpm disk
    (3) A nearly-full disk

    All other disks should be satisfactory.

    The eight DVB-T/T2 tuners arose because I originally used Windows Media Center, which uses one tuner for each channel tuned/recorded, compared to MP's one tuner for each MUX tuned/recorded. If I were starting now with MP, I would probably install only a single quad-tuner card.

    -- from CyberSimian in the UK
     
    Last edited:

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    I don't think that I have tried 8 HD recordings yet. (Thinks: I must try that!)
    LOL :)
    HD is approximately 10 Mb/s = 1.25 MB/s
    Even the slowest modern HDDs - 5400 rpm - should be able to hit a minimum of 30 MB/s sequential write:
    http://www.tomshardware.com/charts/...te-Throughput-Minimum-h2benchw-3.16,2905.html

    8 HD recordings = 8 x 1.25 MB/s = 10 MB/s

    In other words, it should be a walk in the park... as long as the HDD is not highly fragmented or nearly full.
    ...but feel free to go ahead and try it... :D
     

    CyberSimian

    Test Group
  • Team MediaPortal
  • June 10, 2013
    2,873
    1,801
    Southampton
    Home Country
    United Kingdom United Kingdom
    In other words, it should be a walk in the park... as long as the HDD is not highly fragmented or nearly full.
    Yes, I agree (thanks for doing the maths! :)). The disk's sustained throughput should easily be enough to cope with the total data rate generated by multiple recordings.

    The aspect that is more difficult to assess is the maximum number of concurrent recordings, where there will be multiple files being written on different parts of the disk. 50 files each being written at 1 MB/sec will place a higher load on the disk than 1 file being written at 50 MB/sec. The read/write heads have to whizz back and forth between the multiple files, and at some point won't be able to whizz back and forth quickly enough to keep up with the data! :(

    I recollect that one of the disk makers published some specs for their range of "AV" disks, and specified the number of video streams that could be written concurrently; a value in the range 15-30 sticks in my mind (but that may be faulty recollection). However, most people don't use AV disks.

    -- from CyberSimian in the UK
     

    HTPCSourcer

    Retired Team Member
  • Premium Supporter
  • May 16, 2008
    11,418
    2,335
    Home Country
    Germany Germany
    50 files each being written at 1 MB/sec will place a higher load on the disk than 1 file being written at 50 MB/sec.
    That's correct, yet not really applicable as I/O operations are asynchronous. Read/write activities are buffered both at Windows OS and hardware level. In practice you will probably run into other bottle-necks first such as the PCIe band-width constraints before actually reaching the limits of concurrent hard-disk writes.

    Pretty much hypothetical though.
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    Both valid points.
    I guess the performance would be somewhere between the previous chart and these two:
    http://www.tomshardware.com/charts/hdd-charts-2013/-19-IOMeter-2006.07.27-4K-Random-Writes,2927.html
    http://www.tomshardware.com/charts/...-7-Windows-Media-Center-Performance,2912.html

    [edit: @HTPC_Sourcer you may be interested to know that TsWriter's write operations are actually synchronous. Of course there is buffering within TsWriter, and within the OS and hardware too... but still. Recently I changed the TVE 3.5 TsWriter to do async writing - WriteFileEx() - but this is not yet tested.]
     
    Last edited:

    HTPCSourcer

    Retired Team Member
  • Premium Supporter
  • May 16, 2008
    11,418
    2,335
    Home Country
    Germany Germany
    you may be interested to know that TsWriter's write operations are actually synchronous.
    I know. What I don't know though is if the actual MePo recording process of the tuner stream is channeled via tswriter.
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    What I don't know though is if the actual MePo recording process of the tuner stream is channeled via tswriter.
    It is. TsWriter receives the stream from the tuner (there is one TsWriter instance per tuner). TVE (through TV library) controls TsWriter, telling it where to write timeshifting and recording files. There would be no timeshifting or recording without TsWriter.
     

    CyberSimian

    Test Group
  • Team MediaPortal
  • June 10, 2013
    2,873
    1,801
    Southampton
    Home Country
    United Kingdom United Kingdom
    I recollect that one of the disk makers published some specs for their range of "AV" disks
    The application that needs many concurrent video streams is surveillance, which seems to be the way that the disk makers are marketing these devices. The quote below is from this PDF:

    http://www.seagate.com/files/www-co...n-gb/docs/video-vs-desktop-mb645-1-1403gb.pdf
    Unlike budget-priced desktop drives, these video and surveillance HDDs combine high capacity with powerful dual processor technology and video-optimised write-cache management. This blend of features meets the storage needs of multiple, high-quality video streams, which are common in DVR and surveillance environments.

    This page gives some specs for Seagate's current range of surveillance disks:

    http://www.seagate.com/gb/en/produc...e/surveillance-drives/surveillance-hdd/#specs

    from which it can be seen that Seagate specify "up to 32 video streams", but they do not specify the video resolution of those streams (which could range from 640x480 to 1920x1080 -- quite a difference in data rate!)

    Apologies to the original poster for this rather tangential discussion.

    -- from CyberSimian in the UK
     

    Users who are viewing this thread

    Top Bottom