Seriously, what do you do with your computer?
Over time 9front sanded off its rough edges. I can do just about everything I need to do from a bare metal install. Today, we even have vmx(1) for hosting OpenBSD or Linux virtual machines (just in case you need to interface with the U.S. government via the now-required modern web browser). A previous release of the 9front DASH1 manual was created entirely on a ThinkPad running 9front (and Gimp running inside OpenBSD running inside
vmx(1)
). 9front now even ships with a primitive Microsoft Paint clone, several native Sega and Nintendo emulators, and a full port of DOOM. I never would have dreamed anything like this was possible back in 2009. As time goes by, there is less and less reason to boot anything else.For what I do, I’m perfectly happy with it.
Clearly not the most typical user, but that doesn’t make their experiences any less interesting.
Very nice. I like Plan 9 myself, when I had a HUGE multi-machine / multi-device network, I used both Plan 9 and 9FS (for Linux) to monitor and regulate everything. At that time my Plan 9 machine was kinda like the master, whereas it pretty-much had root access on my Linux and BSD machines, and Administrator access on my old Windows XP Professional machine. I have not looked at Plan 9 for about 6 years now. Has anything been done with it. How’s vmx(1) running for you? (I liked it, but it did not like Win systems, not that I blame it, lol).
From the article:
With the exception of multimedia and the modern web, all my needs are met. Pretty much anything people do with traditional UNIX terminals can be done at least as efficiently from a Plan 9 window. Even one accessed over SSH from an inferior operating system.
This guy is so full of sh*t that I can’t even.
Yeah, as far as I can see the most popular *nix, Linux, does almost everything native now. No need for virtual machines, to nest other operating systems, for missing functionality.
Plan 9 might be superior as an idea on paper, but when it comes to implementation of a daily driver, not so much.
If you look at the example code for apps (for example, games like Doom), you see exactly why Plan9 has never caught on – it’s shit for an interface for real-world programs. Need to play some background music in your game? Why, it’s a SIMPLE as
if(pipe(mpfd) < 0)
return;
switch(rfork(RFPROC|RFFDG|RFNAMEG)){
case -1:
fprint(2, "I_PlaySong: %r\n");
break;
case 0:
dup(mpfd[1], 1);
for(n=3; nlumpnum);
if(write(0, m->data, n) != n)
sysfatal(“write: %r”);
if(seek(0, 0, 0) != 0)
sysfatal(“seek: %r”);
if(bind(“/fd/1”, “/dev/audio”, MREPL) 0){
if(waitpid() < 0 || write(1, "", 0) name, nil);
execl(“/bin/play”, “play”, name, nil);
sysfatal(“execl: %r”);
default:
close(mpfd[1]);
}
What could POSSIBLY be simpler?
Okay, what the fucking hell is the markup for the site now? I’ve tried markdown, bbcode, and html… nothing works anymore.
JLF65,
That code example is clearly using an external program, and I believe even some of the linux doom ports worked this way. It might be criticism for the doom port rather than the platform.
I tried to download the plan9 source code from bell labs to find the native audio API, but the website seems to be offline:
plan9.bell-labs.com/sources/plan9/
One of the problems with obscure platforms is that there’s no native software available to use the native APIs. For ported software, the native interfaces are typically covered up with layers of emulation and never get used directly. I saw SDL libraries for plan9, so SDL ports are probably straitforward.
Yeah, wordpress uglifies all code by default. I wish it would handle spaces & tabs, but it does not without plugins. The markup it uses is HTML based, but comments are limited to basic text styles and blockquotes.
I know it’s running an external program for the music. Doing the same in Windows, linux, or any of a half dozen other OSes would be a single line. And that was just one example. Look at all the programs – they’re all just as stupidly complex to do really simple tasks. The only way I’d agree to use an OS like this is if they provided an intermediate library to handle all that, like libSDL2. I’d hate to be the guy charged with maintaining that lib.
JLF65,
I think you missed the main point I was trying to make. The external process used by the doom port is an artifact of the port itself, not anything whatsoever to do with plan9. The exact same design is used by some linux doom ports and I’m suggesting that linux doom is probably where the code you reference comes from.
https://doomwiki.org/wiki/Linux_Doom
So, with this in mind, your criticism may in fact have more to do with the port than plan9 itself.
I haven’t yet found more information about the native interface, I’m guessing it’s based on ioctls and piped writes to the /dev/audio device you quoted. The thing I don’t get about your harsh criticism of plan 9 is that if it works this way, it’s actually fairly similar to linux. Do you have the same objections with native linux audio APIs? Note that even on linux most programmers prefer to use a portability library such as SDL.
I think that Plan 9 has some good ideas, but the biggest thing that has held it back is that it is minimalist to the point of being austere and unusable for most people. I think lower layers of an OS should be as minimal as possible while still being sufficiently general, but higher layers should just be properly modular and not duplicate functionality of lower layers, rather than specifically trying to be minimal. That way, people can choose how minimal they want their system to be. That’s what I’m planning to do with the OS that I’m writing.
andreww591,
Although it’s aging now, IMHO plan 9 was a more refined version of unix and would have been nice successor to unix. By then though unix was too big in terms of market share and commercial support and no one was able to displace it aside from linux, which explicitly aimed to be a unix clone.
Good for you. It’s good experience, depending on your goals. For better or worse, most who go down this path in the past few decades encounter the same obstacles and outcome. You get to design OS interfaces the way you think they should be, which is awesome, but in the end it won’t really matter because nobody actually uses them. More than anything else, the users of your OS need software, so you end up needing to support posix & linux APIs for software portability. From there on out few people benefit from your hard work under the hood, it becomes abstracted away behind compatibility APIs.
There’s still plenty of innovative potential for new operating systems, but I get frustrated when, through sheer necessity, it ends up looking more and more like a POSIX platform. I don’t really have a solution for this. Personally I gave up developing my own OS and joined linux because that was the most pragmatic thing to do. Actually I got into windows kernel development first, but I won’t go into that, haha.
I’m very well aware of the importance of compatibility with legacy OSes. My OS (https://gitlab.com/uxrt) will be highly compatible with Linux (and conventional Unix in general) despite being based around a file-oriented architecture akin to that of Plan 9 or QNX. Basically all the non-file-oriented primitives of conventional Unix will be implemented as library functions on top of special files, and won’t require programs to run in some sort of compatibility environment. New APIs and commands won’t be added unless there is a good reason (usually because they are for features absent from conventional Unix), and the old APIs/commands usually will still continue to be fully supported. The only real compatibility layers will be a Linux binary compatibility layer (which will be relatively simple since most Linux-specific APIs will be implemented natively) and a port of LKL (https://github.com/lkl/linux) for compatibility with Linux drivers. Many of the benefits of the new architecture will still be available to programs that were only written for conventional Unix.