[mythtv-users] Diskless Front End (again)

Rich West Rich.West at wesmo.com
Wed May 2 15:22:12 UTC 2007


Neil Sedger wrote:
> Rich West wrote:
>> Neil Sedger wrote:
>> The only noise it generates is in regard to it being unable to write to
>> fstab.
>>
>> I guess I will have to dig in to that disklessrc startup script to see
>> where it might be failing..
>
> ...having upgraded my diskless from FC3 to FC6, I now have the same
> problem!
>
> A good google around - as the issues are due to RedHat's
> system-config-netboot - didn't help much until I came across the
> diskless page on the mythtv wiki:
> http://www.mythtv.org/wiki/index.php/Diskless_Frontend#Creating_the_boot_images
>
> See the bit about issues with system-config-netboot for FC5 and FC6.
>
> Firstly, the initrd does not contain 'mount.nfs' which is kinda useful
> for netboot systems... I suspect you've got past this point though as
> your root and snapshot mount, just read-only...
> Secondly, newer kernels will not mount an nfs share rw when another
> share from the same server is already mounted ro.
> See http://lkml.org/lkml/2006/10/18/264 for explanation.
> I am hoping that the 'mount -o remount,rw /.snapshot &&' bit in the
> wiki addresses this issue, this is where I'm at.
>
> Mine also spouts errors because it cannot write to mtab (not fstab)
> when it tries to mount the snapshot because /etc/mtab is on the ro
> filesystem at that point. I've edited my disklessrc to include switch
> '-n' to the mount command, which skips writing to mtab. Don't know why
> this behaviour is different between FC3 and FC6...
> An alternative might be to remove (rename just in case...) /etc/mtab
> and instead symlink it to /proc/mounts. I don't think you can do this
> with fstab, but I don't know why it should be writing to fstab on boot
> anyway?
>
>
>
> Aside from all this, how are you supposed to update a working system?
> You can't use rpm/yum on the diskless box because the root filesystem
> is readonly, and you can't just chroot and run them on the server as
> this does not take account of all the files in the 'snapshot' dir
> which get mounted all over the place.

(I meant to send this to the list, and, instead sent it to the poster
directly)

Thanks for the update.  I mis-spoke when I typed "fstab".  The error I
was getting was on "mtab".  Yes, I added mount.nfs to the initrd image,
and I updated disklessrc via the mount -o remount... command.  I didn't
do the -n trick, though... I'll give that a try.

My understanding is that the idea is supposed to be that you have one
_generic_ image for your hosts, and the configuration files are the ones
that are symbolically linked off to the individual snapshots for each of
the hosts.  This way, you just have one image to deal with, and, when
you do updates, you do them via the server and chroot to the diskless
environment (as you said).  The configuration files will get updated,
but only in the image.  The snapshot files will get mounted over top of
the image's configuration files upon boot up.  This way, you can update
all of your diskless clients at one time.

Of course, you are not limited to one image.. you can have multiple. 
But with one image, the management (and disk space) are kept to a minimum.

Now, that's the way it is supposed to work.  I haven't gotten to the
point where the snapshot is getting mounted on top of the existing files
(that's via pivot_root or something, if I remember correctly).

I gave up on this a little while back because I just couldn't get it to
work.  I left everything in place, though, in the event that new
information came along and I could easily start up where I left off.  I
do tinker with it every week or so to see if I can make any progress
because my other half keeps asking me to make the systems quieter. So,
with this info, I will probably give it another shot tonight. :)

-Rich




More information about the mythtv-users mailing list