INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Problems with Live TV on library client  (Read 2686 times)

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Problems with Live TV on library client
« on: December 19, 2012, 12:42:23 pm »

My wife contacts me at work every single day because the TV isn't working - ever since I started using MC18 to stream live TV from the server in the basement to the HTCP Library Client instead of having the HTPC user the tuners directly.

- "Something went wrong with playback" when trying to tune to a channel. This sometimes happens just the first time you do it, and if you retry it will work (probably because the drive was asleep on the server, or something). But, often, it never works, and if you go to the basement to see what's going on you get "uh, MC is already running, or not responding, or something, try restarting" message when you try to open MC. We have to kill media server or restart the computer. Then it's fixed for awhile. This is the one that scares me the most because I think if the server gets in this state, recordings won't work either (and certainly, if we have to restart it better not be in the middle of a recording).

- "No television tuner is available to fulfill your request" - I think I've figured this one out. The way MC18 streams TV is by recording it locally and then having the client play the file while it's recording. Well, if things go haywire on either the client or the server, this recording may never ever stop happening.  I think what causes this problem is when the tuner remains on the channel even though the client is no longer watching that channel. If this happens enough, there aren't any tuners left. Even when this doesn't happen, it is extremely common for the recording files to not get cleaned up and for them to sit on the server until I find and delete them.

- I see info for the show in the guide, but while watching, there is no info available. It doesn't even know how long the show is. Also, in the info I see right before I press "Watch," it shows the file name of the temporary jtv file it's going to use to stream me the live TV.

- When you are watching Live TV on a delay, there is often a problem when you catch up with live (like lips getting out of sync, video pausing and then playing really fast to catch up, silience, etc.). This never used to happen when we used the tuner directly.
Logged

Yaobing

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10926
  • Dogs of the world unite!
Re: Problems with Live TV on library client
« Reply #1 on: December 19, 2012, 05:23:58 pm »

I am not sure what's causing the problems.  One possibility is, just as you suggested, the server takes too long to respond.  This could be the reason for getting "No tuner is available..." message (in addition to the possibility or the fact that a tuner is left running when it should be shutdown).  I will try finding ways to improve.
Logged
Yaobing Deng, JRiver Media Center

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Re: Problems with Live TV on library client
« Reply #2 on: December 22, 2012, 08:22:55 am »

I just had the "no tuner available" problem. I went to the server and MC wasn't responding and I had to restart it. It never recovers from this error.

As for the server taking too long to respond, I think that might be true for the case where I get "something went wrong with playback" the first time, and then a subsequent try works. This could be because the external hard drive the server uses may take 20 seconds to wake up if it hasn't been used in awhile. Otherwise, though, the server is extremely fast (i5, 16GB RAM, not really doing anything else) so I don't think it's taking too long to respond in any of the other cases.
Logged

rowens

  • Regular Member
  • Recent member
  • *
  • Posts: 40
  • Change this by choosing profile
Re: Problems with Live TV on library client
« Reply #3 on: December 31, 2012, 10:29:57 am »

HI - i'm having the exact same issue; getting the "no tuner available" error message on the client and when I go back to the Server, MC18 is frozen and has to be restarted.  Interestingly, there are files in the Server recording folder so it looks like it was recording.

FWIW - i have 2 HDHomeruns (4 tuners total).  They are only setup on the Server, not on the clients.

Logged

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Re: Problems with Live TV on library client
« Reply #4 on: January 03, 2013, 08:33:45 pm »

After some more experience with this, I think that the only real error is the "something went wrong with playback" that you get repeatedly. The "no tuner available" error only happens when you keep retrying and get the "something went wrong with playback" error enough to have used up all your tuners. The failure must grab a tuner and not let go of it.
Logged

Yaobing

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10926
  • Dogs of the world unite!
Re: Problems with Live TV on library client
« Reply #5 on: January 03, 2013, 08:39:52 pm »

Can you grab a log on the server when the error occurs?  The tricky part is the error may not occur for a long time and the log becomes too large to be emailed.
Logged
Yaobing Deng, JRiver Media Center

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Re: Problems with Live TV on library client
« Reply #6 on: January 04, 2013, 05:12:25 pm »

Ok, I just enabled logging. Actually, I had to restart MC first because when this problem occurs, it hangs the MC server. I can't open it on the server. Oddly, other operations on the client work properly (like playing music). Maybe this is because they use the magical "oh I know how to reach that network path directly" feature and it isn't really going through the library server at all.

Next time I have the problem, I will kill the MC process, start it up, and do Report Problem. Just understand that this issue doesn't crash MC, so there may not be an interesting event to look at.

It might be useful for you guys if "Something went wrong with playback" errors automatically sent you an email with at least a little more detail on what happened.

Logged

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Re: Problems with Live TV on library client
« Reply #7 on: January 05, 2013, 09:25:12 pm »

Can you grab a log on the server when the error occurs?  The tricky part is the error may not occur for a long time and the log becomes too large to be emailed.
I just emailed you the log. Tell me if you don't get the email or if you have any trouble getting the log. I could put it in Dropbox instead. Thanks!
Logged

