Has extlinux (the binary file) been removed for LE 9.0 ?

  • In my old LE 8.x setup I used a modified "boot once to other OS" script packaged into a Kodi addon to enable me to run the addon from GUI and select which OS to run on next boot.

    The relevant core of it was thus e.g.:

    Bash
    #!/bin/bash
    
    mount -o rw,remount /flash
    extlinux -o "windows" /flash
    reboot

    ... which would use the extlinux -o option to set a one-time flag to select a different boot entry from extlnux.conf (either Windows on another partition or PartitionMagic from a live squashFS) for next restart, then revert to default (LibreELEC) on subsequent restart.

    In LE 9.0 this just generates a `not found` error since there isn't an extlinux binary anywhere in the search path.


    So ... my questions are:-

    1. Has the sylinux/extlinux implementation changed from LE8.x to 9.x and I'm just too dim to find it in GitHub commits ?
    2. Or ... did I do something myself to install an extlinux executable some time back in the distant past that I've simply forgotten about, which I need to do again for the current LE build ?

    If it's option 1, is there some slightly different way this desired "change boot option one time" functionality can work with the present syslinux executable ?

    or

    If it's option 2 then I'll leave you in peace and wander off to try and recreate whatever the hell it was I did in the past ?(

  • The syslinux executable uses the -o option for a different purpose.

    Quote

    5. EXTLINUX has "boot-once" support. The boot-once information is stored in an on-disk datastructure, part of ldlinux.sys, called the "Auxillary Data Vector". The Auxilliary Data Vector is also available to c32 modules that want to store small amounts of information.

    To set the boot-once information:

    Code
    extlinux -o 'command' /boot/extlinux

    where "command" is any command you could enter at the Syslinux command line, preferably a label. The boot-once information will be executed on the next boot and then erased.

    Quote

    2. SYSLINUX

    For older versions (deprecated):

    -o Specify the byte offset of the filesystem image in the target "device".

    The offset option is applicable only when the target device is a disk image file.

    There *is* a "--once=... Execute a command once upon boot" flag for syslinux but I can't seem to work out the syntax of how to utilise it to achieve the same result

  • Yeah - that must have been what I did before, back in the dim and distant past.

    Maybe I had stored the extlinux binary somewhere that got replaced/wiped by the LE9.0 upgrade. *shrug*

    Anyway - it's all working now and problem solved after I installed the extlinux binary I extracted from a Debian package. 8)

    (There was a bit of puzzlement when I couldn't get the binary from the official Syslinux Project download hosted at kernel.org to run ... till I realised that binary was built against 32bit libraries - hence the trip to Debian to grab their pre-compiled 64bit .deb version)