Join the discussion

Write your take first — we'll ask for email only when you're ready to publish.

  • Hacker News
  • It's be cool to dual boot with a Linux that has a ~1s boot time, drops you into neovim and lets you save text files to a shared partition.
  • I... fail to see the point of running just one process.

    If it's just a PoC, then:

    1) I remember seeing a linux firewall/gateway set up to run with just the kernel, without any userspace at all. Completely unhackable.

    2) To print some text or run a simple program, I belive DOS without a memory manager would be even faster.

    3) It takes 1s to boot linux, but an ordinary PC takes 10s to get to that linux. Even U-boot on ARM takes some seconds to load a kernel.

    BTW, if anyone knows any current platform that can XiP a linux kernel, please share.

    by M95D
  • I do the “Linux from Scratch” challenge every few years and the last time I did it, I got as far as I needed to be able to build antirez’ LOAD81[1] directly from single mode in a few seconds.. it was so satisfying. I lost the image in some later admin task, but I’m going to do it again, and maybe see about adding threads and SQLite support to LOAD81 alongside the other goodies, just for the fun of it ..

    [1]- https://github.com/antirez/load81

  • As I'm currently exploring kernel build things, the alternative to `make tinyconfig` is `make allnoconfig` which is supposedly will not disable expert options and might be a little bit safer starting point.
  • Tried out doing this kind of stuff a while back to create a custom user space, and I found that suckless’ init, sinit, was quite educational for how to deal with init’s responsibilities in a super minimal way: https://core.suckless.org/sinit/
  • > .. There was a brief moment in the early 2000s where the newly introduced SSDs made booting quick ..

    Anyone else reading this and getting the feeling someone is reminiscing about a past they didn't live and thus are seeing it through rose-colored glasses because it didn't exist?

    In the early 2000s, SSDs had an obscene price tag of ~$1000 per gigabyte, so even an 8GB drive would cost you about $8000. There was nothing for the tech industry to ruin because only 0.01% of people owned a setup with an SSD. And neither Linux, NT or Mach were optimized for them. Hell, to this day Linux' VM system is by default still tuned for swap and slow HDDs (swappiness 60 and all that) because no one has bothered to update the defaults.

  • I went through a similar "thought process" to build this: https://www.endbasic.dev/endbox.html last year. I originally wanted to "just" launch my binary right after the kernel started... but in the end settled for a full NetBSD base system to get things like network and WiFi configuration to work with ease. (That said, I still hook very early in the boot sequence to launch my own program and take over the console so that the rest of the system is invisible and initializes in the background.)
    by jmmv
  • > I found “Building a tiny Linux from scratch” which does most of what I do here but in Rust and a year ago

    Linux from scratch seems to still be doing fine at: https://www.linuxfromscratch.org. It's going on 27 years now.

    > yeah, I know, proper C code needs to be scattered with return value checks and sensible reports of errno. I’ve left these out for clarity.

    Somewhere, a LLM is trained on this code as we speak :)

    But anyway, it's great that people are still interested in learning this stuff for fun.

Explore Birbla archives