Cosmos: An open-source .Net-based microkernel OS is born

Cosmos: An open-source .Net-based microkernel OS is born

Summary: Move over, Microsoft Singularity. There's another microkernel, C#-based operating system in town. And this one's available under an open-source license.

SHARE:

Move over, Microsoft Singularity. There's another microkernel, .Net-based operating system in town. And this one's available under an open-source license.

Cosmos: An open-source C# microkernel OS is bornKnown as Cosmos, the new, independently developed operating system (OS) is the brain child of former Microsoft Developer and Platform Evangelism team member Chad "Kudzu" Hower. Unlike Singularity -- version one of which Microsoft released last year (and only to university researchers and academics) -- Cosmos is available to anyone, Hower said. The developers released Milestone 1 of Cosmos at the very end of January.

From the Cosmos Frequently Asked Questions (FAQ) document, which asked "Why Develop Cosmos?":

"Primarily because it's fun. But beyond that, how else can you boot .NET on a floppy or small USB stick? Who else will try to put .NET on the Wii, OLPC (One Laptop Per Child PC), and iPhone?

"We are also developing a TCP/IP stack. Imagine instead of deploying half a dozen virtualized OS's, deploying many dozens of dedicated OS's. One that only does DNS, a few that only do HTTP, etc. One instance, one function."

Cosmos comes with a compiler (IL2CPU) that compiles the resulting intermediate language (IL) to X86 code. The compiler includes a cross-platform-support layer, and the Cosmos team says it plans to add support for other processors and platforms, including x64. Developers can use any .Net language to write to Cosmos.

I had a chance to ask a few additional questions of Hower via e-mail. Here's our exchange:

MJF: What is Cosmos?

Kudzu: Cosmos (Its only upper case C, ie not COSMOS or CosmOS) is an acronym for C# Open Source Managed Operating System.

MJF: What's a one-sentence, layperson's definition of Cosmos?

Kudzu: Cosmos is a set of operating system legos written completely in C# that allow developers to easily build custom OSes with little OS experience by simply selecting new project in Visual Studio, then pressing F5 to build, deploy, and debug.

MJF: What, if anything, does Cosmos have to do with Microsoft's Singularity, an operating system developed by Microsoft Research that written entirely in managed code?

Kudzu: It certainly has a lot in common with Singularity. But unlike Singularity, Cosmos is publicly available now with full source code. Anyone can try it and participate. We have cross-platform plans. So this will allow us to also run Cosmos on the Wii, iPhone, etc.

MJF: Cosmos is an open-source project hosted on Microsoft's CodePlex repository. How does that work, in terms of you retaining your independence?

Kudzu: Cosmos is an independent project from Microsoft. I'm a former Microsoft FTE (full-time employee) myself and still heavily involved with Microsoft as I am Microsoft Regional Director, but Cosmos is independent. Cosmos is licensed under the BSD license though, so generally there are no issues....We are free to support anything we want.

