[mythtv-users] Best options/howto for diskless frontends

Paul Gardiner lists at glidos.net
Thu Feb 21 19:44:31 UTC 2013


On 26/11/2012 09:33, Per Jessen wrote:
> Paul Gardiner wrote:
>
>> My hopes are (anyone of which can be dropped if it simplifies things):
>>
>> 1) Not to have to add a disk to my Zotac ION.
>
> You can boot with root on NFS.
>
>> 2) To use opensuse because it's the linux I best know.
>
> I have servers on openSUSE that boot with root on NFS, it works.  I had
> to generate the initrd separately though.
>
>> 3) To do the initial install actually on the diskless machine,
>> so that I get as much automatic config as possible.
>
> I think that means hooking up a drive first, then installing, then
> copying the filesystem to your NFS-server.  I don't think I've ever
> tried installing straight onto NFS.
>
>> 4) To be able to switch off the diskless machine without
>> shutting down.
>
> So suspend?  Yes, I've been meaning to look into that too.
>
>> I have dhcp/pxe/tftp already set up on my opensuse server/backend
>> already, so it should be just a case of altering that.
>
> This is from one my pxe config files:
>
> append initrd=<your-initrd> root=/dev/nfs rw
> nfsroot=192.168.2.170:/var/pifs/stork1/root
> rootflags=hard,intr,v3,wsize=8192,rsize=8192
>
> You need NFS v3 because the suse initrd does not work with NFS v4 for
> booting.

At last, I've found time to try this, but I've run into a brick wall. I
installed a minimal opensuse 12.2 with mythtv, plus all that's needed
to build mythtv, all on a spare harddrive I had lying around. Works
great, but it's getting it to work via NFS that's troubling me.

I ran "mkinitrd -k vmlinuz -i initrdnfs -f nfs -D eth0 -B" and copied
the result plus the kernel to my server's tftp directory.

I already had tftp and pxe set up because of minimyth so that wasn't a
problem.

I copied all the installed files to a directory on my server
using rsync -ravzx. The x option avoids descending into mount points,
so things like proc and dev are empty directories.

I exported that with nfs options rw,no_all_squash,no_root_squash.

I put the following in the pxelinux.cfg file:

DEFAULT clunk-nfs

LABEL clunk-nfs
            KERNEL clunk/vmlinuz
            APPEND initrd=clunk/initrd init=/bin/systemd root=/dev/nfs 
rw nfsroot=10.0.0.5:/home/clunk rootflags=hard,intr,v3,wsize=8192,rsize=8192

[also tried init=/bin/init and leaving it out completely]

It tries very hard to work. The boot gets past the nfs mount stage and
gets some way through the init, but then it just stops. No shell prompt,
and I can't ssh in, so it's difficult to tell where it went wrong. 
Here's a photo of the screen:
http://intranet.glidos.net/~paul/boot-failure.jpg.

On the server side, I can see three
successful dhcp runs, with a tftp access between first and second, and
an nfs mount between second and third. I feel like it's close, but I'm
out of ideas what to try to get it the rest of the way.

Anything you can think off that I've missed?

Cheers,
	Paul.


More information about the mythtv-users mailing list