LinuxCommandLibrary

syslinux-legacy

Make a partition bootable with SYSLINUX

SYNOPSIS

syslinux device

PARAMETERS

device
    The device name (e.g., /dev/sda1, /dev/sdb, /dev/fd0) where SYSLINUX should be installed.

-d directory
    Specifies the directory where SYSLINUX files will be installed. Defaults to '/syslinux'.

-i
    Installs a new copy of ldlinux.sys, overriding any existing copy.

-m
    Write a generic MBR (Master Boot Record). Use with caution!

-f
    Forces installation, even if the device appears to be mounted.

-s
    Serial console redirect support.

-o offset
    Specifies a filesystem offset. Use with caution, may damage filesystems

DESCRIPTION

syslinux-legacy is a tool used to install the SYSLINUX bootloader on a FAT filesystem, typically a USB drive or floppy disk. SYSLINUX is a lightweight bootloader designed to boot Linux from FAT filesystems. syslinux-legacy installs the necessary files and configures the boot sector to allow a computer to boot from that filesystem.
It's primarily used for older systems or situations where UEFI is not required or supported. The tool relies on specific filesystem layouts and requires careful configuration to ensure proper booting. The 'legacy' designation distinguishes it from the newer, more feature-rich SYSLINUX/ISOLINUX distribution often used with modern Linux distributions and ISO images. Correct configuration usually involves creating a syslinux.cfg file to point to the kernel and initrd files.

CAVEATS

syslinux-legacy directly modifies the boot sector of a device. Incorrect usage can render the device unbootable or corrupt data. Ensure you have a backup or understand the consequences before running. This is a legacy tool and may not be suitable for modern UEFI-based systems. Be careful when using the -m option as it overwrites the MBR.

CONFIGURATION

After running syslinux-legacy, you'll need to create a syslinux.cfg file in the specified directory (usually /syslinux). This file contains directives that tell SYSLINUX which kernel and initrd to load and any other boot options.

BOOTING PROCESS

When the system boots from the device where SYSLINUX is installed, the boot sector loads ldlinux.sys, which in turn reads the syslinux.cfg file to determine the next steps, such as loading the Linux kernel and initrd.

HISTORY

SYSLINUX (and therefore syslinux-legacy) has been around since the mid-1990s. It emerged as a solution for booting Linux from FAT filesystems on floppy disks and later USB drives. The 'legacy' designation reflects its origins and its continued use in situations where a simple, lightweight bootloader is preferred over more complex options like GRUB. The tool has been maintained and updated over the years, but its core functionality remains focused on providing a straightforward way to boot Linux from FAT filesystems.

SEE ALSO

ldlinux.sys(5), syslinux.cfg(5)

Copied to clipboard