Skip to content
FreeDOSDeep Dive Published Updated 7 min readViews unavailable

FreeDOS SYS: Install the Kernel and Boot Sector Without Repartitioning

Learn what FreeDOS SYS changes, how it differs from FDISK and FORMAT, and how to back up boot sectors before testing bootable media.

FreeDOS SYS makes an already prepared medium bootable by installing FreeDOS boot-related files and boot code. It does not create a partition table, select an active partition, or format a filesystem. Those are separate steps with different failure modes. On a floppy, formatting may be sufficient preparation; on a hard disk, a partition must exist and be formatted before SYS can install onto its drive letter. Because SYS writes boot metadata and copies system files, use a clone, a VM snapshot, or a disposable destination during testing.

What SYS changes

The FreeDOS SYS documentation describes the command as installing boot support on a floppy, hard disk, or other writable medium. In its standard behavior it writes a boot sector and copies KERNEL.SYS and COMMAND.COM to the target. The kernel is needed to load CONFIG.SYS/FDCONFIG.SYS and provide DOS services; the shell then processes AUTOEXEC.BAT/FDAUTO.BAT. These files must be available in the locations expected by the installed boot sector and kernel configuration.

The boot sector is executable startup code. It is not the partition table itself, and SYS does not decide which hard-disk partition should be active. On a partitioned disk, BIOS boot code or another boot manager first selects a partition and loads its volume boot sector. SYS operates at the drive/volume level specified to it; it is not a universal bootloader for every firmware mode, partition scheme, filesystem, or USB device.

The command can also accept a source location for system files. Its basic form is SYS [source] drive:. If source is omitted, the current directory is assumed, so a command issued from the wrong location may fail or copy an unintended version. For reproducible work, record which KERNEL.SYS and COMMAND.COM you intend to install and identify the source directory explicitly.

SYS, FDISK, and FORMAT have separate roles

FDISK creates or changes partitions. FORMAT creates a filesystem within a selected volume. SYS copies system files and updates boot code so that a prepared volume can load FreeDOS. Running SYS does not imply that the disk is partitioned correctly or that the filesystem is compatible. Likewise, a successful format does not mean the firmware can boot from the device.

For a new hard disk, the high-level sequence may include partition creation, making the intended partition active where required, rebooting so the partition layout is re-read, formatting the correct drive letter, and then installing SYS. The precise partition and firmware steps depend on the machine. The FreeDOS FDISK and SYS documentation should be checked for the installed versions; do not treat an old machine’s setup recipe as universal for modern USB or UEFI systems.

Floppy media are different: FreeDOS notes that FDISK is not needed for floppy disks. A typical lab sequence is to format a known disposable floppy and run SYS from an existing FreeDOS boot environment. Do not combine this with a valuable disk or assume that /S on FORMAT makes the filesystem and boot code valid for every target. SYS remains a distinct stage and should be tested with the actual boot configuration.

Select and verify the source and destination

Before running SYS, inspect the executable’s help with SYS /?. Confirm the BIOS drive mapping, DOS drive letter, volume label, source path, and target filesystem. If multiple hard disks or removable devices are attached, disconnect any that are not part of the test. In a VM, keep a copy of the disk image and record the configured boot order. A drive letter alone does not identify a physical disk.

The FreeDOS help documents options such as /BACKUPBS and /DUMPBS for saving the existing boot sector. Their syntax and behavior should be checked against the installed SYS build before use. Store the backup on a separate volume and confirm the file exists and has the expected size before making changes. A backup written to the same target disk can be lost or overwritten during repair.

For an isolated test, use a separate cloned image and take a snapshot before starting. Run SYS against that image only, then boot the clone in the same firmware mode and virtual hardware that will be used in service. A backup of the volume boot sector does not by itself preserve the partition table, filesystem, files, or the whole device state. If recovery matters, preserve a full image as well.

Options that intentionally narrow the operation

SYS documents /BOOTONLY to update the boot sector or image without copying the kernel and shell. /UPDATE copies the kernel and updates the boot sector but does not copy the shell. These are specialized modes, not safe defaults. Use them only when you understand which components are already present and intentionally want to leave the others unchanged. A partially updated combination can be unbootable if the boot code expects a file that is absent or incompatible.

The utility also documents OEM and drive-selection options that influence boot-sector behavior. Those flags exist for compatibility with different DOS families and BIOS assumptions. Do not force LBA, CHS, OEM, or BIOS-drive settings as a guess. If the machine boots inconsistently, first capture the current state, confirm firmware geometry/mapping, and consult the specific kernel and SYS documentation. Forcing an option can hide the true mismatch while making recovery harder.

Never infer from /BOOTONLY that the operation is read-only: it writes boot code. Never infer from /UPDATE that all system files are synchronized: it intentionally omits COMMAND.COM. Exact support and option parsing vary with SYS versions, so verify the actual output and the installed help text.

Controlled installation workflow

For a disposable prepared floppy, use a known source directory and target:

SYS C:\FREEDOS\BIN\ A:

This example assumes that the source directory contains the intended FreeDOS system files and A: is the disposable floppy. The target must already be formatted and writable. Do not run the command until those assumptions have been independently confirmed.

For a prepared hard-disk volume, first create a full image or snapshot. Verify the correct drive letter, check that the expected partition is active if the boot method requires it, and back up the relevant boot sector. Then use SYS with an explicit source path and the intended target drive. Avoid ambiguous current-directory assumptions and avoid testing with /BOOTONLY or OEM overrides unless that is the specific behavior under investigation.

After SYS reports success, inspect the root directory for the expected system files and confirm the boot sector backup remains available. Boot the cloned target without attaching the original source disk if practical; this detects accidental dependence on files from the source medium. Capture the boot message and kernel version so the test is reproducible.

Diagnosing failures without escalating risk

If SYS cannot write the target, distinguish a source problem from a destination problem. Confirm source files exist and are the intended versions; verify the destination is not read-only, full, or mapped to an unsupported device; and check whether the filesystem and BIOS access path are supported. A DOS critical I/O error should not be silenced by forcing compatibility options. Preserve the error text and test a cloned image.

If installation succeeds but the system will not boot, determine which layer failed: firmware selection, disk/partition boot code, partition active status, volume boot sector, kernel file path, shell file, or CONFIG.SYS configuration. Boot from an independent FreeDOS disk and inspect the destination without rewriting it. Compare the installed files and boot-sector backup against the known-good image. The fact that SYS exited successfully confirms its own operation, not the end-to-end boot path.

The kernel belongs in the root directory of the boot medium under the expected name unless its boot configuration says otherwise. The shell is loaded after the kernel and may be selected through startup configuration. A wrong shell path can produce a failure after the kernel has already started; that is different from a BIOS that cannot read the volume boot sector.

Acceptance criteria

Accept a SYS installation only after the boot-sector change, system-file versions, and intended boot path have been verified. Test the clone from a cold start in the target environment, confirm the expected FreeDOS kernel and shell load, and verify required startup files run. Keep the original medium unchanged until the test passes. For production firmware updates or recovery media, retain a known-good tested alternative; one newly created boot disk should not be the only recovery path.

Related:

Sources:

Comments