View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 13 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
 Post subject: New Info after SSH login
PostPosted: Sun Jul 29, 2012 2:15 pm 
Offline
Joined: Fri Oct 20, 2006 12:04 pm
Posts: 905
Location: LA, CA
I Putty into my backend regularly and after the 7.3 upgrade, I see a LOT of backend information when I login. COOL! Shows Tuner status, upcoming recordings, and a couple more things. I was just wondering where this info comes from and if I can call it from a bash script somewhere. It's like looking at the MythWeb status page, I gotta know... mythbackend --printschedule isn't very human readable and dumps a bunch of redundant stuff.

TIA


Top
 Profile  
 
PostPosted: Sun Jul 29, 2012 3:30 pm 
Offline
Site Admin
Joined: Fri Jun 11, 2004 7:58 am
Posts: 507
Glad someone found it useful.

It's generated with a python program that pulls info using the bindings.
On login myth_status.sh is called, which in turn calls myth_status.py


Top
 Profile  
 
PostPosted: Sun Jul 29, 2012 5:54 pm 
Offline
Joined: Fri Oct 20, 2006 12:04 pm
Posts: 905
Location: LA, CA
SWEET! Thanks Jams, this is a nice touch.


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 9:10 am 
Offline
Joined: Fri Nov 04, 2005 7:11 am
Posts: 61
Mine is partially working. I get the upcoming recordings, but after that, I get the following:

Conflicted Recordings:
----------------------
Traceback (most recent call last):
File "/usr/LH/bin/myth_status.py", line 92, in <module>
a=be.getConflictedRecordings()
File "/usr/lib/python2.6/site-packages/MythTV/mythproto.py", line 743, in __ca
ll__
return self.sortedrun(*args, **kwargs)
File "/usr/lib/python2.6/site-packages/MythTV/mythproto.py", line 780, in sort
edrun
key=lambda p: p.starttime))
File "/usr/lib/python2.6/site-packages/MythTV/mythproto.py", line 774, in run
pg = self.func(pg, *args, **kwargs)
TypeError: getConflictedRecordings() takes exactly 1 argument (2 given)

_________________
BE: R8.4, HVR2250, MCE media center remote, GigaByte GA-EP43-UD3L, 2gb ram

FE: Linhes 8.4, Mythbuntu, Linux Mint DE


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 10:34 am 
Offline
Joined: Mon Apr 10, 2006 3:48 pm
Posts: 997
Location: Lexington, Ky
You might check and see if you have a config.xml

/usr/share/mythtv/config.xml or ~/.mythtv/config.xml


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 11:58 am 
Offline
Joined: Fri Nov 04, 2005 7:11 am
Posts: 61
I have a config.xml in both places. They differ in three places as listed below. I assume the one in ~/.mythtv trumps the one in /usr/share/mythtv

/usr/share/mythtv/config.xml
Code:
<MediaRenderer>10312eb3-be1b-4b87-a7ec-4e70b0e2be56</MediaRenderer>
<DBHostName>127.0.0.1</DBHostName>
<DBPort>0</DBPort>




/home/mythtv/.mythtv/config.xml
Code:
<MediaRenderer>10312eb3-be1b-4b87-a7ec-4e70b0e2be56</MediaRenderer>
<DBHostName>localhost</DBHostName>
<DBPort>3306</DBPort>


I took out the parts of the files that were identical for brevity.

_________________
BE: R8.4, HVR2250, MCE media center remote, GigaByte GA-EP43-UD3L, 2gb ram

