{"id":15003571,"url":"https://github.com/expertcoderz/floppy-disk-linux","last_synced_at":"2025-10-03T14:31:20.735Z","repository":{"id":236690868,"uuid":"792985557","full_name":"Expertcoderz/floppy-disk-linux","owner":"Expertcoderz","description":"An x86-64 EFI-compatible Linux system on a 3½-inch floppy disk.","archived":true,"fork":false,"pushed_at":"2024-05-26T04:28:39.000Z","size":64,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-09-29T14:42:50.438Z","etag":null,"topics":["busybox","busybox-linux","busybox-system","busybox-userland","efi","floppy","floppy-disk-images","floppy-disks","linux","linux-kernel","uefi","uefi-boot"],"latest_commit_sha":null,"homepage":"","language":"Makefile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc0-1.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Expertcoderz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-04-28T05:23:42.000Z","updated_at":"2024-08-21T13:35:36.000Z","dependencies_parsed_at":null,"dependency_job_id":"05b9dee1-fd28-4e0f-a1c9-0f93fab1db55","html_url":"https://github.com/Expertcoderz/floppy-disk-linux","commit_stats":null,"previous_names":["expertcoderz/floppy-disk-linux"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Expertcoderz%2Ffloppy-disk-linux","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Expertcoderz%2Ffloppy-disk-linux/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Expertcoderz%2Ffloppy-disk-linux/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Expertcoderz%2Ffloppy-disk-linux/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Expertcoderz","download_url":"https://codeload.github.com/Expertcoderz/floppy-disk-linux/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235146451,"owners_count":18943262,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["busybox","busybox-linux","busybox-system","busybox-userland","efi","floppy","floppy-disk-images","floppy-disks","linux","linux-kernel","uefi","uefi-boot"],"created_at":"2024-09-24T18:59:02.225Z","updated_at":"2025-10-03T14:31:20.297Z","avatar_url":"https://github.com/Expertcoderz.png","language":"Makefile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Floppy Disk Linux\n\n![console screenshot](screenshots/console.png)\n\nThis repository provides a set of tools and configs to build a x86-64 Linux\ndistribution with the very latest software (kernel and userland), fitting\nentirely on a 1.44 MB floppy disk and booting natively in a UEFI environment.\n\nHeavily inspired by [Floppinux](https://github.com/w84death/floppinux), with the\nfurther aim of supporting some key characteristics of modern PCs (64-bit architecture, UEFI\nboot, SMP etc.) while also packing as much functionality as practically possible\nin the form of [BusyBox](https://www.busybox.net/) command-line utilities.\n\nFloppy Disk Linux is intended for education and experimental purposes only. Due\nto the increasingly large size of the Linux kernel and related software, there\nis of course not very much that can be squeezed into 1.44 MB[^1].\n\n## Building\n\nThe provided makefile automatically downloads sources, applies configurations,\nbuilds software and prepares the root filesystem as well as the final floppy\ndisk image.\n\nMakefile host system requirements:\n\n- `git` for fetching and updating all sources\n- `gcc` and `binutils` for building\n- `fakeroot` for creating `rootfs.cpio`\n- `sudo`, `mount`, `umount`, `mountpoint`, `losetup`, `mkfs.fat` for creating\n  `floppy.img`\n- `qemu-system-x86_64` and [OVMF](https://github.com/tianocore/tianocore.github.io/wiki/How-to-run-OVMF)\n  for testing the images, if desired\n- the usual core utilities found on GNU/Linux installations\n- `make`, obviously\n\nTo fetch sources and perform initial configuration, run:\n\n```sh\nmake configure\n```\n\nAfterwards, to start the actual build process:\n\n```sh\nmake\n```\n\nThe result is `floppy.img`: a FAT12-formatted disk image[^2] containing the\nFloppy Disk Linux [EFI executable](https://www.kernel.org/doc/html/latest/admin-guide/efi-stub.html)\nwith the root filesystem embedded as an [initramfs](https://www.kernel.org/doc/html/latest/filesystems/ramfs-rootfs-initramfs.html#what-is-initramfs).\n\nThe image can then be written to an actual floppy disk:\n\n```sh\nsudo dd if=floppy.img of=/dev/fd0\n```\n\n(Substitute `fd0` accordingly if using a different or external floppy disk drive.)\n\nTo quickly test the OS in a [QEMU](https://www.qemu.org/) virtual machine:\n\n```sh\nmake runqemu-bzImage\n```\n\nOr, to test the OS booting from the floppy disk image itself:\n\n```sh\nmake runqemu-floppy.img\n```\n\nTo clean up everything:\n\n```sh\nmake reset\n```\n\nRefer to `Makefile` itself for other possible `make` targets.\n\n## Booting\n\nThe `floppy.img` image should allow Floppy Disk Linux to boot from external\nfloppy disk drive connected to a modern PC via USB. Ensure that the PC's\nfirmware is configured to boot from such media.\n\nThe layout of `floppy.img` is as follows:\n\n```txt\n+--------------------------------------+-------------------------+\n| Linux EFI stub (bootloader) \u0026 kernel | Root filesystem archive |\n+--------------------------------------+-------------------------+\n|          Linux EFI executable (\\EFI\\BOOT\\BOOTX64.EFI)          |\n+----------------------------------------------------------------+\n|                        FAT12 filesystem                        |\n+----------------------------------------------------------------+\n|                            Raw disk                            |\n+----------------------------------------------------------------+\n```\n\nAccording to [section 13.3.1](https://uefi.org/specs/UEFI/2.10/13_Protocols_Media_Access.html#system-partition)\nof the UEFI Specification 2.10:\n\n\u003e For a diskette (floppy) drive, a partition is defined to be the entire media.\n\nTherefore, creating a GUID Partition Table (GPT) and \"EFI System Partition\" on\n`floppy.img` should not be necessary for it to boot successfully. To create a\nGPT and place the filesystem on an EFI System Partition anyway, pass\n`BOOTFS_CREATE_GPT=1` to `make` (requires the `sgdisk` utility):\n\n```sh\nmake BOOTFS_CREATE_GPT=1\n```\n\n`floppy.img` will then take the following form instead:\n\n```txt\n+--------------------------------------+-------------------------+\n| Linux EFI stub (bootloader) \u0026 kernel | Root filesystem archive |\n+--------------------------------------+-------------------------+\n|          Linux EFI executable (\\EFI\\BOOT\\BOOTX64.EFI)          |\n+----------------------------------------------------------------+\n|                        FAT12 filesystem                        |\n+----------------------------------------------------------------+\n|                      EFI System Partition                      |\n+----------------------------------------------------------------+\n|                       GPT-formatted disk                       |\n+----------------------------------------------------------------+\n```\n\n## Limitations\n\n- No support for [block devices](https://linux-kernel-labs.github.io/refs/heads/master/labs/block_device_drivers.html)\n  and thus accessing persistent storage media (for example, internal SSDs or\n  external USB mass storage devices, even the disk from which the OS is booted)\n  is not possible from the OS. This means that the only filesystem to work with\n  resides in memory and any changes made to / will be lost on system shutdown.\n\n  This is because adding block device, USB and FAT filesystem functionality\n  into the Linux kernel enlarges it by hundreds of kilobytes, beyond what would\n  successfully fit on a 1.44 MB floppy disk.\n\n  If you find a reasonable way to achieve mounting filesystems on persistent\n  media, please [open an issue](https://github.com/Expertcoderz/floppy-disk-linux/issues/new/choose)\n  describing how to do so and it may be incorporated into Floppy Disk Linux.\n\n- No support for x2APIC, which may be necessary for SMP to work on real\n  machines. Enabling x2APIC support in the Linux kernel requires also enabling\n  PCI and IOMMU support.\n\n- No fancy graphics, only a text console on the EFI framebuffer.\n\n- No networking support of any kind.\n\n- Non-goals of Floppy Disk Linux which will not be supported include booting on\n  BIOS-based (non-UEFI) systems and running on an IA-32 (32-bit) processor.\n\n## TODO\n\n- Implement the ability to mount persistent storage devices.\n\n- Implement support for x2APIC.\n\n- Experiment on the use of a minimal external bootloader instead of the Linux\n  EFI stub, to reclaim some disk space.\n\n- Add `make` targets to analyze image size.\n\n[^1]: For an example of a feature-rich OS on a floppy disk, see: https://menuetos.net/.\n\n[^2]: Other FAT sizes such as FAT16 and FAT32 are unable to handle a 1.44 MB\nfilesystem size and thus cannot be used to format the floppy disk.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fexpertcoderz%2Ffloppy-disk-linux","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fexpertcoderz%2Ffloppy-disk-linux","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fexpertcoderz%2Ffloppy-disk-linux/lists"}