-- Leo's gemini proxy

-- Connecting to ew.srht.site:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

2023-11-09

Re: Small Operating Systems?

tags: software



Inspired by Jeff's reply to Christopher's post about small operating systems, I decided to pin down what little I know, in the hope that it may be useful.

gemini://gem.librehacker.com/gemlog/starlog/20231019-0.gmi

local copy

gemini://gemini.sh0.xyz/log/2023-11-07_re_small_operating_systems.gmi

local copy



Prolog


I have been using Un*x type operating systems since at least 1990. Privately I have always been using some sort of GNU/Linux system, Debian for the most part. But I have gotten a growing, albeit faint feeling, that Linux (both the kernel and the distribution ecosystem) is increasingly facing the risk to drown due to its own weight.


Linux the kernel


Linux the kernel is a big project, it carries quite a bit of baggage around (like why are network interfaces fundamentally different from items represented by device files?). The things that make me very uncomfortable are eBPF (which seems to be a virtual machine inside the kernel, running with kernel privileges) and the integration of Rust (I'm afraid of the day when I do need a rust compiler to just compile the kernel). I will readlily admit that Linux the kernel is a phantastic piece of software, and it has helped me time and time again to get my things done --- including but not limited to typing this post. I'm just a bit uneasy about the things mentioned.


Linux the ecosystem


Linux the ecosystem of countless distributions is a lot bigger, several orders of magnitude, I guess. However: When I started to use Linux (Suse 6.3) the whole thing fit comfortably onto a system with diskspace less than 1 GiB. I switched to Debian potato a bit later on that same machine. If I try to install Debian today, even without a big GUI management system (just with xorg and i3), I need several GiB of diskspace just for the operating system. Of course using tex-live or KiCAD eats away on diskspace fast, and of course 100 GiB of disk space is readlily available today --- but it makes me wonder.


In my (maybe not so humble) opinion the quest to make things work automatically, always, wherever, accompanied by the quest to make things look really cool and pretty --- both add to the neccessary disk space and cpu cycles quite a bit. Again, I am extremely grateful for all those restless souls producing all those little and big wonders, which together form my current Linux workstation. But I feel a bit uneasy about the complexity and the mindboggling size of it all.


So once in a while I set out to scan the visible to me web for efforts to radically size down, and still make me feel comfortable on such a system. Now "small" has very different meanings to different people, so for me a useful system would have the equivalents of bash and emacs plus a webbrowser, of course.


Small Operating Systems


Linux: At dayjob I can construct special Linux systems of a few 10 MiB in size (think embedded). I'm not convinced I would like this on my workstation. There are small distributions like tiny core linux or puppy linux.

http://tinycorelinux.net/

http://www.puppylinux.com/


AlpineLinux: I have tried alpinelinux on notebooks, and I am impressed by it. It is still Linux, however, it is a lot smaller. I can install a fully functional system without perl, python, ruby and the like! It uses an alternative implementation of the libc named musl, busybox rather than the GNU core utils, and the openrc init system rather than systemd. It is a very nice system in my opinion.

https://alpinelinux.org/


OpenBSD: some time ago I made a few experiments with that. I can use it without problems given that I am used to the shell. But it is a bit too slim for my taste to reside on my workstation. There are more variants of BSD to be explored.

https://www.openbsd.org/

https://en.wikipedia.org/wiki/Comparison_of_BSD_operating_systems


Minix3: a few years ago I played with that, but I don't remember much.

https://www.minix3.org/


GNU/Hurd: yes well, it might still be "not dead", and many years ago I even managed to install Debian with the Hurd kernel. Again, it is too long ago to say something useful.

https://www.gnu.org/software/hurd/


At FOSDEM there has been a developer room dedicated to microkernel systems for several years now. These talks offer a lot of information and insight, and I can only recommend to scan the archives.

https://fosdem.org/2023/schedule/event/microkernel2023/


Genode/SculptOS: If I understand it correctly, Genode is a framework on which operating systems can be built. It enforces capability management, e.g. if a process is forked, the calling process must give up some of its recources (memory, cpu cycles) to allow the new process to run. I have played with SculptOS, it works, and it can run a separate Linux in a container. So it can be useful. I admit that I did not get far.

https://genode.org/


Other microkernel systems: HelenOS, managarm, redox-os, ares-os in various stages of usability. There must be more.

http://www.microkernel.info/

http://www.helenos.org/

https://github.com/managarm/managarm

https://redox-os.org/

https://ares-os.org


plan9 by Bell Labs: This operating systems has spawned a number of derivatives, it seems. Check the wikipedia page for inspiration.

https://en.wikipedia.org/wiki/Plan_9_from_Bell_Labs


Forth/collapseOS: this is a tiny system running on microcontrollers like the venerable Z80. I do use Forth regularly, and I could also say "install Forth and be done". But the practical value of such a thing is rather limited, unless you take pride in programming all of your applications yourself. However, Forth based systems have their niche where they are useful.

http://collapseos.org


ConTiki by Adam Dunkels: this is an operating system for 8-bit CPUs. It weighs in at a few 100kiB or smaller. Definitely something to check out. There is a "new generation" effort going on as well.

http://www.contiki-os.org/

https://github.com/contiki-os/contiki

https://github.com/contiki-ng/contiki-ng


Serenity OS by Andreas Kling: a fairly new effort with interesting choices.

https://serenityos.org/


Inmos Transputers? They had some operating system, I'm sure. The programming language was called occam, it seems. These things were pioneering parallelism and other concepts in the 1980. Allthough I knew a place with such systems, I never got my hands on one.

https://en.wikipedia.org/wiki/INMOS_Transputer



Epilog


Writing an operating system from scratch is possible for a person. Producing something that can be used daily even only for its creator is a big effort. There are probably many such projects, e.g. VSTa (Valencia's Simple Tasker). Check out the list of operating systems on wikipedia for more inspiration. And lastly, search for "small linux" on distrowatch, you will find Redox, Risc OS, ReactOS, and many more.



https://en.wikipedia.org/wiki/VSTa

https://en.wikipedia.org/wiki/List_of_operating_systems

https://distrowatch.com/

https://www.redox-os.org/

https://www.riscosopen.org/

https://www.reactos.org/


Cheers,

~ew


Home

-- Response ended

-- Page fetched on Thu May 2 18:13:05 2024