Moving a MythTV Master backend

This proved to be a whole lot easier than I thought. It required backing up the mythconverg MySQL database on the old system and restoring it on the new one.

   ~ /usr/share/mythtv/mythconverg_backup.pl
   ~ /usr/share/mythtv/mythconverg_restore.pl --filename mythconverg-VERSION-TIMESTAMP.sql.gz

A further step was needed to update the hostname of existing recordings to the new host.

   mysql> update 'recorded' set hostname='peeves' where hostname<>'peeves'

This machine became the frontend at the same time. The i3 GPU support was included in the xf86-video-intel driver from version 2.10. I ended up using 2.11 which had just become available and added the following entry to /etc/portage/package.keywords.

   =x11-drivers/xf86-video-intel-2.11.0 ~x86

posted by James Gemmell on Sun, 29 Aug 2010 at 12:13 | permalink | tags: gentoo, linux, mythtv

Building a new Gentoo MythTV backend

After a few of years of fairly intensive use I am migrating a MythTV backend from a rather creaky and increasingly unstable Pentium 4 to a shiny new Core i3 530 based box. I was quite impressed with Phoronix's Linux benchmarks of the CPU. The performance of the integrated GPU will help too since this box is destined to run an HD frontend at some point.

It's been a while since I last set up a Gentoo box from scratch and thought I'd give the Gentoo Quick Install a go rather than the LiveCD. The i3's Hyper-Threading support meant that the boot was graced with a 4 penguin salute and I was pleasantly surprised by the performance.

When partitioning the 1TB drive I settled on the following layout, setting aside /dev/sda5 as a future amd64 root partition.

   /dev/sda1	/boot		256MB	ext2
   /dev/sda2	swap		2GB	swap
   /dev/sda3	/		100GB	ext3
   /dev/sda5	[amd64]		100GB	ext3
   /dev/sda6	/mnt/mythtv	729GB	xfs

I diverged from the install guide in a few places. When the gentoo-sources kernel download threatened to take more than a couple of hours I performed the mirror-select step early and portage pulled it from a local mirror. I prefer using genkernel and, setting MAKEOPTS="-j5", this and the emerge world steps took next to no time.

The backend is now up and recording and the next step is to promote it to master backend status and get the frontend working.

posted by James Gemmell on Tue, 20 Apr 2010 at 09:17 | permalink | tags: gentoo, linux, mythtv

Upgrading Gentoo MythTV to 0.22

I recently upgraded a frontend to Mythbuntu 9.10 and got MythTV 0.22 as part of the deal. Rather than leap through the fiery hoops required to revert it back to 0.21 I decided to take the plunge and upgrade my other Gentoo-based MythTV backend and frontends to 0.22.

This was trouble free as upgrades go but I did encounter the UTF8/latin1 database encoding problem which requires a backup and restore of the MythTV database after changing the default encoding to latin1. Changing the MySQL server configuration is easy to do on Gentoo as all that is required is to rebuild MySQL with the latin1 USE flag.

My package.keywords now looks as follows;

   >=media-tv/mythtv-0.22 ~x86
   >=media-plugins/mythcontrols-0.22 ~x86
   >=media-plugins/mythgallery-0.22 ~x86
   >=media-plugins/mythmusic-0.22 ~x86
   >=media-plugins/mythvideo-0.22 ~x86
   >=www-apps/mythweb-0.22 ~x86
   >=dev-python/imdbpy-3.8 ~x86
   >=x11-themes/mythtv-themes-0.22 ~x86
   >=x11-themes/mythtv-themes-extra-0.22 ~x86

and my package.use has;

   dev-db/mysql latin1

posted by James Gemmell on Mon, 28 Dec 2009 at 10:36 | permalink | tags: gentoo, linux, mythtv

DTV1000S Linux driver now working

Top of my todo list for some time now has been to get my Leadtek WinFast DTV1000S DVB-T capture card to pay its way on a Gentoo MythTV backend instead of gathering dust on the shelf.

Video4Linux (V4L) drivers exist for the individual DTV1000S components listed below as they have also been used in other DVB cards.

What was lacking was the support for the card. I made an unsuccessful attempt at putting it together at the beginning of the year. Now Michael Krufky has done all the heavy lifting and committed his changes.

The easiest way to incorporate these into the 2.6.30-r8 kernel was to follow the V4L build instructions. Revision 13263 has all the necessary changes.

hg clone http://linuxtv.org/hg/v4l-dvb
cd v4l-dvb
make
sudo make install

I've not tested the IR capabilities of the DTV1000S as I'm using an AverTV DVB-T 777 for that purpose.

I used Steven Toth's instructions to get the TDA10048 firmware drivers from http://steventoth.net/linux/hvr1700/ and followed the readme.txt. Hat tip to Terry for his Leadtek product page.

posted by James Gemmell on Sun, 29 Nov 2009 at 10:17 | permalink | tags: gentoo, linux, mythtv

Gentoo Linux on the Dell Latitude C400

This guide started off some time after I upgraded the 10Gb drive on the C400 to an 80Gb Hitachi and replaced the Debian installation. Gentoo has a wealth of documentation so this is intended as an installation specific supplement.

