Page 1 of 3
IFL log file
Posted: Wed Dec 04, 2024 9:17 pm
by tbifan39
I am using Image For Linux v4.03. I am using Easy2Boot to boot the iso from a flash drive. I would like to have a log file created on the flash drive. Is this possible? Hoe do I file out the drive and path of the flash drive?
Re: IFL log file
Posted: Thu Dec 05, 2024 2:13 am
by TeraByte Support
if you mount it and then point the /logfile to that mount point. See
https://www.terabyteunlimited.com/kb/kb ... boot-disk/
Re: IFL log file
Posted: Thu Dec 05, 2024 10:16 am
by tbifan39
Okay... I figured out how to mount partition using Terminal. I created a script and named it logfile, I copied it to the script folder. I selected the option to run script from folder. It is the only script in the folder,
I run IFL from the usb flash drive. The script does not run; and it is not shown in the script menu. I tested the iso using QEMU and when I boot from QEMU, the script is shown. I am booting iso; not the flash drive.
I am able to mount the partition manually from IFL using Termial or the mount option in the menu.
this is the contents of logfile script (blank line included)
#! /bin/bash
mount /dev/sdb2 /tbu/mnt1
Re: IFL log file
Posted: Thu Dec 05, 2024 3:30 pm
by TeraByte Support
you'll need to rebuild the ISO with the script.
Re: IFL log file
Posted: Fri Dec 06, 2024 1:17 am
by tbifan39
i did rebuild the iso. I used makedisk utility I selected script from folder option and put the script in the folder
Re: IFL log file
Posted: Fri Dec 06, 2024 2:02 am
by TeraByte Support
does it exist when booting?
Re: IFL log file
Posted: Fri Dec 06, 2024 4:49 am
by tbifan39
I tested the iso using qemu and the script appears in the script menu
However, when i boot the my system with the iso using easy2boot, the script does not appear in the menu. I can mount the drive manually after IFL loads, I do not know if you have heard of easy2boot. It is a program that allows you to boot many iso on a flash drive; like YUMI.
It is probably the way easy2boot is handling the iso that is preventing the script from loading. Maybe some has the same problem and know of a fix.
The iso works fine, other than the scripting not loading. The reason I am mounting the partition is so I can save the log file to the flash drive.
Re: IFL log file
Posted: Fri Dec 06, 2024 5:13 am
by TeraByte Support
The iso booting type software typically implement a hook in the the legacy BIOS interface which early iso booting code uses to read the disc. It can be done via loading to memory (remapping BIOS memory map) and reading from there or reading the actual file from the media. Once protected mode OS loads, they won't be able to find anything (unless os boot code is hacked) in an ISO like they could an actual disc so not all OSes can boot fully in such cases.
The IFL boot disk init script, IIRC, is looking for the disc to find the scripts folder since the script isn't in the kernel image. FWIW, makedisk.cfg injects items like firmware in the kernel image via |initrmfs.
Re: IFL log file
Posted: Fri Dec 06, 2024 5:32 am
by tbifan39
Well I guess I will just have to mount the partition manually or just not use the log. Maybe someone will figure out a fix.
is there a way to inject the script in the kernel?
I was looking at the makedisk.cfg and saw these lines.
ADD0=:*.*,>\
ADD1=scripts\*.*,>\scripts
ADD2=firmware\*.*,>/lib/firmware/|initrmfs
Re: IFL log file
Posted: Sat Dec 07, 2024 8:45 am
by TeraByte Support(PP)
You could try changing ADD1 to the following and recreate the ISO:
Code: Select all
ADD1=scripts\*.*,>/tbu/scripts/|initrmfs
After booting you can look in the /tbu/scripts folder and see if they're there. Note that if you change this the scripts won't be in the scripts folder of the boot media, but, in your case, you don't need them there.