FE: Linhes 8.4, Mythbuntu, Linux Mint DE


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 11:59 am 
Offline
Joined: Sat Feb 03, 2007 12:52 am
Posts: 187
Location: Manitoba, Canada
I was playing with a USB tuner one time and I unplugged the tuner without removing it from mythtv-setup. I got similar errors till I removed it from mythtv-setup or reconnected the tuner. Anything like that going on?


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 12:37 pm 
Offline
Joined: Fri Nov 04, 2005 7:11 am
Posts: 61
Nothing like that, but I have been getting some errors in my kernel log that make me wonder if my PVR-500 card might be going bad. I was planning on doing some testing tonight. (The standard def tuners don't get much use anymore.)

Code:
2012-08-07T08:59:59.368920-04:00 myth kernel: [118915.663034] ivtv0: Encoder has
 died : ivtv_serialized_open                                                   
2012-08-07T08:59:59.368937-04:00 myth kernel: [118915.663038] ivtv0: Detected in
 ivtv_serialized_open that firmware had failed - Reloading                     
2012-08-07T09:00:00.145097-04:00 myth kernel: [118916.444124] ivtv0: Loaded v4l-
cx2341x-enc.fw firmware (376836 bytes)                                         
2012-08-07T09:00:00.348097-04:00 myth kernel: [118916.647480] ivtv0: Firmware re
start okay

_________________
BE: R8.4, HVR2250, MCE media center remote, GigaByte GA-EP43-UD3L, 2gb ram

FE: Linhes 8.4, Mythbuntu, Linux Mint DE


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 12:54 pm 
Offline
Joined: Mon Apr 10, 2006 3:48 pm
Posts: 997
Location: Lexington, Ky
You might want to see if your PVR-500 is changing to different device than what it is configured as. Since the change to udev you may need to write some rules
Check out this link
viewtopic.php?f=21&t=22612
Tim


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 1:14 pm 
Offline
Joined: Fri Nov 04, 2005 7:11 am
Posts: 61
I have been using the following udev rules for my pvr-500 and hdpvr.

Code:
KERNEL=="video?", ATTR{name}=="Hauppauge HD PVR", SYMLINK+="video-HDPVR"
KERNEL=="video?", ATTR{name}=="ivtv0 encoder MPG", SYMLINK+="video-500a"       
KERNEL=="video?", ATTR{name}=="ivtv1 encoder MPG", SYMLINK+="video-500b"


Is there a change that needs to be made? Currently video0 is linked to the hdpvr, video1 is 500a and video2 is 500b.

_________________
BE: R8.4, HVR2250, MCE media center remote, GigaByte GA-EP43-UD3L, 2gb ram

FE: Linhes 8.4, Mythbuntu, Linux Mint DE


Top
 Profile  
 
PostPosted: Tue Aug 07, 2012 2:22 pm 
Offline
Joined: Mon Apr 10, 2006 3:48 pm
Posts: 997
Location: Lexington, Ky
All my paths sym links are "v4l/dev_name". As long your tuner paths in myth-setup are configured and found at those sym links you should be ok ...

Tim


Top
 Profile  
 
PostPosted: Fri Oct 05, 2012 9:22 pm 
Offline
Joined: Mon Jun 04, 2007 5:22 am
Posts: 6
Your problems with the fireware reloading is not uncommon since the last upgrade. Long thread here related to PVR350/500. http://www.mailinglistarchive.com/html/mythtv-users@mythtv.org/2012-09/msg01062.html.

I am having the same problem. About once every day or two since I did the 7.3 upgrade, the firmware fails and reloads; but after the reload, my recordings are all blank files. The script listed in the quoted post uses a heavy handed approach of monitoring the kernel logs for the crash message, then stops the backend, reloads the modules and restarts. Not written for linhes, so some paths are not correct. Working on changing the script right now as a temporary measure until I get a resolution.

The messages showing up in dmesg are:
2012-10-04T21:00:54.045587-03:00 linhes-be2 kernel: [88031.362033] ivtv1: Encoder has died : ivtv_serialized_open
2012-10-04T21:00:54.045609-03:00 linhes-be2 kernel: [88031.362036] ivtv1: Detected in ivtv_serialized_open that firmware had failed - Reloading
2012-10-04T21:00:54.952288-03:00 linhes-be2 kernel: [88032.288451] ivtv1: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
2012-10-04T21:00:55.155265-03:00 linhes-be2 kernel: [88032.491845] ivtv1: Firmware restart okay

My current firmware is from an install in Feb (thought is was Jan):
-rw-rw-r-- 1 root root 141200 Feb 18 2012 v4l-cx23418-apu.fw
-rw-rw-r-- 1 root root 158332 Feb 18 2012 v4l-cx23418-cpu.fw
-rw-rw-r-- 1 root root 16382 Feb 18 2012 v4l-cx23418-dig.fw
-rw-r--r-- 1 root root 262144 Nov 30 2010 v4l-cx2341x-dec.fw
-rw-r--r-- 1 root root 376836 Nov 30 2010 v4l-cx2341x-enc.fw
-rw-r--r-- 1 root root 155648 Nov 30 2010 v4l-cx2341x-init.mpg

My two cards (one dual tuner) are I believe a 500 and a 150.
03:05.0 Multimedia video controller: Internext Compression Inc iTVC16 (CX23416) MPEG-2 Encoder (rev 01)
03:06.0 PCI bridge: Hint Corp HB6 Universal PCI-PCI bridge (non-transparent mode) (rev 11)
04:08.0 Multimedia video controller: Internext Compression Inc iTVC16 (CX23416) MPEG-2 Encoder (rev 01)
04:09.0 Multimedia video controller: Internext Compression Inc iTVC16 (CX23416) MPEG-2 Encoder (rev 01)

I plan to try the latest firmware available. If that works, I will post back here.

Cheers,
-ed


Top
 Profile  
 
PostPosted: Mon Oct 08, 2012 10:19 pm 
Offline
Joined: Mon Jun 04, 2007 5:22 am
Posts: 6
Well, doing my first step of testing, and need to leave the system run 24-48 hours for it to fail. That seems to be about the time range.
I have downloaded the latest recommended firmware for my Hauppauge card. As I mentioned, I have a 150 and a 500 (which shows up as two 150’s); but that should still help the 350 users who use almost all of same files (plus one).
So I got my download from the main ivtv page. http://ivtvdriver.org/index.php/Download and just downloaded the firmware files. One of the files has been updated since I built the original system.
[
Code:
root@linhes-be2 ~]# dmesg | grep firmware
[    6.691118] ivtv0: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
[    6.706132] ivtv1: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
[    6.802478] ivtv2: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
[   11.107326] cx25840 8-0044: loaded v4l-cx25840.fw firmware (16382 bytes)
[   12.438405] cx25840 2-0044: loaded v4l-cx25840.fw firmware (16382 bytes)
[   12.770449] cx25840 1-0044: loaded v4l-cx25840.fw firmware (16382 bytes)

Code:
[root@linhes-be2 ~]# md5sum /lib/firmware/v4l-cx2*
7d3bb956dc9df0eafded2b56ba57cc42  /lib/firmware/v4l-cx231xx-avcore-01.fw
588f081b562f5c653a3db1ad8f65939a  /lib/firmware/v4l-cx23418-apu.fw
b6c7ed64bc44b1a6e0840adaeac39d79  /lib/firmware/v4l-cx23418-cpu.fw
95bc688d3e7599fd5800161e9971cc55  /lib/firmware/v4l-cx23418-dig.fw
305dba74bbe5905447add8883f3ecb68  /lib/firmware/v4l-cx2341x-dec.fw
305dba74bbe5905447add8883f3ecb68  /lib/firmware/v4l-cx2341x-dec.fw.old
9b39b3d3bba1ce2da40f82ef0c50ef48  /lib/firmware/v4l-cx2341x-enc.fw
9b39b3d3bba1ce2da40f82ef0c50ef48  /lib/firmware/v4l-cx2341x-enc.fw.old
0661f8b2693fe3123e6234557353eacc  /lib/firmware/v4l-cx2341x-init.mpg
a9f8f5d901a7fb42f552e1ee6384f3bb  /lib/firmware/v4l-cx23885-avcore-01.fw
1cb3c48a6684126f5e503a434f2d636b  /lib/firmware/v4l-cx23885-enc.fw
b3704908fd058485f3ef136941b2e513  /lib/firmware/v4l-cx25840.fw
dadb79e9904fc8af96e8111d9cb59320  /lib/firmware/v4l-cx25840.fw.old


Well that did not go well, less than 6 hours and it has crashed again.

I downloaded the current drivers from Hauppauge, but they do need to be renamed according to this page http://ivtvdriver.org/index.php/Firmware. I renamed the two .rom files, and I do get an error in the kernel messages, but otherwise things appear to be working.
Code:
[    6.865119] ivtv1: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
[    6.971023] ivtv0: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
[    6.971617] ivtv2: Loaded v4l-cx2341x-enc.fw firmware (376836 bytes)
[    7.065238] ivtv1: Encoder revision: 0x02050032
[    7.065240] ivtv1: Recommended firmware version is 0x02060039.
[    7.171242] ivtv2: Encoder revision: 0x02050032
[    7.171244] ivtv2: Recommended firmware version is 0x02060039.
[    7.178209] ivtv0: Encoder revision: 0x02050032
[    7.178210] ivtv0: Recommended firmware version is 0x02060039.


This page at ivtvdriver told me about the other driver files, http://ivtvdriver.org/index.php/Firmware_versions; but I was not able to download them there. I did find the 2.0.24.23025 version of the files at http://www.shspvr.com/ftp/download/wintv-pvr_150-500/inf/pvr_2.0.24.23025.zip. My md5sum on those files are:
Code:
5f5fa240ada73c3565f5f7de4c7b5138  /root/pvr20/v4l-cx2341x-enc.fw
3a4803384f749d644ee1f1ca9dcb12fa  /root/pvr20/v4l-cx25840.fw


Again, waiting to see if this firmware works better with the system.

Well that was a bust as well, still less than a day for failure.

Since the firmware has not worked. I have put this script in my cron.d/monitor_ivtv:
Code:
*/1 * * * *     root    /usr/bin/restarteverything.sh >> /tmp/restart_results.txt 2>&1

Here is he script which was referenced in previous post and now updated for linhes, I now have it loaded and will let you know if it properly restarts the devices:
Code:
##########################################################
#!/bin/bash

#This script will automate the reloading of the ivtv modules. It is rather heavy handed but due to
#issues with firmware failures in the ivtv module causing recording issues on my PVR-500 it was
#my last resort to prevent failed recordings. Note that this script must be run as root in order to
#be able to reload the ivtv module. As such it has full root privilege and should be used very
#carefully. While it works as intended on my debian system I cannot guarantee it will work as
#intended on your system. Please check all commands before using.

#Cron jobs start on the minute and so do myth recordings so wait 15 seconds
#for the problem to occur and be logged
/bin/sleep 15

#If we find an indication in the syslog that the ivtv driver has failed
if  /bin/grep "Encoder has died : ivtv_serialized_open" /var/log/dmesg.log ;  then

#Kill both frontend and backend so that we can unload the ivtv module

        #pkill mythfrontend
        #pkill mythbackend
        /sbin/sv restart mythbackend
        /sbin/sv restart frontend

#The ivtv module will not unload until the frontend and backend are stopped so
#rather than sleep for some arbitrary amount of time lets just try to unload

    #repeatedly until we succeed

        while ! /sbin/modprobe -vr ivtv ; do

        #Wait for a second

                /bin/sleep 1
                i=$(($i+1))

#See if we have tried more than 15 times indicating there is a real problem

                if [ $i -gt 15 ];then

         #In which case return an exit value of 1

                        exit 1
                fi
    #Otherwise try again
        done

    #Relax for a second

        /bin/sleep 1

#And reload the ivtv module the debug level is so that when someone tells

    #me what to look for my logs should have everything

        /sbin/modprobe -v ivtv debug=127

#We are moving the logfile to another file so that we can corelate the failures with
#Logs. the new file name is syslog.restart.n so check to see if n exists

        i=0
        while [ -e /var/log/dmesg.log.restart.$i ];do

        #and if so iterate until we find a good name

                i=$(($i+1))
        done

    #Save the syslog file

        mv /var/log/dmesg.log /var/log/dmesg.log.restart.$i

    #start a blank syslog

        touch /var/log/dmesg.log

    #restart the syslog daemon

         /sbin/sv restart rsyslog

        /bin/sleep 5

    #Restart the backend

        /sbin/sv restart mythbackend
        /sbin/sv restart frontend

fi


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 13 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 127 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu