Difference between revisions of "User:Mehall@itfysb.com/Upgrading from 0.20.0 to 0.20.2 on Fedora Core 6 from rpms"

From MythTV Official Wiki
Jump to: navigation, search
m
(Restart the backend)
Line 94: Line 94:
  
 
=== Restart the backend ===
 
=== Restart the backend ===
<pre># /sbin/service mythbackend ''[re]''start</pre>
+
<pre># /sbin/service mythbackend restart</pre>
  
 
=== Restart the front end ===
 
=== Restart the front end ===

Revision as of 03:20, 28 August 2007

This is the technique I used when upgrading my FC6 system from 0.20.0 to 0.20.2. I do not provide any information about updating the MythTV settings, because that's documented many other places. I'm doing this for people that may or may not have much Linux experience, and this can help you do the upgrade as quickly and easily as possible. I am not documenting how to do it here, but I'm using the ATrpms repository.

The basic configuration of my system is a 160 MB disk running LVM2, a Hauppage PVR-150 as tuner 1, a PVR-350 as tuner 2, and using the PVR-350 as my video out. -- Mehall

  • WARNING -- There is some risk to this upgrade of the kernel. As with any kernel change, it is possible to completely prevent the system from booting. Even having another kernel version installed does not completely guarantee that it will still boot.

Prepare for upgrade

The upgrade process was pretty straightforward. Make sure the system is working completely before doing this upgrade, otherwise problem determination becomes more tricky - what's new, what's old? Is that the same problem?

Locate recovery media

Find the FC6 rescue CDROM Image. (If you experience any module issues as I had, it can prevent you from being able to even get to single user mode. Trust me on this one. I do Linux for a living. --mehall) Having it before starting beats having to spend 2 hours looking for it or downloading a new one.

Stop the running software

Stop the backend and disable the frontend restart for troubleshooting later. This is important to ensure that nothing gets corrupted.

# /sbin/service mythbackend stop
# touch /home/mythtv/nogui

This prevents X from restarting in a login script in /home/mythtv/.bashrc:

if [ -z "$DISPLAY" -a "$(tty)" = "/dev/tty7" ]
then
        while [ 1 = 1 ]
        do
                if [ ! -f ~/nogui ]
                then
                        startx
                fi
                sleep 10
        done
fi

Exit the mythfrontend at some point. Since the next process took a while, this is a good time to listen to music through the frontend for a while.

Back up the database

# mysqldump -p mythconverg > mythconverg.db.020.0

(Wondering what the -p flag is? it's prompt for password. Oh, you DID set a password on your root account's db access, right!?? If not, um... do it. Soon. Maybe even now.)

Document your current system software

Get a list of the current software to ensure getting back to the exact current versions is possible The filename isn't so important, just so long know what it is later if needed.

# rpm -qa > /root/myth_system_packages_pre_update

Upgrading the system

Yum is your best friend. No really. Unless upgrading to a version a little before the most recent. There's a way to avoid that, just specify the exact version to upgrade to. So, there's a few packages that must be upgraded to specific versions, and then the rest of the system updates itself.

Updating the kernal

Update the Kernel to 2.6.22.1-32.fc6

# yum install kernel-2.6.22.1-32.fc6.i686.rpm

Update the iviv kernel modules (drivers)

Update the ivtv-kmdl to 2.6.22.1-32.fc6-1.0.1-133.fc6

# yum install ivtv-kmdl-2.6.22.1-32.fc6-1.0.1-133.fc6.i686.rpm

Update the ivtv package

Update ivtv to 1.0.1-133.fc6

# yum install ivtv-1.0.1-133.fc6.i386.rpm

Update the alsa kernel modules

Update alsa-kmdl to 2.6.22.1-32.fc6

# yum install alsa-kmdl-2.6.22.1-32.fc6.i686.rpm

=== Update the lirc package's kernel modules ===
Update lirc-kmdl to 2.6.22.1-32.fc6
<pre># yum install lirc-kmdl-2.6.22.1-32.fc6.i686.rpm

=== Updating the rest of the system ===
This step is very important. If you do not exclude the packages we just upgraded, yum will attempt to upgrade them to higher revisions which may not match the kernel versions you have available. If you need to use a different kernel version, make sure that anything here that says <code>2.6.22-1.32</code> is replaced by your kernel version. If any of these packages fail, your hardware will not do what you want, which is record TV.
<pre># yum --exclude=kernel --exclude=ivtv --exclude=ivtv-kmdl --exclude=alsa-kmdl --exclude=lirc-kmdl update

Notice that I have not used the -y flag. This way, if something that undesirable attempts to upgrade, back out is still an easy option. Go get a drink or something while this step is running. It will take a while to build the dependency tree (mine took 5-10 minutes), and the next phase will take even longer - about 1 to 2 hours to downloading all the packages.

Reboot the system to move to the new kernel versions

Several pieces of documentation indicate that the system should be shut down for at least 30 seconds to allow the registers to clear on the PVR-x50 cards.

# shutdown -h now

After the Upgrade

Now that the upgrade is 'finished', it should be safe to do a few other important steps.

Shut down the backend again

# /sbin/service mythbackend stop

Run the MythTV setup

Update the channel listings according to other MythTV documentation.

Double check functionality

Verify that the hardware is still functioning correctly.

# dd if=/dev/video''0'' of=/dev/video''16'' bs=64k

Is there video on the TV? If so, good.

# startx

Did X start up the MythTV front end? If so, excellent. Shut that back down again.

Restart the backend

# /sbin/service mythbackend restart

Restart the front end

# rm /home/mythtv/nogui

Test all functions

This is a good time to verify system functionality. View recordings. Watch live TV. Change channels. Do other normal functions routinely used. If all is good, have a frosty cold beverage [Thanks Dave (Letterman)] and enjoy a little TV.

There may be some other issues with respect to settings for ivtv options and/or other modules depending on how the hardware was originally configured. If the hardware was well configured, there shouldn't be many issues. For instance, the video4linux-kmdl package was not installed on mehall's system. Installing it corrupted other kernel modules. Ensure that packages which aren't currently installed aren't installed afterwards. Installing different packages may introduce other unexpected changes. The reboot after reconfiguring x due to some kernel module differences resulted in repeating kernel panic. After booting via the Recovery CD and then removing the video4linux-kmdl modules, another unsuccessful reboot announced problems. After attempting recovery again and then removing ivtv-kmdl and ivtv, followed by another reboot, the system was operational but without video services. Mythbackend started and was unaware of any upcoming recordings causing this author to panic worse than the kernel. After reinstalling ivtv and ivtv-kmdl and another reboot, MythWeb indicated upcoming recordings and all was well. With some luck, these problems will be unique.