Daveyravey

  • Galactic Citizen
  • ****
  • Posts: 443
Re: Problems with Live TV on library client
« Reply #8 on: January 06, 2013, 04:03:21 am »


I had the "no tuner available" problem yesterday evening whilst upstairs and noticed that the server had crashed. kill mc18 and restart then it was fine.

Next time it crashes ill attach a log to this post

Regards

Dave

Logged

Yaobing

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10926
  • Dogs of the world unite!
Re: Problems with Live TV on library client
« Reply #9 on: January 06, 2013, 01:54:18 pm »

I just emailed you the log. Tell me if you don't get the email or if you have any trouble getting the log. I could put it in Dropbox instead. Thanks!

I have received the log.  Thanks.  I will read it tomorrow.
Logged
Yaobing Deng, JRiver Media Center

Yaobing

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10926
  • Dogs of the world unite!
Re: Problems with Live TV on library client
« Reply #10 on: January 10, 2013, 09:10:10 am »

Sorry it took so long.

I found some things in the log that may or may not be the cause of the issues.

Firstly there is a reference counting issue.  When the same client tries to watch different channels consecutively, the server uses the same tuner to serve the client, but adds up the count.  When the client eventually stops, the reference count does not come down to zero, leaving the tuner loaded.  This however may not be a real problem.  Even though the tuner is not released, it is not considered "being in use" either.  It can be subsequently used.  I wonder whether having a tuner loaded for many hours without unloading it could be bad.  In any case this will be fixed in an upcoming build.

Secondly I see in the log a couple of times when the program is stuck for more than 20 seconds, apparently trying to create a file.  I wonder whether your hard drive went in deep sleep and was having trouble waking up.

Thirdly, and more mysteriously, near the end of the log the main thread is stuck somewhere.  I have not being able to identify the cause of it.  All client requests for playing a channel went unanswered.  That was why the client got "no tuner available" error.
Logged
Yaobing Deng, JRiver Media Center

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Re: Problems with Live TV on library client
« Reply #11 on: January 11, 2013, 11:19:09 pm »

Secondly I see in the log a couple of times when the program is stuck for more than 20 seconds, apparently trying to create a file.  I wonder whether your hard drive went in deep sleep and was having trouble waking up.
This is true. I use an OWC Mercury Elite external hard drive array to store large media, and it takes 20 seconds to wake up the first time it's used after it falls asleep. It seems like MC is not very tolerant of this (not just for TV). Is this possible to improve? I think I can solve it by writing a batch file that touches the drive every 5 minutes, or something, but it seems like a waste of electricity.

Thirdly, and more mysteriously, near the end of the log the main thread is stuck somewhere.  I have not being able to identify the cause of it.  All client requests for playing a channel went unanswered.  That was why the client got "no tuner available" error.
This is consistent with the fact that if I go to the server, it appears hung and I have to kill the process. There is a perfect relationship between this problem occurring and the server hanging like this. However, the log I sent you did not ever get the "no tuner available" error - it just got the "something went wrong with playback" error indefinitely. So, it still seems like there's something we don't understand.

I also just updated to the build containing the referencing counting fix, so we'll see how it goes from here. Thanks.
Logged

Yaobing

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10926
  • Dogs of the world unite!
Re: Problems with Live TV on library client
« Reply #12 on: January 12, 2013, 09:16:04 am »

This is true. I use an OWC Mercury Elite external hard drive array to store large media, and it takes 20 seconds to wake up the first time it's used after it falls asleep. It seems like MC is not very tolerant of this (not just for TV). Is this possible to improve? I think I can solve it by writing a batch file that touches the drive every 5 minutes, or something, but it seems like a waste of electricity.

As it is now, the client is in blocking mode trying to get the server to start TV.  Until I find another way to do it, 20 seconds is way too long to way.

Quote
This is consistent with the fact that if I go to the server, it appears hung and I have to kill the process. There is a perfect relationship between this problem occurring and the server hanging like this. However, the log I sent you did not ever get the "no tuner available" error - it just got the "something went wrong with playback" error indefinitely. So, it still seems like there's something we don't understand.

Unfortunately it hang in a function that is not logged.  So I can not figure out where it hang from your log.
Logged
Yaobing Deng, JRiver Media Center

greg.smalter

  • World Citizen
  • ***
  • Posts: 153
Re: Problems with Live TV on library client
« Reply #13 on: February 13, 2013, 10:05:07 pm »

The situation has not gotten any better. I have prevented my hard drives from going to sleep on the computer acting as the Library Server. I have created a scheduled task to write the current time to mass storage drive every 5 minutes so it can't go to sleep even if it wants to. But both errors persist. I still usually have to re-try the first time I start viewing Live TV, and today I had to restart the server because I had the error saying there were no tuners.

There are still some issues with streaming live TV versus having it local (the channel down button doesn't work - it rewinds to the beginning of the stream; there is no detailed info when you select a show to watch - just an ugly random file name; my TV recordings get polluted with live streams that weren't cleaned up properly; channel changing is bad, like local channel switching used to be before it was made to be awesome). Maybe if some of those issues get resolved, it could solve this problem as a side effect.
Logged
Pages: [1]   Go Up