Disclaimer: This document comes with no guarantees. The steps I followed worked for me but may not necessarily work for you or your hardware.

Configuration

Gentoo
linux-2.6.18-suspend2-r1 kernel
no Windows installation
PIII-M 866MHz CPU
768 Mb RAM (256Mb + 512Mb)
A12 BIOS
Crystal 4205 audio
3c905C-TX FastEthernet adapter (built-in)
80Gb 5400rpm Hitachi 5K80
TrueMobile 1150 wireless (disabled)
Netgear MA401 PCMCIA adapter
Netgear WAG511 PCMCIA adapter

Post-install

genkernel

Thinking the genkernel built kernels to be a little bloated I resorted to using the more traditional make menuconfig and make bzlilo. After much fiddling, recompiling & rebooting every time I needed another driver it was time to give genkernel another shot. I was pleasantly surprised - it actually built most of what I needed! I'm now a genkernel convert.

Custom settings are as follows:

CONFIG_ACPI
is not set
CONFIG_APM
= y
CONFIG_USB_KBD
= m
CONFIG_USB_MOUSE
= m

Xorg

Xorg has replaced XFree86 as the default X server and the Intel i830 chipset is supported out of the box with no extra configuration required.

Starting from an upgrade to Modular Xorg (6.9?) there seems to be a problem with repainting the screen correctly after an APM suspend/resume. I haven't yet taken the time to find out exactly what is at fault but am using suspend2 instead.

i8kutils

The i8kutils package is a collection of tools which can control various Dell specific functionality such as the fan(s) and custom keyboard buttons when used in conjunction with the i8k kernel module. They were initially created for the Inspiron 8000 series but will work with most other Dell laptops. A list is provided in the package.

The module is compiled by default and installed at startup by adding it to the list in /etc/modules.autoload.d/kernel-2.6.

Some other very useful utilities are i810switch and i810rotate from the app-misc/i810switch package which do a better job of switching to an external display than Fn-F8.

Sound

emerge alsa-drivers followed by alsaconf

Wireless network

The factory installed TrueMobile 1150 wireless mini-PCI card tends to lock up following a suspend/resume so I reverted to using an old Netgear MA401 PCMCIA card with the hostap drivers. This driver is WPA capable using wpa_supplicant but that is a work in progress.

The Netgear WAG511 is an Atheros based 802.11a/b/g card which uses the madwifi-ng drivers. A Gentoo package is available but I've stuck to the recommended method of using the subversion source for now. I'm having some problems getting this code to compile with the suspend2-sources but that, too, is a work in progress.

USB

USB on the C400 does not work properly after a suspend to ram and resume. For some time I assumed this was a kernel problem that would eventually be resolved but as my USB usage increased and the drivers improved through 2.6 it begged the question that perhaps the C400 hardware or BIOS was at fault (surely not!)

I eventually got around to re-installing the original supplied W2K on my now defunct 10Gb Toshiba disk and lo! USB failed to work after standby/resume. A quick perusal of the Dell support forums (very useful) has confirmed this to be an issue going back some years to the A08 or A09 BIOS upgrades and Dell (bless them) have not yet stepped forward with a fix.

It is not all bad news though. The workaround is to suspend to disk (hibernate) and then resume and voila - all is well with USB. Not an ideal solution but it works. It has meant though that I get my feet wet with suspend2.

suspend2

This was refreshingly easy to set up using suspend2-sources instead of gentoo-sources for genkernel and following the instructions in the HOWTO. I use a 1000Mb /suspend_file instead of a partition.

Memory Upgrade

The memory upgrade was interesting. The 512Mb SODIMM was bought from Crucial Technology. I tried installing it in the expansion slot under the inspection hatch underneath the C400. The boot failed to recognise the extra memory claiming some sort of parity failure.

I reseated the SODIMM and ended up with a unsupported memory error. Thinking this to be some sort of peculiar SODIMM ordering problem I switched the modules around. This is not a straightforward process and required some disassembly. The Dell User Guide proved quite useful. Switching the 256Mb and 512Mb SODIMMs around worked and I now have a full 768Mb.

While compiling this web page I was unable to remember the exact error messages so I opened the C400 up again and switched the SODIMMs back only to find that everything still worked. I can only conclude that the original problem must have been due to dirty contacts in the memory expansion slot which only really cleared up after reseating the SODIMMs.

Ongoing

IrDA

Not used now that I have a Sony Ericsson V600 with a USB cable.

PCTel Modem

I've no real requirement for this and have removed it. Try the latest PCTel drivers and their instructions.

Fn-Z

The infamous all-fans-on mode is well documented on the linux-dell-laptops mailing list. Also noticed after the upgrade to A04 and persisting in A12. This afflicts a number of different laptop models. Occasionally, after a resume from standby, the indicated CPU temperature will shoot up to 85 and the single fan will spin at full speed. All that is required is to simply reset the on-chip temperature sensor using Fn-Z.

posted by James Gemmell on Wed, 24 May 2006 at 17:09 | permalink | tags: gentoo, laptop, linux