HackerTrans
トップ新着トレンドコメント過去質問紹介求人

astralbijection

no profile record

投稿

curl > /dev/sda: How I made a Linux distro that runs wget | dd

astrid.tech
172 ポイント·投稿者 astralbijection·4 か月前·65 コメント

コメント

astralbijection
·3 か月前·議論
> An archive of files and directories is in itself not a program.

Okay, but you can make the same argument to say that ELF files aren't programs in and of themselves either. In fact, some ELF files are dynamic libraries without an entrypoint, and therefore not actually executable in any meaningful way unless connected to yet another program.

If you can accept that some ELF files are executables and some aren't, then you can also accept that some CPIOs are executables and some aren't. What's the difference between ld.so unpacking an ELF file into RAM and running its entrypoint, and the Linux kernel unpacking an initramfs into RAM and running its entrypoint?
astralbijection
·3 か月前·議論
This one is an interpreter for CPIO files.
astralbijection
·3 か月前·議論
... I think you're reading a bit much into it. It's less that I couldn't afford to pay that, and more that I didn't want to pay that, and iterating on the solution I used to dodge that led me down a giant rabbit hole of learning more about Linux while solving stupider and stupider problems posed for myself.
astralbijection
·4 か月前·議論
I did learn about systemctl switch-root after finishing my kexec solution, but I think if you're at the point of reimaging a server over the network, you probably don't care enough to shut it down correctly :)
astralbijection
·4 か月前·議論
Does it make it more cursed that the distro was built off of NixOS Anywhere, and then it theseus shipped NixOS Anywhere out of it?
astralbijection
·4 か月前·議論
To be honest, even this has plenty of room to go down. I get the feeling I could have squeezed a couple more MB off if I had actually cut things off of the default Nixpkgs busybox, and possibly also cut a couple of kernel drivers out.
astralbijection
·4 か月前·議論
Part 2 presents a fully automated proof of concept that does all of this: https://astrid.tech/2026/03/24/2/how-to-pass-secrets-between...
astralbijection
·4 か月前·議論
From what it sounds like, because you have a console and therefore aren't dependent on SSHD not getting overwritten, you can just dd the live running system here?
astralbijection
·4 か月前·議論
That script sounds extremely unhinged, and I mean it as a compliment :)

Without spoiling too much, the command at the very end of the series does something adjacent to this.
astralbijection
·4 か月前·議論
It does get linked at the very bottom, though admittedly it could be made clearer. https://astrid.tech/2026/03/24/1/swap-out-the-root-before-bo...
astralbijection
·4 か月前·議論
All of those things get covered in parts 2, 3, and 4 :)