Live data from Hacker News

Maestro: A Linux-compatible kernel in Rust

blog.lenot.re

181–190 of 380 posts

Re: Maestro: A Linux-compatible kernel in Rust

#181
post #161
post #108

Earlier quoted context omitted.

Sure, but the benefit from being even partly compatible (same structs with same names, etc -- or maybe some compatibility layer) are great as Linux' devices drivers can then be ported more easily. On one end device drivers in Rust are now possible, OTOH the Meastro kernel. I wonder if there come be a day in my life that I run a non-C-kernel in prod/ on dev laptop.

I hope that there would be architectural improvements possible that would not be realistic for current Linux, and implementing those changes would make also the internals—and thus the kernel module interfaces—look quite a bit different.

Dunno what I hope for more: better internal architecture or more HW compatibility. I think the latter drives adoption more than the first.

Re: Maestro: A Linux-compatible kernel in Rust

#183
post #92

I wonder how far we are from having a GPT-X.Y operating in a loop, creating a fully Linux-compatible kernel with all 437 system calls in Rust within a day, which includes testing, debugging, and recompiling.

I imagine someone could set up a complicated autofeedback loop. Describe the task to the LLM, give a development system and a possibility to run many tests, then let it rip. I still think perhaps not too soon. I think the problem that there are many things to optimize for. One of them is correctness, but if a program runs this does not mean it is correct. Another thing is security. How to test the system for security…

Because there is much more to the linux kernel than maintenance.

Look at things like ebpf and uring for examples of meeting real needs with new development in the kernel.

I doubt that a LLM will be able to come up with the ideas, and implement these things without substantial prompting.

For the every day stuff. Yeah, sure. Though you'd be amazed how many strange corner conditions POSIX and Linux have even around "simple" things like pipes.

... Understanding the whole context may be beyond where we are today based on what I have seen from LLMs, there may day where they can come closer. But as the Klingons say: "Not today."

Re: Maestro: A Linux-compatible kernel in Rust

#184

Earlier quoted context omitted.

It's just silly. I wrote an "imagine if we could trust the kernel as a boundary" and I get 100 posts about the same misconceptions. If people read into my post that I think a Rust kernel would solve all problems, perhaps I was overly simplistic with my language.

People here are overly nitpicky, your language was fine.

I don’t think people are nit picking. The issue of container vs VM security is unrelated to memory safety. So bringing them into the discussion here, even if just in a hypothetical, is odd. You could say the language might be misleading but Occam’s Razor would suggest they’re just conflating the two topics.

Frankly, their comments since (especially those around namespacing) doesn’t do much to convince me that understand the distinction either. So it’s not just the opening post.

The best think they could do in this situation is to ask detailed questions from those that reply, as to why people disagree. Rather than stating they do understand and everyone else misunderstands them, while continuing to post the same misconceptions but phrase differently. At least if they asked questions, there’s a chance they might learn something.

Re: Maestro: A Linux-compatible kernel in Rust

#186

[flagged]

Fantastic words of encouragement! It's always better to do nothing and criticize from the sidelines, right?

My first thought when I looked at this project was the words of one Linus Torvalds more than 30 years ago (and yes, I remember that time) — "I'm doing a (free) operating system (just a hobby, won't be big and professional like gnu)".

I am so happy to see people take on things like that!

Re: Maestro: A Linux-compatible kernel in Rust

#187

[flagged]

95% will be good enough if it offers extra features that people want.

Linux did not have full compatibility before it took off. And I don't think the bar is THAT much higher today for a new competitor, where I can swap the kernel in.

If anything it may encourage us to use a few less Linuxisms in our code.

Re: Maestro: A Linux-compatible kernel in Rust

#188
post #153

Earlier quoted context omitted.

I don't think I've ever seen an argument for why "everything is a file" is a desirable thing. It seems like a kitchen where "everything is a bowl". Fine when you want to eat cereal, mix a cake, do some handwashing up, store some fruit; tolerable when you want to bake a cake in the oven. Intolerable when you've got a carrot in a bowl-shaped chopping board and you've got to peel and cut it using a bowl. Why in principl…

the file is inconsequential. it could be any other universal abstraction, e.g. HTTP POST. it's just something that every program running on a computer knows how to do, so why bother with special APIs you have to link against if you can just write to a file? (note you can still develop those layers if you wish, but you can also write a device driver in sh if you wish, because why not?)

>the file is inconsequential. it could be any other universal abstraction

Bad abstractions are notoriously problematic, and no abstraction is fit for every purpose.

Re: Maestro: A Linux-compatible kernel in Rust

#189
post #179

Earlier quoted context omitted.

The culture around memory safe languages is a positive improvement for programmer zeitgeist. Man though the overreach all the way to "always safe forever" needs to be checked.

serious question: how much additional safety do you get over best practices and tooling in modern c++?

It's not possible for me to say.

Clearly you can only do worse in Rust than you'd have with perfect C. But what's that?

The question is: what is the expected loss (time, bugs, exploits that lead to crashes or injury or death or financial catastrophe) with Rust vs other languages.

Unfortunately that's not the conversation we have. We instead have absolutism re managed memory, which does account for about half of known security flaws that have been discovered and patched. Removing half of bugs in one fell swoop sounds amazing.

It's not that we can't remove those bugs other ways. Maybe modern c++ can cut bugs in half at compile time too. But Rust seems nicer to play with and doesn't require much more than what it has out of the box. Also it's shiny and new.

Given that Rust is making its way into platforms that Cpp struggled into, it's potentially moot. I sincerely doubt Linux will accept Cpp, but we're on the cusp of Rust in Linux.

Re: Maestro: A Linux-compatible kernel in Rust

#190

[flagged]

Reading the introduction in the post makes it pretty clear why it was created...

> I like to dig into complexity, and I like to learn by doing. On top of that, I spend a lot of time on the computer. Wouldn’t it be cool if I had a system that I would know from A to Z and that I could customise as much as I wanted to fit my expectations?

Post reply on HN