Polish geeks use a floppy disk to run the Linux system, using the latest kernel

A few hundred KiB are left when the 1.44MB disk is used up

Booting Linux systems with floppy disks used to be “commonplace”, of course it was all in the 90s and 00s.

Older students (bushi) may be familiar with it.

But now, even if you still have a 3.5-inch floppy disk that can be used, the 1.44MB capacity is far less than a modern Linux kernel, let alone all supporting software.

But Qiren has a trick. A game developer in Poland used a floppy disk to embed the modern Linux operating system!

There are hundreds of KiB free space on the disk! And all the latest “components” are used, including the 5.13.0-rc2 version of the Linux kernel that was released on 5.16 this year.

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

A floppy disk to install modern Linux system

My brother named this system Floppinux and walked everyone through the entire process on its official website, including all the commands from pull down, compiling the source code to creating the final disk image.

The reason for doing such a thing is because I feel that I have used Linux for many years and also used a lot of Live-CD (to experience the things of Linux operating system without installing to the hard disk).

But he knew very little about the basic principles behind it, so he decided to do some research.

My first goal is to run the Nomad Diskmag program.

Does anyone know Diskmag this ancient thing?

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Its full name is disk magazine, which is an electronic magazine issued in the form of floppy disks in the 1980s and 1990s. After the 1990s, it was replaced by online publications.

Brother has used the bash script to get the front-end interface, only the cover, directory and the text of each file in cat are missing.

In order to run the script he wrote, you need an available Linux distribution, that is, a system that can run on a floppy disk.

Do it!

Because compiling 32-bit code on a 64-bit system is a bit tricky. To make it easier, I used his old notebook with a 32-bit CPU to do all this.

You can use the 32-bit system VirtualBox, if you want to use 64-bit, add the command “ARCH=x86”, for example: make ARCH=x86 tinyconfig.

The following is the approximate process of installing a modern Linux operating system into a 1.44MB floppy disk:

1. Create and enter the directory where you want to save the file

2. Configure and build a custom kernel

Use the latest Linux kernel (version 5.13.0-rc2):

git clone –depth=1 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Make minimal configuration: make tinyconfig

Add additional configuration: make menuconfig

Choose the following options from the menu:

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Save the settings and exit, wait for the compilation to complete, and finally the kernel will be built in arch/x86/boot/bzImage and move it to the home directory.

3. Add tools

If there is no tool, the kernel will only start and cannot perform any operations. Brother uses BusyBox (one of the most popular lightweight tools), download and unzip:

wget https://busybox.net/downloads/busybox-1.33.1.tar.bz2

Enter the directory and start configuration: make allnoconfig

Then select the tool you want: make menuconfig

Each menu item shows how many KB each tool needs to take up, choose a reasonable one.

Brother’s choice:

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Save the configuration and exit. After the compilation is complete, a file system containing all files will be created in the _install directory and moved to the home directory.

4. Add directory structure

With the kernel and basic tools, some additional directory structure is still needed:

cd ../filesystemmkdir -pv {dev,proc,etc/init.d,sys,tmp}sudo mknod dev/console c 5 1sudo mknod dev/null c 1 3

Next, create a few configuration files and display a welcome message after startup:

cat >> welcome << EOFSome welcome text…EOF

Then configure the Inittab file & actual initialization script that handles startup, exit, and restart, and make the initialization script executable, and set the owner of all files to root. (The command has been omitted due to space limitations. For details, please refer to the link at the end of the article [1])

Finally, compress this directory into a file.

All of the above can be tested by running QEMU (an analog processor widely used on the GNU/Linux platform) from the home directory.

5. The following is to put all this into a floppy disk

Create a Syslinux boot file pointing to the kernel and file system:

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Create an empty floppy disk image:

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Mount it! and copy syslinux, kernel, and file system to the floppy disk image:

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

carry out!

Now you have your own distribution image floppinux.img, you can burn it to a floppy disk, and then start it on the real hardware!

Start-up takes more than 1 minute

It took me less than 3 minutes to burn successfully, and then started the first boot:

success! It probably only took more than 1 minute.

The younger brother (brother) said that the only thing that can prevent the startup speed on this bare-metal modern hardware is the actual speed of the floppy drive. Their maximum raw speed is 125KB/s. It may actually be slower.

The following is a summary of the space occupied by the floppy disk, you can see that there are 272KiB left.

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Netizens hotly discuss: “In 1992, I needed two 5.25″ floppy disks.”

Hardware open source project site Hackaday to create small brother were reported, and points commentary said:

Of course, in order to build the latest Linux kernel and BusyBox to a space of about 1MB, some concessions must be made, so Floppinux is definitely not a daily driver as anyone said. Once the system is started, there is nothing to do except write some shell scripts.

Even if you don’t have a floppy disk, it is worth following his tutorial to boot the image in QEMU and see how to build a Linux system from scratch. This can not only be used to brag, the knowledge of how all the components of such a minimal installation are put together is also very useful for learning embedded Linux devices.

On the Hacker News forum, many people gave the little brother a thumbs up. Some people said that what surprised him most was the latest version of the Linux kernel and BusyBox. And this is also very useful for other embedded systems.

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Some people say that I needed two 5.25-inch floppy disks to run Linux in 1992!

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

Developer introduction

Polish geeks use a floppy disk to run the Linux system, using the latest kernel

The protagonist “Little Brother” in the article is called Krzysztof Jankowski, from Poland, born in 1985, is a professional game developer and digital artist.

I started programming with QBASIC 25 years ago. I like FOSS, pixel art, Raspberry Pi, game engines, etc.

Last year, he founded his own company Cyfrowy Nomada and signed an advanced game engine development contract with beffio. His dream of becoming a professional game developer became a reality.

He and his partners developed the game “Tanks of Freedom” (Tanks of Freedom), I don’t know if anyone has played it?

GitHub Portal: https://github.com/w84death/floppinux

Reference link:

[1]https://bits.p1x.in/floppinux-an-embedded-linux-on-a-single-floppy/

[2]https://hackaday.com/2021/05/24/running-modern-linux-from-a-single-floppy-disk/

[3]https://news.ycombinator.com/item?id=27247612

[4] https://krzysztofjankowski.com/

Posted by:CoinYuppie,Reprinted with attribution to:https://coinyuppie.com/polish-geeks-use-a-floppy-disk-to-run-the-linux-system-using-the-latest-kernel/
Coinyuppie is an open information publishing platform, all information provided is not related to the views and positions of coinyuppie, and does not constitute any investment and financial advice. Users are expected to carefully screen and prevent risks.

Like (0)
Donate Buy me a coffee Buy me a coffee
Previous 2021-07-06 07:34
Next 2021-07-06 07:36

Related articles