Bringing up MiniMyth on an EPIA M10000 using wireless


I'm finally getting back to using my Epia M10000 board as a MythTV frontend.  The goal here is to configure it to run with a CF card for booting and a wireless card to communicate with the backend, and use the TV-output connected to our TV in the living room.  Long ago I started out on this project using a small system called MiniMyth, which essentially network boots the board to run it as a diskless frontend.  I then migrated to rolling my own distribution using the steps outlined by the Linux From Scratch project.

Well, life gets busy and the best laid plans don't always work out.  I'm now back on this project and have found that MiniMyth has evolved a bit since I last used it.  Enough so that I can now muck with it enough to try and get the one missing piece added to it:  wireless networking via the MadWifi drivers.

MiniMyth is designed with two boot options and two root filesystem options.  The boot options are either local, as from a hard disk or CF card, or network boot via PXE.  The root filesystem options are either run from RAM or run from an nfs mounted root partition.  To get back into this project I started with the simplest mechanism to set up:  PXE booting with an NFS root filesystem.  This setup will allow me to peruse the runtime system manually to see how it was built and how I might go about adding in the wifi drivers.  Setting up for booting from PXE is fairly straight forward.  You'll need to install the DHCP and TFTP servers (the latter requires xinetd to also be installed) on your boot server.  My boot server happens to be the same system running my mythtv backend.  You'll need to make sure you configure your minimyth.conf file, which needs to be stored in your TFTPBOOT/conf/minimyth directory, where TFTPBOOT is the root directory for your TFTP server.

While your debugging your configuration you should know some things that the MiniMyth site doesn't mention.  First is that the network booted frontend has a telnet server installled.  If you want to login to it and look around after it boots up, then telnet to the box and use the userid "root" (no password).  Note that MiniMyth is NOT secure.  It's not intended to be publicly accessible.  It should only be accessible on your local network at home and safely behind a well configured firewall.

Another thing to note is that there is an extra script you can write that MiniMyth will download from the same directory as your minimyth.conf file.  This file is called minimyth.script and should be written as an ordinary shell script.  The online docs at the MiniMyth project suggest that if you use this script to manually mount remote directories you should use a functions file called /etc/minimyth.d/minimyth.functions, but that doesn't exist at boot time.  More than likely this has been changed to /etc/rc.d/functions.  For mounting remote directories on the MiniMyth box you use a function called mm_url_mount, which also differs from the online documentation (which says to use mount_url). 

I have all video related files saved under /store on the MythTV backend and music under /music.  I export these two directories via NFS.  In order for my MiniMyth box to use these, I configure the following variables in my minimyth.conf file:

MM_MYTHMUSIC_MOUNTPOINT='/music'
MM_MYTHMUSIC_URL='nfs://192.168.1.101/music'
MM_MYTHVIDEO_MOUNTPOINT='/store'
MM_MYTHVIDEO_URL='nfs://192.168.1.101/store'

To verify these settings are in place, I telnet in after the Minimyth box boots and check to see that /store and /music exist on the box and that the remote NFS server is mounted there correctly.

So far everything is working using the netboot w/NFS configuration except that videos are not playing yet.  I believe this to be a problem with the way the video players are configured.  I'll be testing that shortly.

The next step after verifying everything is working as expected using the netboot/NFS configuration is to move to a local boot configuration on the CF card.  I'm also working, at the same time, on trying to build Minimyth from source (a metabuild based on GAR).  Once the local boot and build-from-source are working, then work can begin on determining how best to integrate the MadWiFi drivers.  I don't expect this to be particularly difficult other than learning the structure and usage of the GAR-based build system.

One thing I noticed while getting started with compiling Minimyth from source:  on fedora 7 the default compiler is found using a package called ccache, which is used to speed startup of the compiler.  That means "type gcc" (which lists the location of gcc under BASH) will report "/usr/lib/ccache/gcc".  That doesn't work for the Minimyth build – it dies when it tries to build a package called gmp, which is a dependency for building the Minimyth gcc.  To get around that you simply start the build by explicitly setting the CC environment variable, such as:

make CC=/usr/bin/gcc build