rename KERNEL/SYSTEM boot files

  • from my boot manager (grub4dos) I currently have working:

    Code
    kernel /KERNEL boot=LABEL=flash disk=LABEL=storage quiet

    is there a way to tell the kernel to use a specific filename for SYSTEM? or even if I move SYSTEM to a subdirectory of the root directory?

    I know I saw a parameter to specify it either here or the OE forum at one time but don't recall what it was. Tried the forum search function as well.

    Code
    kernel /KERNEL <???> boot=LABEL=flash disk=LABEL=storage quiet

    my goal is to have in my root directory files renamed something like:

    Code
    KERNEL7.0.2
    SYSTEM7.0.2
    KERNEL8.2.2
    SYSTEM8.2.2

    then use different menu entries to boot different versions. or perhaps use the LE live parameter as part of a multiboot USB but have the files in an subdirectory of the root for tidyness.

    thanks,

  • thanks. this works:

    Code
    kernel /MYKERNEL BOOT_IMAGE=MYKERNEL SYSTEM_IMAGE=MYSYSTEM boot=LABEL=FLASH live quiet

    this does not:

    Code
    kernel /libreelec/KERNEL BOOT_IMAGE=/libreelec/KERNEL SYSTEM_IMAGE=/libreelec/SYSTEM boot=LABEL=FLASH live quiet

    what is the syntax for "path_to/KERNEL" and "path_to/SYSTEM" for the files in a subdirectory?

  • this works:

    Code
    kernel /MYKERNEL BOOT_IMAGE=MYKERNEL SYSTEM_IMAGE=MYSYSTEM boot=LABEL=FLASH live quiet

    subdirs do not:

    Code
    kernel /libreelec/KERNEL BOOT_IMAGE=/libreelec/KERNEL SYSTEM_IMAGE=/libreelec/SYSTEM boot=LABEL=FLASH progress debugging nosplash textmode

    produces this:

  • looking at "init" line 1029 "cp" will fail due to not creating the subdir "libreelec" under "/dev/" when copying, ie:

    Code
    cp /flash/$IMAGE_SYSTEM /dev/$IMAGE_SYSTEM
    cp /flash/libreelec/SYSTEM /dev/libreelec/SYSTEM

    maybe the "--parents" option would complete successfully, ie:

    Code
    cp --parents /flash/$IMAGE_SYSTEM /dev/$IMAGE_SYSTEM
    cp --parents /flash/libreelec/SYSTEM /dev/libreelec/SYSTEM
  • I don't suppose modification of the code could be considered a "feature request?"

    :/

    I can't answer that. It is easy change which doesn't affect anything else so I would say yes. But other has to say that. Maybe chewitt ?

    Does with noram and subfolder works? Because if not then there are more changes needed.

  • if I wanted to make the change myself, where is the location of "init", KERNEL or SYSTEM?

    to make the change is it the process of unsquash SYSTEM and resquash?

    how would I go about modifying KERNEL, "file KERNEL" returns "x86 boot sector"? recompile? /:

  • Just change init file packages/sysutils/busybox/scripts/init and build the image. It would be easier than changing initramfs in kernel.

    And if works with noram then just use this option. This option just disables copying SYSTEM file to ram and mounting from there instead of hdd or sd card or usb stick. Maybe there is very, very small performance hit but you will not notice it anyway.