MJF: Is Cosmos written entirely in managed code (like Microsoft's Singularity is, I believe)? If it is, why did you go this route?

Kudzu: Singularity actually has a fair bit of C or C++ down in the core. Cosmos is 100% C#. The only assembly is emitted by our compiler.

MJF: Is Microsoft helping or supporting Cosmos project in any way?

Kudzu: Not currently. We just went public very recently. There has been a lot of independent interest from Microsoft. What I mean by this is not the dev groups, but the evangelists are really grabbing on to it and helping spread the word. When I was with Microsoft I was in Developer Evangelism, so I understand why. Its "super geeky" and so its really interesting to developers of all types.

Topics: Software Development, Microsoft, Open Source, Operating Systems, Software

About

Mary Jo has covered the tech industry for 30 years for a variety of publications and Web sites, and is a frequent guest on radio, TV and podcasts, speaking about all things Microsoft-related. She is the author of Microsoft 2.0: How Microsoft plans to stay relevant in the post-Gates era (John Wiley & Sons, 2008).

Kick off your day with ZDNet's daily email newsletter. It's the freshest tech news and opinion, served hot. Get it.

Talkback

107 comments
Log in or register to join the discussion
  • awesome...another alternative, lightweight OS

    Microsoft ought to rebuild Windows on top of its stripped-down kernel so that Windows can run efficiently with fewer resources.
    killerbunny
    • They are, It's called Windows 7.

      ;-)
      No_Ax_to_Grind
      • Microsoft Troll

        Look at No_Ax, who can only learn Microsoft stuff, because he's too stupid to learn anything else.

        Who can spell "paid for Troll"?
        fr0thy
        • "paid for" troll?

          Funny - the trolls are always somehow "paid for". Wonder when I can get into some of that action.
          daftkey
          • LOL. Me too ;-)

            Maybe 2008 is the answer?
            fr0thy
        • who cares

          you dont need anything else...

          really thats true.. whether or not you agree with me is irrelevant.
          pcguy777
          • Like bottled air

            Pig ignorance such as displayed by yourself would be buying the stuff, believing that you couldn't live without it. Way to go ;-)
            fr0thy
          • Actually, it's more like bottled water

            You can get free water from the tub, but some of us prefer to pay for the sparkling bottle of water, in my case that would be MacOSX.
            royalstream
      • Yeah, that'll really be lightweight.

        Vista requires 1GB RAM, 40GB HD with 15GB free, and a minimum of 128MB graphics memory.

        I'm running Ubuntu on 256MB RAM, 20GB HD with 387MB of free space left, and an old i815 graphics card. Everything runs smoothly, and will continue to run smoothly even if I have 0MB left. To be fair though, I do have a 384MB swap partition. Ubuntu is one of the more bloated out of the Linux distros too.

        Let's face it. Microsoft isn't exactly the expert on being lightweight.
        Amaroq
        • Well, you might be wrong this time.

          http://en.wikipedia.org/wiki/Windows_7
          <br> <br>
          Here is the part on MinWin and what is cooking for win7. Italics and emphasis mine.<br><br>
          Incidentally, the name MinWin was also used earlier to refer to what is currently known as Server Core in Windows Server 2008.[15][17] However, the two are quite different. While both efforts are to consolidate and componentize the core of Windows, with server core, the functionality of the OS is constrained according to server roles, and unneeded components (which will never be used as the role isn't supported) are removed from the binary image. However, the dependencies still exist in code, and the code cannot compile without the components. <b><i>In contrast, with MinWin, the dependencies are consolidated into MinWin and what is not needed is removed at the code level itself. As a result, the code compiles even without any extraneous components and builds a stripped-down self-contained OS kernel image.</b></i>
          xuniL_z
    • This is already happening

      If you look at what Vista contains, as well as XP, and many new APIs, you'll immediately see that most of the recent additions to Windows now depend on a "Managed" subsistem.

      Microsoft is already porting Windows progressively on this base core of APIs, and is already deprecating the Win32 API by putting its documentation far way in MSDN from develoers views. All gets modeled now after .Net and for .Net, even if it finally runs on Win32, but the dependancy of those APIs on Win32 is already decreasing at high speed.

      Win32 gets progressively moved to a lower layer, and its API is now alsmost completely freezed (with the exaception of security bugs that are often solved by rewriting part of it with a managed subsystem.

      This is also true for device drivers, that are now developed with mini-drivers running in user space with stronger isolation from the OS: the OS provides a generic driver that integrates all the others.

      Next generation versions of Windows will run in a VM as well as the applications "plugged" into it and more easily manageable and deployable. There won't be however a revolution, like restarting from scratch from a micro kernel, instead most OS services will progressively be migrated by splitting them in several layers with less cyclic dependencies, and finally some lower layers (specific to some old architectures) will be removed when they are no longer needed to support the upper layer.

      I think that Win32 is now in end of life, and usage of .Net within Windows is constantly increasing. Most applications will no loger depend on Win32 if you follow the upgrade path already strongly suggested by the MSDN documentation.

      Yes, initially, there's a performance cost when porting your application to some VM, but the cost is already small enough and rapidly compensated by the fact that applications already have to run on PCs with very wide differences in terms of performance and capabilities.

      So what is important? Getting the maximum performance on a single host with a single CPU core, or getting the maximum performance on a large and extensible platform with networking capabilities, that still has many unused resources that a VM could harness to offer much better scalability and better integration, focusing on user demands on the platform as a whole instead of just on a single device?

      Just look at your home environment: there are now computing resources everywhere in many products. Electronic and processors are present everywhere. Why can't they collaborate to create a much more powerful platform with more versatile use and from everywhere?
      PhilippeV
      • Nice commercial....

        ...exactly in the line of those .NET MS ads.
        alf5
        • Jealous...

          Because they did their homework. Let me Guess - MAC Boy (said with a very feminite accent) or Linux...which is it. You need another forum.
          ItsTheBottomLine
      • Both are important

        "So what is important? Getting the maximum performance on a single host with a single CPU core, or getting the maximum performance on a large and extensible platform with networking capabilities"

        Actually, which one is important depends on the individual or business. An individual who has only one computer will not need the extensible platform. The same goes for a small business which does not have a LAN.
        However, for businesses that do have LANs or use client/servers then the networking platform option could be more attractive. One solution is not going to fit everyone's needs.
        alaniane
      • This is already happening

        >>>If you look at what Vista contains, as well as XP,<<<

        Tes, all of that spaghetti is nice.
        joe6pack_z
      • Right on the mark !!

        What you say at the top of your post is right on the mark. And I'll add one thing to it.

        The looming end-of-life for the VB IDE is another important step taken by Microsoft toward ending a historically-rooted RAD tool rooted in the VB run-time which is further rooted in the Win32 API.

        By eliminating official support for the VB IDE, they take a huge step in discouraging further COM-based development and hence the Win32 API.
        SteveChaille
  • Zzzzzzzzzzzzzzzzzzzzzzzzz.....

    "[b]<enter OS Name here>[b] can't hold a candle to Linux."
    D T Schmitz
    • Your post is almost as boring as you.

      But not quite...
      No_Ax_to_Grind
      • You are just too funny

        nt
        D T Schmitz
      • No_Ax is sooo boring

        that he can only ever read, learn and consume something that say "Microsoft" all over it. How dull is that? Linux scared you 'cos you're not remotely clever enough to use it?
        fr0thy