6 ms·
From my understanding, the microkernel approach has been deemed impractical for real-world use. I wonder if there is anyone out there using it?
by scorpioxy 11y ago
From my understanding, the microkernel approach has been deemed impractical for real-world use. I wonder if there is anyone out there using it?
- Avshalom 11y agoTo swipe a line from Chesterton: micro-kernels have not been tried and found wanting, they have been found different and wanted trying.
- tomcam 11y agoMore quotes for Chesterton are needed in this (literally) godforsaken place. Actually, more quotes from Chesterton are needed just about everywhere...
- tomcam 11y agoDownvoted? I thought atheism was A Good Thing with the HN hive mind.
- drdeca 11y agoI'm not totally sure what you mean. I would not expect an atheist to consider themselves "God forsaken", and I would not be surprised if one was kind of offended by being called that. (I myself am not an atheist, ftr) Given that,I am not sure why you would be surprised that people reacted negatively?
- mindcrime 11y agoI imagine you got downvoted because this thread is neither about Chesterton nor about atheism. HN culture is generally not very tolerant of threads that deviate into things that aren't at least tangentially related to the main topic-at-hand.
- nickpsecurity 11y agoIt took decades to get UNIX's reliable enough to trust for day to day operation with labor estimates in hundreds of millions to billions of dollars. Three or so people got that done in a few years with MINIX 3 using micro-kernel architecture and self-healing services. QNX and INTEGRITY RTOS's have been doing that stuff for years in the field with less resources. And QNX-based Playbook was more reliable, responsive, and fast than iPad in its first incarnation. Before that, KeyKOS outperformed IBM's monolithic stuff on their mainframes with better security and full persistence of system state. So, they worked better and keep working better. People just use monolithic kernels for some reason. Just like they took forever to get off of C for reliable, business applications. "Worse is better."
- Rusky 11y agoDo you mean for GNU Hurd specifically, or just microkernels in general? Because there are several microkernels in production use if you look beyond desktop OSes.
- slacka 11y agoI doubt the engineers at Blackberry would agree with you when they chose the QNX microkernel as the basis of their next generation OS. Also I never heard any complaints about AmigaOS’s or Symbian's microkernel design as being impractical.
- lobster_johnson 11y agoAmigaOS never implemented any memory protection, did it? So it hugely favours a microkernel design, since there's no expensive context switch to translate a call into kernel mode; everything is user mode.
- ZenoArrow 11y agoWhilst you are correct in that AmigaOS didn't implement memory protection, it's possible to argue that wasn't by design. The original design for AmigaOS was known as CAOS. The CAOS design included resource tracking, which I believe is a useful feature when it comes to implementing memory protection. If I remember correctly what ended up happening was the microkernel for CAOS was developed in-house (Exec), but contractors were being paid to develop the rest of the OS, and they disagreed with the design decisions of CAOS and wanted to make it more Unix-like. Once the Amiga team realised the contractors had wasted time developing something different from what they intended, they sought out an alternative solution to replace the user-space side of the OS. As a result they contracted a different team to rework an OS called TripOS to use the Exec microkernel (that was originally intended for CAOS), which then became the AmigaOS that Amiga users know. You can read a bit more here: http://www.amigahistory.plus.com/caos.html http://www.amigahistory.plus.com/caos.html
- nickpsecurity 11y agoQuark microkernel in MorphOS https://en.wikipedia.org/wiki/Quark_%28kernel%29 https://en.wikipedia.org/wiki/Quark_%28kernel%29 MorphOS - quite fast and usable :) http://www.morphos-team.net/intro http://www.morphos-team.net/intro So, out with the old and in with the new.
- jsmith0295 11y agoNot all microkernels. There are many newer ones which have much better performance characteristics of their predecessors. Mach, however, has rather slow IPC, which would be a problem for Hurd.
- lobster_johnson 11y agoQNX [1] is probably being the most successful and most mainstream example of a microkernel in real-world use. It's extremely popular for embedded use and/or apps with real-time demands, most famously in nuclear power plants. I've never used QNX myself, but I believe people also run full desktop environments on top of it. [1] https://en.wikipedia.org/wiki/QNX https://en.wikipedia.org/wiki/QNX
- david-given 11y agoI've used the desktop version. It's amazing: it looks, and feels, and operates, just like a Unix, except if you want it it's got this ultra-fast real-time core. When I say 'just like a Unix', I mean: you log in and start up some terminal windows and it's sh and you can compile and run X11 software with configure scripts and gcc and you can print stuff with lpr and it all just works. It even runs Java --- my copy was completely self-hosting via Eclipse! Years ago there was a single-floppy QNX demo disk: you booted from this and you got a basic desktop with dialup modem support and a web browser. SINGLE FLOPPY. Hey, look! I was all set to write a paragraph about how sad it was that you couldn't get the bootable QNX CD any more, but look what I found! http://www.qnx.com/download/feature.html?programid=19602 http://www.qnx.com/download/feature.html?programid=19602 It doesn't even need registration and a login any more! Holy crap, I have to see if this still works... Edit: looks like it won't install without a license key. I'll see if I can get one... Edit: apparently I have an account with QNX dating back from 2012, with three hobbyist license keys, one of which makes the installation CD happy. I don't know whether these are still available, though. Edit: so it installed into a VM in about two minutes flat, and I now have a very old copy of Firefox running. It can't see the network, but that's nothing to do with QNX and everything to do with my inability to set up kvm. I need to find a real machine to run this on. Edit: it will only install from CD, not from USB (unetbootin doesn't help). And I've lost the power cable for my CD burner. So until I find it, I won't be able to proceed here. Sorry. Still good to know this still exists, though...
- tomcam 11y agoThey have a license for evaluation & noncommercial use. http://www.qnx.com/legal/licensing/non_commercial.html http://www.qnx.com/legal/licensing/non_commercial.html
- _rook 11y agoBoth Qualcomm and Apple are known to run variants of L4, a microkernel, on their mobile hardware: https://en.wikipedia.org/wiki/L4_microkernel_family#Commercial_deployment https://en.wikipedia.org/wiki/L4_microkernel_family#Commerci...
- nickpsecurity 11y agoAnd Samsung uses INTEGRITY Multivisor in KNOX. http://www.ghs.com/products/rtos/integrity_virtualization.html http://www.ghs.com/products/rtos/integrity_virtualization.ht... Multivisor is kind of a combination of the INTEGRITY RTOS and virtualization stuff. The leader in this kind of stuff was OKL4 like in your reference, though. General Dynamics supplies their stuff now due to acquisition.
- agumonkey 11y agoAs other said, QNX is used, in a lot of places. The microkernel issues raised in the 90s have been addressed partially at least (I'm just a noob) in the L4 mkernel family. Minix v3 too IIUC.
- vezzy-fnord 11y agoYour understanding is, I'm sorry if this comes across as hostile, absolute nonsense. You should actually consult the literature instead of reading Linus Torvalds rants. Back in 1990, the Amoeba system revealed 2x improvement in throughput and 5x improvement in latency for its RPC over the SunRPC of the time. [1] Relative measurements for the V-System and Sprite were similar. QNX, a microkernel-based system with high commercial success and a long history (used by over 40 automotive manufacturers) has highly fast IPC by integrating message passing with the CPU scheduler. After years of research, Jochann Liedtke introduced L4 in 1996 [2] using only seven generalized calls with a 20x improvement in speed over prior art such as Mach. Mach, by the way, is the glaring exception to microkernel performance because of complicated message packing and port rights checking. Yet the Hurd developers are doing well in optimizing it, and to this day Mach is used to malign microkernels by people with no background on the subject. OKL4, in turn, has shipped in ~1.5 billion devices by 2012, powering the baseband processor behind nearly every mobile phone. [3] MINIX 3 further only shows a ~5-10% performance drop relative to monolithic Unixes, this for 2006. [4] They never learn. [1] http://www.scs.stanford.edu/nyu/03sp/sched/amoeba.pdf http://www.scs.stanford.edu/nyu/03sp/sched/amoeba.pdf [2] https://homes.cs.washington.edu/~bershad/590s/papers/towards-ukernels.pdf https://homes.cs.washington.edu/~bershad/590s/papers/towards... [3] http://www.creativemac.com/article/OK-Labs-Software-Surpasses-Milestone-of-15-Billion-Mobile-Device-Shipments--1842548 http://www.creativemac.com/article/OK-Labs-Software-Surpasse... [4] http://www.minix3.org/doc/ACSAC-2006.pdf http://www.minix3.org/doc/ACSAC-2006.pdf
- caycep 11y agoas an aside, how is Mach doing these days? I suppose the most visible use is OS X and I assume Apple's engineers have evolved it greatly to keep up with the times compared with the earlier versions of OS X?
- vezzy-fnord 11y agoApple's XNU is de facto monolithic in nature. It simply reuses OSF Mach primitives to build the BSD Unix layer next to it. Mach IPC is used primarily for service discovery these days, I think, what with launchd being responsible for being the bootstrap server, which maintains name-port bindings for Mach services to call into. This is a side effect of Mach port namespaces being internal to tasks, and hence not having an intrinsic arbiter. In contrast though, the Hurd decentralizes this activity by just assigning a bootstrap port for the client making the RPC call to rendezvous with the server or library in question. These days, OS X seldom uses Mach IPC directly, but rather via XPC. Mach had a surprising resurgence in interest over NextBSD implementing a ton of compatibility layers and mangling Apple sources in a weird, misguided attempt to make FreeBSD the new OS X. We'll see how it turns out.
- kryptiskt 11y agoYour phone likely has a L4 microkernel running the radio. There are millions and millions of microkernels out there running all kinds of things, going where Linux fear to tread.
- technion 11y agoI'm surprised that something so incredibly prevalent is so rarely discussed.
- techdragon 11y agoMuch of the tech community views this as "settled" thanks to the Linux versus Tannenbaum debate. Microkernels aren't going away any time soon. :-)
- technion 11y agoOh I know - I meant more "running L4 kernels", with the seL4 currently looking quite interesting. At what point do you conclude that you're: * running everything in hypervisor X, thus hardware support doesn't matter * running only servers, thus desktops don't matter * and thusly, may stand more to gain from an environment that never catered to the above two?
- skykooler 11y agoMac OS X is based on the Mach microkernel. I would think that counts as real-world use.
- lobster_johnson 11y agoXNU (OS X's kernel) doesn't really use Mach as a microkernel. It supports user-mode device drivers, so you might call it a hybrid microkernel, but practically speaking, it's a monolith just like Linux; everything of practical relevance (file system, graphics, most disk and networking I/O) runs in kernel mode. Some parts (high-level USB, Bluetooth, power management, etc.) run as user-space processes, but they talk to kernel-mode device drivers. (XNU was inherited from NeXT, which was based on Mach 2.5, which was actually not a microkernel at all.)
- artlogic 11y agoI think a lot of the common idioms passed around about microkernels stem from the old Torvalds v. Tannenbaum argument [1]. It wasn't that Torvalds was right and Tannebaum was wrong. It was simply that Tannenbaum had reliability and theoretical correctness in mind, while Torvalds was concerned with performance. The less context switching you do, the more performant your computer will be. We can take this to the extreme and look at OSes like TempleOS [2] where EVERYTHING runs in kernel mode. Most people prefer a bit more reliability, and so modern desktop kernels are generally hybrid kernels (with the notable exception of Linux which is, of course monolithic). I don't think there's any real technical reason a microkernel couldn't work on today's hardware which is many orders of magnitude faster than what we had in 1992, but a hybrid kernel is always going to be faster. [1] https://en.wikipedia.org/wiki/Tanenbaum%E2%80%93Torvalds_debate https://en.wikipedia.org/wiki/Tanenbaum%E2%80%93Torvalds_deb... [2] http://www.templeos.org/ http://www.templeos.org/
- lobster_johnson 11y agoI always found it interesting how much Intel's protection ring architecture dictated the direction of operating systems back in the 1980s. (I'm sure Intel didn't even invent it; similar concepts were probably already in place in mainframes?) x86 has highly specific support for protection rings and switching between them, as well as things like page faulting and interrupt management, leading to the classic kernel/user split with a kernel as a privileged actor underneath a user mode. But having just one exclusive, reserved "kernel mode" is starting to look old, which is why there's now so much talk about virtualization and exokernels and so on. The microkernel design certainly seems very elegant, but it looks to me like Intel's architecture was always a stumbling block. You have to wonder about what hardware support you could invent that would make microkernels a better fit.
- marcosdumay 11y agoTake a look at the Mill's security presentation. It's an architecture where there is no real border between a monolithical kernel and a microkernel. It's just differences on access control policies, to the point that those names lose their meaning. As always, it's a very interesting architecture. I hope they produce it someday.
- nickpsecurity 11y agoIn his defence of them, Tannenbaum mentions a lot of companies using microkernels for high-reliability applications: https://www.cs.vu.nl/~ast/reliable-os/ https://www.cs.vu.nl/~ast/reliable-os/ For consumer devices, the Blackberry Playbook was one of the better examples given it was built on QNX microkernel for reliability and nobody was complaining about its performance (i.e. doing two games at once). Lots of phones have microkernels in them to isolate baseband from problems in main OS. Did you know you were using a virtualized OS message passing to other components? I didn't either until I saw the vendor's press release. They might be efficient after all. ;) Here's one used a lot in safety-critical and security-critical apps with nice security architecture: http://www.ghs.com/products/rtos/integrity.html http://www.ghs.com/products/rtos/integrity.html The beautiful and efficient MorphOS uses a microkernel: http://www.morphos-team.net/intro http://www.morphos-team.net/intro One that was made for capability-security model with FOSS code: https://web.archive.org/web/20070428020436/http://www.eros-os.org/eros.html https://web.archive.org/web/20070428020436/http://www.eros-o... Note: See their papers and KeyKOS especially, as it was first successful one on IBM mainframes of old. GenodeOS and MINIX 3 are the best efforts to look at in FOSS today as they're actively maintained. Not at Linux feature set or stability yet given almost no staff haha. Already on bare metal and hosting apps/desktops, though. Just don't think stuff like Hurd is representative of microkernels in general. It's just a failed GNU project. ;)