Locked time-shift files cause failure to change channel

Discussion in 'Television (MyTV frontend and TV-Server)' started by Charlie TV, January 13, 2016.

  1. Charlie TV
    • Premium Supporter

    Charlie TV MP Donator

    Joined:
    February 22, 2014
    Messages:
    81
    Likes Received:
    10
    Ratings:
    +29 / 2
    Home Country:
    United Kingdom United Kingdom
    Last edited by a moderator: January 26, 2016
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    I can see that your time-shift drive (E: ) has 6.2 GB total space, and that only 1.5 GB was free at the time the logs were collected. MASTER had been time-shifting since even before BIGBOY's test started, and so presumably was using a full sized buffer:
    [2016-01-12 17:39:54,070] [Log ] [3 ] [INFO ] - Controller: StartTimeShifting started on card:9 to E:\\live9-1.ts.tsbuffer

    Further, I can see that time-shfit files were cleared after your failed channel change:
    Show Spoiler

    [2016-01-13 18:28:08,846] [Log ] [33 ] [INFO ] - Controller: find free card for channel BBC ONE South
    ...
    [2016-01-13 18:28:24,227] [Log ] [33 ] [INFO ] - Controller: Timeshifting failed, no more cards available.
    ...
    [2016-01-13 18:28:24,383] [Log ] [TS_File_Cleanup] [INFO ] - card: delete timeshift files E:\\live9-3.ts
    [2016-01-13 18:28:24,383] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer
    [2016-01-13 18:28:24,383] [Log ] [44 ] [DEBUG] - Controller: DoSetChannelStates for 66 channels
    [2016-01-13 18:28:24,383] [Log ] [44 ] [INFO ] - ChannelStates.GetAllTimeshiftingAndRecordingChannels took 1 msec
    [2016-01-13 18:28:24,524] [Log ] [44 ] [INFO ] - ChannelStates.DoSetChannelStates took 153 msec
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: delete timeshift files E:\\live9-3.ts
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer1.ts
    [2016-01-13 18:28:29,438] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer1.ts
    [2016-01-13 18:28:29,438] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer2.ts
    [2016-01-13 18:28:29,453] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer2.ts
    [2016-01-13 18:28:29,453] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer3.ts
    [2016-01-13 18:28:29,500] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer3.ts


    That's presumably what enabled the subsequent channel changes to succeed.

    In short: the circumstances seem to make sense.

    Keep in mind that the time-shift buffer settings are per-stream.
    This table might also be of some use to you:
    http://wiki.team-mediaportal.com/1_...k_for_Timeshifting/Suggested_Ramdisk_Settings
     
    Last edited: January 26, 2016
  4. Charlie TV
    • Premium Supporter

    Charlie TV MP Donator

    Joined:
    February 22, 2014
    Messages:
    81
    Likes Received:
    10
    Ratings:
    +29 / 2
    Home Country:
    United Kingdom United Kingdom
    Cool I think :) I have the Ramdisk settings in-line with the guide already. Bounce this if it's off topic but should I therefore change anything?

    btw it's always confused me why MP states that the Drive space needed is 3150 MByte!? Would be nice to have just a dropdown menu, how much disk space do you have, how many clients to support and it just does magic and handles how many files and sizes etc. The min/max files is over my head, even after reading the wiki page many times! :)

    Anyway, thank you for your help and usual amazing support :)

    Cheers
     

    Attached Files:

    • RAM-Disk.jpg
      RAM-Disk.jpg
      File size:
      35.7 KB
      Uploaded:
      January 14, 2016
      Views:
      99
  5. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    Hmmm, that's interesting because the maths doesn't add up.

    The dxdiag log tells me that the E: drive has 6.2 GB total space, but only 1.5 GB was free. This was the status after BIGBOY's stream had stopped.

    I know from the TV service log file that BIGBOY's stream had 3 time-shift files:
    Show Spoiler

    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: delete timeshift files E:\\live9-3.ts
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer
    [2016-01-13 18:28:29,391] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer1.ts
    [2016-01-13 18:28:29,438] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer1.ts
    [2016-01-13 18:28:29,438] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer2.ts
    [2016-01-13 18:28:29,453] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer2.ts
    [2016-01-13 18:28:29,453] [Log ] [TS_File_Cleanup] [INFO ] - card: trying to delete E:\live9-3.ts.tsbuffer3.ts
    [2016-01-13 18:28:29,500] [Log ] [TS_File_Cleanup] [INFO ] - card: deleted file E:\live9-3.ts.tsbuffer3.ts


    3 x 350 = 1.05 GB

    1.5 - 1.05 = total space available when BIGBOY was trying to change channel = 450 MB

    That number seems right because in order to successfully start time-shifting, TV Server requires that there be enough space to create 2 time-shift files.

    What doesn't add up is how only 1.5 GB could be free (and 4.7 GB used) when only MASTER is streaming. Even with a full sized buffer, MASTER's stream should only have been using 8 x 350 MB = 2.8 GB. Is there other stuff using up space on the disk?


    No, not unless part of the disk space is used for something else.

    That number is calculated as: (8 stream files + 1 file worth of free space) x 350 MB per file.
    The "1 file worth of free space" is space left to ensure the disk doesn't ever get completely full (which can be really bad if the disk is also used for the operating system).

    It would be nice to not have to specify the file counts and sizes, but the maths gets quite tricky. Essentially the mathematical problem is: what is the smallest common factor of 2 numbers which is greater than or equal to [approx.] 100 MB.

    "Min" is not really a minimum. It's just the standard buffer size when time-shifting.
    "Max" only has an effect when you pause. When you pause, the buffer size can increase from the standard size up to the maximum size.
     
  6. Charlie TV
    • Premium Supporter

    Charlie TV MP Donator

    Joined:
    February 22, 2014
    Messages:
    81
    Likes Received:
    10
    Ratings:
    +29 / 2
    Home Country:
    United Kingdom United Kingdom
    Hi,

    The RAM disk isn't used for anything else, just the MP buffers.

    I can pull logs from MASTER (the other client) if that is helpful? I've only provided the logs for the TVServer (called MEDIA) and one of the clients BIGBOY. So I just put both clients on different HD channels to cause maximum stress and after a day or two I get the error message. It's not the end of the world tbh I don't normally have MASTER turned on that much, it was just in the interests of breaking stuff for you ;)

    Cheers
     
  7. Charlie TV
    • Premium Supporter

    Charlie TV MP Donator

    Joined:
    February 22, 2014
    Messages:
    81
    Likes Received:
    10
    Ratings:
    +29 / 2
    Home Country:
    United Kingdom United Kingdom
    Hi, just for info.. I had the Unable to Play:confused:tream 9 error today;

    In the Log on the TV Server End;
    [2016-01-22 12:46:48,484] [Log ] [33 ] [INFO ] - card2:BIGBOY 9 0
    [2016-01-22 12:46:48,484] [Log ] [33 ] [INFO ] - Controller: delete timeshift files E:\\live9-0.ts
    [2016-01-22 12:46:48,484] [Log ] [33 ] [INFO ] - Controller: delete E:\live9-0.ts.tsbuffer
    [2016-01-22 12:46:48,484] [Log ] [33 ] [DEBUG] - Controller: Error "The process cannot access the file 'E:\live9-0.ts.tsbuffer' because it is being used by another process." on delete in CleanTimeshiftFiles
    [2016-01-22 12:46:48,484] [Log ] [33 ] [INFO ] - Controller: delete E:\live9-0.ts.tsbuffer6.ts
    [2016-01-22 12:46:48,484] [Log ] [33 ] [DEBUG] - Controller: Error "The process cannot access the file 'E:\live9-0.ts.tsbuffer6.ts' because it is being used by another process." on delete in CleanTimeshiftFiles
    [2016-01-22 12:46:48,500] [Log ] [33 ] [INFO ] - Controller: delete E:\live9-0.ts.tsbuffer8.ts
    [2016-01-22 12:46:48,500] [Log ] [33 ] [DEBUG] - Controller: Error "The process cannot access the file 'E:\live9-0.ts.tsbuffer8.ts' because it is being used by another process." on delete in CleanTimeshiftFiles
    [2016-01-22 12:46:48,500] [Log ] [33 ] [INFO ] - Controller: epg stop

    Rebooting the client made no difference, there is 5Gb free on the RAM disk on the Server. Stopping/starting the service on the Server fixed it.

    If it helps and you want full logs let me know or if it's more helpful to load these into a new thread etc.

    Cheers
     
  8. Sebastiii
    • Team MediaPortal

    Sebastiii Development Group

    Joined:
    November 12, 2007
    Messages:
    16,264
    Likes Received:
    6,218
    Gender:
    Male
    Location:
    France
    Ratings:
    +10,224 / 9
    Home Country:
    France France
    Show System Specs
    Need full log m8 :)
     
  9. Charlie TV
    • Premium Supporter

    Charlie TV MP Donator

    Joined:
    February 22, 2014
    Messages:
    81
    Likes Received:
    10
    Ratings:
    +29 / 2
    Home Country:
    United Kingdom United Kingdom
    Hi,

    Sure no problem, here is the log from the TV Server end

    Cheers
     
    • Thank You! Thank You! x 1
  10. Charlie TV
    • Premium Supporter

    Charlie TV MP Donator

    Joined:
    February 22, 2014
    Messages:
    81
    Likes Received:
    10
    Ratings:
    +29 / 2
    Home Country:
    United Kingdom United Kingdom
    Hi, another crash as attached. Thanks
     
    • Thank You! Thank You! x 1
  11. mm1352000
    • Team MediaPortal

    mm1352000 Development Group

    Joined:
    September 1, 2008
    Messages:
    21,527
    Likes Received:
    4,738
    Ratings:
    +8,205 / 17
    Home Country:
    New Zealand New Zealand
    I'm confused. I can't see any indications that MediaPortal or TV Server crashed, and I don't recall you mentioning crashes previously either.
    So, please can you explain what you mean. Dates/times and channel names would be appreciated.
     
    • Like Like x 1
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!