{"id":20067712,"url":"https://github.com/hypersolid-os/bootloader.ipxe-cloud","last_synced_at":"2025-08-19T18:37:16.076Z","repository":{"id":145684396,"uuid":"228258415","full_name":"hypersolid-os/bootloader.ipxe-cloud","owner":"hypersolid-os","description":"boot hypersolid via [MBR -\u003e syslinux -\u003e ipxe] chaining","archived":false,"fork":false,"pushed_at":"2020-05-18T07:39:24.000Z","size":20,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-12T23:27:54.302Z","etag":null,"topics":["bootloader","cloudserver","extlinux","hypersolid","ipxe","syslinux"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hypersolid-os.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","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":"2019-12-15T21:53:31.000Z","updated_at":"2024-09-01T07:31:14.000Z","dependencies_parsed_at":null,"dependency_job_id":"d342c62f-c9ad-499d-8de0-c53a9bfa94c4","html_url":"https://github.com/hypersolid-os/bootloader.ipxe-cloud","commit_stats":{"total_commits":5,"total_committers":1,"mean_commits":5.0,"dds":0.0,"last_synced_commit":"2efcd2d6a8f879d0be99125f07b69fd80f0c69a5"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hypersolid-os%2Fbootloader.ipxe-cloud","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hypersolid-os%2Fbootloader.ipxe-cloud/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hypersolid-os%2Fbootloader.ipxe-cloud/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hypersolid-os%2Fbootloader.ipxe-cloud/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hypersolid-os","download_url":"https://codeload.github.com/hypersolid-os/bootloader.ipxe-cloud/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241494194,"owners_count":19971874,"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":["bootloader","cloudserver","extlinux","hypersolid","ipxe","syslinux"],"created_at":"2024-11-13T14:03:06.750Z","updated_at":"2025-03-02T11:18:19.788Z","avatar_url":"https://github.com/hypersolid-os.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"hypersolid bootloader for cloudservers/virtual maschines\n=========================================================\n\n**boot hypersolid via [MBR -\u003e syslinux -\u003e ipxe] chaining**\n\nUse case\n=============\n\nWithin cloud environments/virtual servers there is mostly no possibility to use pxe-boot directly to load ipxe (which is the recommend method to deploy hypersolid on server systems).\n\nAs a workaround, we use [syslinux/extlinux](https://wiki.syslinux.org/wiki/index.php?title=EXTLINUX) as bootloader to chainload [ipxe](http://http://ipxe.org/) which can for example retrieve a configuration file via https.\n\nHow to deploy\n===================\n\nMost hosting providers offering a rescue-system or supports raw system images directly.\n\nThe final image can be directly copied onto the boot disk of the system using dd:\n\n```bash\n# extract image and write to disk\ngzip -d -c boot.img.gz | dd bs=4M status=progress of=/dev/sdX\n\n# create new uuid's and rewrite secondary GPT table to the end of the disk\nsgdisk -G /dev/sdX\n```\n\nBuild image\n===================\n\nThis bootloader generator creates a raw GPT disk image with 2 paritions (boot, config) including all required bootloader files + configs. The build environment is isolated within a docker container but requires full system access (privileged mode) due to the use of loop devices.\n\nTo build the disk image, you have do add the `ipxe.lkrn` binary into `ipxe/` directory. Optionally place a `ipxe.conf` file into this directory if your not using a embedded ipxe script.\n\n### Embedded iPXE script ###\n\n**File** `extlinux/extlinux.conf`\n\n```conf\nDEFAULT ipxe\n  SAY booting iPXE from SYSLINUX\nLABEL ipxe\n  LINUX ipxe.lkrn\n```\n\n### External iPXE script ###\n\n**File** `extlinux/extlinux.conf`\n\n```conf\nDEFAULT ipxe\n  SAY booting iPXE from SYSLINUX\nLABEL ipxe\n  LINUX ipxe.lkrn\n  INITRD ipxe.conf\n```\n\n**File** `ipxe/ipxe.conf`\n\n```conf\n#!ipxe\n\necho booting LINUX from iPXE\n\n# network setup\n# ------------------------------------------------------------------\n\n# try to get an IP via dhcp\ndhcp\nchain http://ipxe1.example.org/myconfig.ipxe?serial=${serial}\n```\n\n### Run Build ###\n\nFinally run `build.sh` to build the docker image and trigger the image build script. The disk image will be copied into the `dist/` directory.\n\n```txt\n $ ./build.sh \nSending build context to Docker daemon  6.144kB\nStep 1/7 : FROM debian:buster as build\n ---\u003e 8e9f8546050d\nStep 2/7 : ENV DEBIAN_FRONTEND=noninteractive\n ---\u003e Using cache\n ---\u003e 818ca9c1ef88\nStep 3/7 : WORKDIR /opt\n ---\u003e Using cache\n ---\u003e 6c85e942c228\nStep 4/7 : RUN set -xe     \u0026\u0026 apt-get update     \u0026\u0026 apt-get -y --no-install-recommends         install extlinux gdisk\n ---\u003e Using cache\n ---\u003e 88de8edd75b4\nStep 5/7 : COPY entrypoint.sh /entrypoint.sh\n ---\u003e Using cache\n ---\u003e 041ee0bfa8f9\nStep 6/7 : ENTRYPOINT [ \"/bin/bash\" , \"-c\"]\n ---\u003e Using cache\n ---\u003e d998cea2da5a\nStep 7/7 : CMD [ \"/entrypoint.sh\" ]\n ---\u003e Using cache\n ---\u003e 5e54c23470ac\nSuccessfully built 5e54c23470ac\nSuccessfully tagged hypersolid-boot-cloudserver:latest\nhypersolid-boot-cloudserver-env\nCreating new GPT entries.\nSetting name!\npartNum is 0\nSetting name!\npartNum is 1\nWarning: The kernel is still using the old partition table.\nThe new table will be used at the next reboot or after you\nrun partprobe(8) or kpartx(8)\nThe operation has completed successfully.\nGPT fdisk (gdisk) version 1.0.3\n\nPartition table scan:\n  MBR: protective\n  BSD: not present\n  APM: not present\n  GPT: present\n\nFound valid GPT with protective MBR; using GPT.\nDisk /opt/build/disk.img: 1048576 sectors, 512.0 MiB\nSector size (logical): 512 bytes\nDisk identifier (GUID): DA307D18-07FB-4605-B630-EF355CBF2F2A\nPartition table holds up to 128 entries\nMain partition table begins at sector 2 and ends at sector 33\nFirst usable sector is 34, last usable sector is 1048542\nPartitions will be aligned on 2048-sector boundaries\nTotal free space is 2014 sectors (1007.0 KiB)\n\nNumber  Start (sector)    End (sector)  Size       Code  Name\n   1            2048           22527   10.0 MiB    8300  extlinux\n   2           22528         1048542   501.0 MiB   8300  config\n1:2:1 (legacy BIOS bootable)\n1+0 records in\n1+0 records out\n440 bytes copied, 2.8426e-05 s, 15.5 MB/s\nmke2fs 1.44.5 (15-Dec-2018)\nDiscarding device blocks: done                            \nCreating filesystem with 10240 1k blocks and 2560 inodes\nFilesystem UUID: 6f541550-18d7-4ca1-a69c-f402dcac4c37\nSuperblock backups stored on blocks: \n        8193\n\nAllocating group tables: done                            \nWriting inode tables: done                            \nWriting superblocks and filesystem accounting information: done\n\nmke2fs 1.44.5 (15-Dec-2018)\nDiscarding device blocks: done                            \nCreating filesystem with 513004 1k blocks and 128520 inodes\nFilesystem UUID: 3b6cd75b-249c-4790-9436-52eaa797750e\nSuperblock backups stored on blocks: \n        8193, 24577, 40961, 57345, 73729, 204801, 221185, 401409\n\nAllocating group tables: done                            \nWriting inode tables: done                            \nCreating journal (8192 blocks): done\nWriting superblocks and filesystem accounting information: done \n\n/mnt/boot/extlinux is device /dev/loop0p1\nWarning: unable to obtain device geometry (defaulting to 64 heads, 32 sectors)\n         (on hard disks, this is usually harmless.)\n```\n\nBoot stages\n===================\n\n0. host system loads the initial bootloader (e.g. SeaBIOS) | hostsystem\n1. BIOS loads the MBR bootcode (`gptmbr.bin`) at the start of the root disk | extlinux-stage1\n2. extlinux mbr code searches for the first active partition | extlinux-stage1\n3. extlinux mbr code executes the volume boot records of the active partition (contains the inode address of `ldlinux.sys`) | extlinux-stage2\n4. extlinux loads the rest of `ldlinux.sys` | extlinux-stage3\n5. extlinux loads `ldlinux.c32` core bootloader module | extlinux-stage4\n6. extlinux core module searches for the configuration file `extlinux/extlinux.conf` and loads it | extlinux-stage5\n7. extlinux loads+executes the `ipxe.krnl` code which includes a full featured ipxe bootloader | ipxe-stage1\n\nPartition layout\n===================\n\nThis bootloader generator creates a GPT based partition layout (of course, syslinux can handle it).\n\n* Partition 1 \"boot\" - `10MB` | `EXT2` (required for extlinux!) | bootloader partition including extlinux+ipxe\n* Partition 2 \"conf\" - `500MB` | `EXT4` | persistent data storage partition\n\nIPXE binary\n===================\n\nThe [iPXE](http://ipxe.org) binary can be build from source (to include an embedded config file) or retrieved from the [official website](http://ipxe.org)\n\n\nLicense\n----------------------------\n\n**hypersolid** is OpenSource and licensed under the Terms of [GNU General Public Licence v2](LICENSE.txt). You're welcome to [contribute](CONTRIBUTE.md)!","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhypersolid-os%2Fbootloader.ipxe-cloud","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhypersolid-os%2Fbootloader.ipxe-cloud","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhypersolid-os%2Fbootloader.ipxe-cloud/lists"}