Use syslinux to guide the linux System

Source: Internet
Author: User
Article Title: Use syslinux to guide the linux system. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.

SYSLINUX mainly contains four programs: syslinux, pxelinux, isolinux, and extlinux.

Except pxelinux, it is only used to start the operating system from the network. It is used to create boot programs for operating systems on different types of file systems.

Syslinux is used on MS-DOS/Windows FAT file system;

Pexlinux is used to start the operating system from the network;

Isolinux is used on ISO 9660/El Torito CD-ROM file system;

Extlinux is used on the Linux ext2/ext3 file system;

First look at the use of syslinux:

Here, we use a flash drive in the FAT32 format as an example. After insertion, if automatic mounting is available, uninstall the USB flash drive first.

Then execute

# Syslinux/dev/sdb

The above command will change the boot partition on the USB flash drive and copy a file LDLINUX. SYS to its root directory.

Then, save syslinux. cfg that contains the following content to the root partition of the USB flash drive. Root =/dev/sda4 is the first partition on the target machine. Copy the kernel vmlinux to the root partition of the USB flash drive.

DEFAULT 2.6.31sda4

TIMEOUT 50

LABEL 2.6.31sda4

SAY Now booting the kernel from SYSLINUX...

LINUX vmlinux

APPEND rw root =/dev/sda4

Then, set the target machine to start from the USB flash drive and insert it into the USB flash drive. The syslinux boot system is successful.

The extlinux operating object is the directory of the mounted device whose file system type is ext2/ext3.

Partition the USB flash drive and format it.

# Mkfs. ext3/dev/sdb1

# Mkfs. ext3/dev/sdb2

Operation in the first partition,

# Cd/media/disk

# Extlinux.

# Cp ~ /Syslinux. cfg extlinux. conf

# Cp kernel.

Because the boot file generated by exlinux is only a common file stored in the USB flash drive, you need to change the MBR to point to it.

Therefore, use the mbr included in the syslinux package to overwrite the original mbr of the USB flash disk. You need to use fdisk to set the boot flag of the partition to on.

# Cat/usr/lib/syslinux/mbr. bin>/dev/sdb

# Fdisk/dev/sdb1

T

A

1

Because the preparation files used by extlinux and syslinux are named differently and have the same content, you can simply copy them.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.