Add support for version update on netboot

  • When the "boot" argument on cmdline.txt points to ISCSI, NBD or NFS, then updates are not supported and the file "/dev/.update_disabled" is created.

    What is the reason for this? If done properly, a networked boot should be upgradable.

    Please, add an option to cmdline.txt for allowing upgrades when using a networked boot.

  • Netbooting is used by a microscopic percentage of our total users, and zero project staff. As long as we continue to receive the occasional "it still works" post when we make major changes there's no reason for us to remove netboot support, but we're equally not looking to expand support. Sorry.

  • My setup is described here: RE: LibreELEC v9 RPI3 PXE

    For updates, I just do this:

    Download the image for my Raspi, create an update directory and move the image in the new directory:

    Code
    root:/nfs/Raspi# wget http://releases.libreelec.tv/LibreELEC-RPi2.arm-9.2.7.img
    root:/nfs/Raspi# mkdir -p upd/p1
    root:/nfs/Raspi# mv LibreELEC-RPi2.arm-9.2.7.img upd/p1
    root:/nfs/Raspi# 

    Mount the first partition of the image:

    Code
    root:/nfs/Raspi# mount $(losetup --show -r -f -P upd/LibreELEC-RPi2.arm-9.2.7.img)p1 upd/p1
    mount: /nfs/Raspi/upd/p1: WARNING: device write-protected, mounted read-only.
    root:/nfs/Raspi# 

    Overwrite the SYSTEM over my old one

    Code
    root:/nfs/Raspi# cp -vax upd/p1/SYSTEM 3X84XbXf.boot/SYSTEM
    'upd/p1/SYSTEM' -> '3X84XbXf.boot/SYSTEM'
    root:/nfs/Raspi#

    Overwrite the rest to the tftpboot directory:

    Code
    root:/nfs/Raspi# rsync -av upd/p1/* /var/lib/tftpboot/3X84XbXf/ --exclude SYSTEM* --exclude cmdline.txt --exclude config.txt
    root:/nfs/Raspi#

    Clean up

    Code
    root@ruet-ch-ars01-lin01:/nfs/Raspi# umount upd/p1
    root@ruet-ch-ars01-lin01:/nfs/Raspi# losetup|grep LibreELEC-RPi2.arm-9.2.7.img
    /dev/loop2         0      0         0  1 /nfs/Raspi/upd/LibreELEC-RPi2.arm-9.2.7.img   0     512
    root@ruet-ch-ars01-lin01:/nfs/Raspi# losetup -d /dev/loop2
    root@ruet-ch-ars01-lin01:/nfs/Raspi# rm -fr upd
    root@ruet-ch-ars01-lin01:/nfs/Raspi#

    Well done :)