Running Image for Linux Without a Boot Disk
To run Image for Linux (IFL), you would
normally create a bootable CD/DVD or USB flash drive, and then boot
that media. This
article will describe a method for running IFL
a boot disk. Instead, IFL will run from a boot file
located on your hard drive.
There is a similar article that describes how to do essentially the same thing with Image for DOS (IFD) instead of IFL. You can find that article at this link: https://www.terabyteunlimited.com/howto/howto-ifd-bootfile.htm
OverviewBooting from a "boot file" is made possible by the free TeraByte Unlimited BOOTFILE (bootfile.exe) utility, which is included with the TeraByte OS Deployment Tool Suite. The BOOTFILE utility can configure the Master Boot Record (MBR) to boot from an NTFS, FAT, or FAT32 partition that is contained in a continuous file in an NTFS, FAT, or FAT32 partition. There are many different ways to configure a boot file, but in this case we will configure it to boot from Windows into IFL. Once booted into IFL, the MBR is automatically restored by the Linux version of BOOTFILE. This prepares the system to boot back into Windows again (i.e. boot normally) when finished with the IFL session.
Getting Set Up
- Download the IFL
boot file setup archive (iflsetup.zip). This zip archive contains the files necessary to configure and boot from the IFL boot file.
- If not already installed, install IFL (version 2.57 or later) so
that its files will be available. This can be either the
stand-alone IFL zip archive extracted to a folder,
or the full IFW/IFD/IFL version that includes IFL and IFD with
the IFW installation. Specifically, the file iflnet.iso must
be available so that it can be mounted and have files copied
- If not already installed, download and extract the TeraByte OS Deployment Tool Suite Professional (tbosdts_pro_en.zip)
on the system so that its files will be available. The
zip archive will contain a second zip
file inside the archive that will require a password to extract. The
password can be found in the
readme.txt file included inside the zip file. The end
result should be a folder with contents similar to the screenshot below:
- Extract iflsetup.zip
to a folder named iflsetup
(the default name) so that its contents are in a sub-folder of
the TBOSDTS folder shown above. The iflsetup folder should be
at the same
level as the linux, win,
dos_tbos, docs, and scripts folders included with TBOSDTS. The
setupifl.bat batch file depends on this
location so that it can find the files it needs. The TBOSDTS
folder should now look like the screenshot shown below:
- In an Explorer window, navigate to the iflsetup folder created
in Step 4. The iflsetup folder's contents should be as shown in the screenshot
- Edit the setupifl.bat batch file (right click and choose
Edit) to configure it to your system and preferences. The
5 parameters to edit are at the beginning of the file, and are
explained in the comments. The
default configuration is shown below. If using the registered version
of IFL, the IFLPK parameter will need to be edited to supply your IFL
Product Key. The other parameters can often be left at their default
values for the typical user setup. However, be sure to check the IFLDIR
parameter to ensure that it points to the correct location for the
iflnet.iso file. The location shown below for that file will be correct
if you installed the IFW/IFD/IFL package to the default location.
If you would like to include one (or more) executable bash
scripts on the IFL boot disk, create them as text files and
put them in the ifl_scripts folder. An executable script can
used, for example, to run an IFL command line automatically
boot. The script(s) that you
in that folder will be copied to the IFL boot file, and will be
available in /tbu/scripts when booted from IFL. A sample
script (named script1) already exists in the ifl_scripts folder by
default. This file can be opened with Notepad by double
clicking it and choosing Notepad to open it.
If you would like to execute one or more of the bash scripts
in the ifl_scripts folder automatically on boot, edit and uncomment the
RUNSCRIPTS option in the file ifl_boot.cfg. See the comments in
ifl_boot.cfg file for additional details. Note that if you do not use
the RUNSCRIPTS option to execute the script(s) automatically, you can
still include them as described in Step 7, and just execute
them manually. The default contents of ifl_boot.cfg are shown below:
If desired, edit the existing copy of ifl.ini (empty by default) to add
any custom IFL settings. Please refer to the IFL User Manual for complete
information on settings that can be included in ifl.ini.
- From the iflsetup folder, execute the setupifl.bat
batch file. This can be done by either double clicking the file, or by
opening a command window in the iflsetup folder, and then running the
command 'setupifl'. The setupifl.bat file will create the IFL boot file, as well as a batch file to boot from it.
Booting from the Boot FileAfter setupifl.bat completes execution, the target directory specified in setupifl.bat (C:\IFLBOOT by default) should now exist, and should contain 3 files; the IFL boot file, the bootfile.exe utility (Windows version), and a batch file to initiate booting from the boot file. The name of the batch file and the boot file will be based on the value chosen for the IFLBIN parameter in the setupifl.bat file. By default, IFLBIN is set to "ifl", so the batch and boot files will be named run_ifl.bat and ifl.bin respectively, as shown in the screenshot below:
To initiate booting from the boot file, double click the batch file. This should result in the system rebooting, and then coming up to the initial IFL boot menu, as shown in the screenshot below. Use the boot menu to boot into IFL as you normally would. When the IFL boot disk gets initialized on boot, the MBR will be automatically restored by the Linux version of BOOTFILE so that on the next reboot, the system will boot normally.
The IFL boot menu shown above is the same as the standard IFL boot menu, with the exception of item 4. The purpose of item 4 is to provide an easy method of restoring the original MBR should IFL fail to boot (hang) on a particular system. This situation should be rare, but it would leave you in a difficult predicament if it did occur, since you would not be able to get back into your normal OS after attempting to boot IFL. If this does happen, item 4 is provided so that you can choose it (type 4, then press <Enter>) to restore the original MBR. The system will be back to normal on the next reboot.
Appendix 1: Description of Files Included in iflsetup.zipifl_boot - This file is the starting point in creating the IFL boot file. It contains a 32 MiB FAT file system that has syslinux installed, and also contains a floppy image file containing the DOS version of bootfile. This file can be booted from the boot menu to restore the MBR in the event that IFL fails to boot on a particular system.
ifl_boot.cfg - This file can be edited to configure the SSHD server to be started on boot, and also to configure one or more scripts to execute automatically.
ifl_boot.tbs - This tbscript is executed by tbosdtw.exe, which is called from setupifl.bat. It mounts and copies files to the IFL boot file. Processing .tbs files require the professional (non-trial) version of tbosdtw.exe.
ifl.ini - This file can be edited to add any custom IFL settings as documented in the IFL manual. The file is empty by default, and is copied to the IFL boot file by the ifl_boot.tbs script.
setupifl.bat - This batch file is executed to create the IFL boot file, as well as a batch file to boot from it. These files, along with the Windows version of bootfile.exe, are copied to a specified folder. The beginning of this file contains variables that can be configured to your preferences. These variables are documented in the file.
ifl_scripts - This folder is where one or more bash scripts can be placed so that they will be copied to the IFL boot file by ifl_boot.tbs. To have one or more of the scripts executed automatically on boot, edit and uncomment the RUNSCRIPTS option in the ifl_boot.cfg file.
Appendix 2: Using Image for Linux to Determine Command Line OptionsYou can use IFL itself to determine a command line that you may want to use in a script (see steps 7 and 8). To do this, proceed as follows:
- Run Image for Linux and proceed as if you were going to
perform the type of backup or restore you
wish to automate, until you arrive at the "Backup Options" or "Restore
- On the "Backup Options" or "Restore Options" screen, adjust
the options to your satisfaction but DO NOT press enter.
(note: to place a check next to various options, highlight it and press
the space bar.).
- Press the F6 key to
display the applicable command line options. An example of what you
will see is shown in the screenshot below:
- Note: certain options like the encryption password or unattended (/um, /uy, /un) options will not show on this screen. For full documentation on the various command line options, please refer to the IFL User Manual.