Summary: | Install gentoo via PXE (integrated squashfs.image + init patch) | ||
---|---|---|---|
Product: | Gentoo Release Media | Reporter: | Ax Warhawk <ax.warhawk> |
Component: | Netboot | Assignee: | Gentoo Release Team <releng> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gentoo, nikize, pinkbyte, zerochaos |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
init script patch to load squashfs.image
Patch Detection of squashfs in root Updated patch |
Description
Ax Warhawk
2011-12-29 23:09:16 UTC
Subscribing to this bug. Patch exists long time ago. This patch is not production-quality, but it seems that some users really need such functionality(i am the such user also). Could we do something about this? I have made similar implementations for SystemRescueCd[1], The idea is simply to allow for squashfs image to be located in already existing/mounted filesystem, before search on different media is started. I also made this work by injecting a /etc/initrd.splash (and squashfs) via additional cpios, .splash containing: got_good_root=1 bootstrapCD() { CDROOT_PATH=/ cd / REAL_ROOT=/ return 0 } [1] https://github.com/NiKiZe/systemrescuecd/commit/e97479ddbd02075e1ed44e39460b9aa3b85ac306 I also think that BUG #74628, and BUG #494300 would be solved by this Created attachment 540984 [details, diff] Patch Detection of squashfs in root Added patch that should work, hopefully without breaking anything else. Example usage at http://b800.org/gentoo/boot.ipxe With backup at https://gateway.ipfs.io/ipfs/QmP1hw69dV7kSUBEBTBpGtudxwcH5Apu1ngUzRtr5jEBCR/boot.ipxe With attached patch applied however, the "/etc/initrd.splash" in boot.ipxe should not be needed. What the patch does is "simply" to detect if the LOOP filename already exists in the existing filesystem (exact path match) and if it does it skips all CD detection and mounting. the CDROOT_PATH modification is needed to avoid check_loop() in initrd.scripts to error out, didn't find a better way to handle that. Created attachment 540986 [details, diff]
Updated patch
Updated patch with initialization of variables added, and some comments
Robin, ignore "init script patch to load squashfs.image", the other patch is good to go I think. The bug has been closed via the following commit(s): https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=24ad5065fa856389ee9b058f57adffbe752da157 commit 24ad5065fa856389ee9b058f57adffbe752da157 Author: Christian Nilsson <nikize@gmail.com> AuthorDate: 2018-07-24 23:08:23 +0000 Commit: Rick Farina (Zero_Chaos) <zerochaos@gentoo.org> CommitDate: 2018-07-25 15:10:19 +0000 linuxrc: Add detection of squashfs in initrd root Allows for the squashfs to be found in the initrd root without mounting CD This allows iPXE boot by adding the squashfs in a extra cpio initrd Related: https://bugs.gentoo.org/74628 Related: https://bugs.gentoo.org/494300 Closes: https://bugs.gentoo.org/396467 Signed-off-by: Christian Nilsson <nikize@gmail.com> defaults/initrd.defaults | 5 +++++ defaults/linuxrc | 21 +++++++++++++++------ 2 files changed, 20 insertions(+), 6 deletions(-) |