The Design and Implementation of the FreeBSD OS
n0dez writes "Peter H. Salus has written a review of The Design and Implementation of the FreeBSD Operating System on UnixReview.
"If you need to understand just how a kernel works, you need this book. McKusick and Neville-Neil have done the community a favor, and this book deserves to be a best seller." This book is an update to The Design and Implementation of the 4.4BSD Operating System by Marshall Kirk McKusick."
I was considering getting the 4.4 version of this book so I'm glad I waited. I've been working through the Tanenbaum OS Book and it's a bit dry. I've been working through the 2.4 Linux Kernel as well. It's amazing the quality that goes into these open source offerings.
I just wish someone would make a linux distro that is more like OS X. It would bring Linux to the desktop faster and give grandma an interface she could easily understand.
However, no amount of hinting got me this as a birthday present.
However, my gf *did* get me a mess of other cool stuff- a new GeForce video card, a pile of video games for PC and PS2 (she's always telling me that i need to play more games....), some Lego...
No worries though.. I'm sure to pick this up myself anyways.
do() || do_not();
I don't know about this new FreeBSD-specific book, but the previous 4.4BSD book (also by McKusick, etc.) was a combination of code and design explanation. I didn't read the whole thing, but I used much of the book for a term paper about FreeBSD's design a year ago, and probably 80% or so of the book was design info, not code.
:)
That makes sense too -- after all, the code is bound to be changed sooner or later, making the book out of date, even though the same design principles may be in-use. This was a good move on McKusick's & Co's part, b/c much of the information they published back in 1996 still applies even today to FreeBSD 5.x (that said, 5.x is definitely a major change, particularly w.r.t. the process scheduler).
Go to a university library if you want to find a copy without buying it. Most normal public libraries won't have a copy (alternatively, you can hang out at Borders or Barnes and Noble and browse through it there).
Speaking from experience though, if you want a "book that explains the guts" without forcing you to read reams of code (and why would you? The source is available online for free to read instead!), then you want McKusick, etc.'s book (I imagine this new FreeBSD-specific book is similar to the 4.4BSD book).
I looked hard (as in, for the better part of a semester) -- there simply is not a more-comprehensive BSD OS-design reference anywhere. And yes, I got an 'A' on my paper (updated from the 4.4BSD's era to include FreeBSD-specific info, including through FBSD-5.1, however).
Is Capitalism Good for the Poor?
For the most part the book presents the organization and major algorithms used in FreeBSD, and then presents the theory and rational behind the choice. It also presents some alternative implementations that could have been used and explains why they weren't.
As far as code, I don't think there's a single line of it in the book.
"I'm looking at running a modified linux kernel on x86, x86-64, PPC & Itanium"
Assuming your goal is to create a pretty desktop OS like OS X, why would you run it on Itanium? Itanium is designed specifically as a "RISC killer" for high-end RISC/UNIX shops (and it's failing miserably, I might add). To my understanding, OS X Server isn't even the same code-base as normal OS X. Supposedly it's more NeXTish. The point is that Apple's servers don't really run the same OS that their desktops and laptops do.
It always strikes me as funny when Linux people whine about the lack of a Linux distribution that works like OS X. Hmmm, maybe that's because Apple pays developers market wage to create their interface, rather than relying on community contributions by random, unaccountable people? Also, it seems that the Enlightenment WM is really supposed to mimmic OS X, so perhaps the lament should be "I wish there was a WM..." rather than "I wish there was a distro...". Besides, if you recognize that OS X is so much better, why don't you just buy a system with OS X? Do you not believe in paying for quality, or should everything just be handed to you on a silver platter?
Then again, that's the problem with the Linux community. Instead of contributing towards a common project and common goals, everyone goes off and totally duplicates the effort of everyone else. You end up with dozens of WMs, dozens of text editors, dozens of e-mail clients, a dozen web browsers, hundreds of OSs (that's what a distro is, after all) and not ONE of them approaches the quality of a commercial OS.
If free software is ever going to approach the quality of commercial software, people have to stop this assinine "I'll start my own ___" mentality and learn to work in productive teams. The Apache web server and OpenSSL should be examples of how to do things. There aren't 10 different common SSL implementations in Open Source.
Getting slightly back on topic, BSD should serve as a good example for how to do OSS right. Have large groups of developers working on an integrated project, i.e. a whole OS. Pick one default for everything, and don't duplicate effort all over the place. There are only really four free BSDs (Dragonfly, Free, Net, Open) and they share code heavily. The default installations have one sane selection for each task, and you can add more from ports if you really, really feel like it. Development is a lot more cohesive and as a result, the BSD releases tend to work a lot more reliably. Imagine that!
Someone is WRONG on the Internet!
I'm nitpicking, but there *is* code in "The Design and Implementation of 4.4BSD."
See page 233 which has C source for checking access permissions for a file ("int ufs_access(ap)", etc.).
There's not much code; as you say, the code that is there is mostly C-style P-code to explain the algorithms. But there still exists some code...
Is Capitalism Good for the Poor?
This one? If so, note that the OS X Server releases starting with the one labeled "Mac OS X Server 10.0.3" have arrows from the OS X client line. The earlier OS X Server releases didn't have an Aqua GUI - they had a more Mac-like GUI (more Rhapsody-derived).
Exactly. It's talking about one of the old OS X server 1.x releases that came out before the client OS X 10.0.
Perhaps those other sources think OS X Server is still more like the older 1.x releases, without all the stuff added on the client side since then, including the Aqua GUI (or are old source from when it was one of the older 1.x releases).
The Mach stuff that's generally visible is mainly the object file format; that stuff is present in both client and server, as is the Mach+BSD kernel (/mach_kernel) and Mach-related user-mode servers such as mach_init. What stuff have you observed that shows the client being "more FreeBSDish" and the server ("server" meaning "server with the same version as the client", e.g. if your client is 10.3[.x], the server should be another 10.3 version, not one of the really old servers) being "more Machish"?
I just bought it today. There is a little bit of code, mainly snippets from headers and drivers.
From the little I've read so far (30 pages), it's an excellent book. I liked the previous book (on the 4.4BSD system - I've never read the 4.3BSD book), but this one is a lot more relevant to current operating systems, as the former is about 8 years old.
To my understanding, OS X Server isn't even the same code-base as normal OS X. Supposedly it's more NeXTish.
.edu) and Unlimited-client for $1000 ($500 .edu). Client restrictions only affect simulataneous Mac and Win file sharing, so many shops just use the 10-client version.
OS X Server 1.0 came out over a year before the OS X Client. At the time of Server's original release it was basiclly a Mac-flavored version of NeXT OPENSTEP. Apple's client OS at the time was still classic Mac OS 9 (or was it 8.6?).
When Apple released Mac OS X 10.0, with the Aqua GUI and all of its refined NeXTisms, they replaced the original OS X Server with one based on 10.0. This trend has continued today with 10.3 and soon, 10.4.
The only differences between Server and Client today are the inclusion of more open source daemons and apps, optimized configurations, and some (really snazzy) closed source management tools. Remote admin can be done via a remote shell (BSD derrived), web interface, or from another Mac using the management apps. Server comes in two flavors: 10-client for $500 ($250
http://www.apple.com/server/macosx/
If you have an older Mac that doesn't support Mac OS X, or if you have an x86 PC (or if you have a semi-modern Mac but don't want to pay for an upgrade to 10.3 Client or Server), you can install Darwin, the open-source core of Mac OS X. It's basiclly Apple's NeXTish BSD distribution, but based on the Mach kernel and using NetInfo to manage configuration. You won't get the Aqua GUI (but you can use straight X11) nor the GUI admin tools, but everything else will be about the same.
Perhaps the coolest thing about Darwin is the fact it's opensource -- driver and utility coders love this, there aren't too many secrets when the core OS has open code.
So falling $13B short of expected sales and shipping less than 6,000 units in Q2 is considered a success? The only vendor to ship over 300 units was HP. Compare that to say, Apple who shipped 13,000 Xserves, which arguably are the biggest competitor to Itanic in the clustering market for universities and super-computer centers. If we look at the Opteron, that shipped 60,000 (of course it's usually not a direct one to one vs. Itanic, but you get the idea).
For over a decade of R&D and combine billions from Intel and HP, that has to be a major failure. Just the fact that they're adding 64bit extensions to Xeon shows you that Itanium is failing to gain the server market share that they planned on and now they have to plug the holes by beefing up their low-end server gear.
Now comes news from IDF that HP is adding more Opteron kits to it's lineup with 4 way boxes and blades. Hmmm, that doesn't sound like a company that has faith in Itanium to me, and they were the second largest investor!
There is of course the old saying "no one ever got fired for buying IBM", but I wonder if in a few years there won't be a rash of firings for "buying Intel" when Itanics platform support is still lagging terribly behind other architectures.
Someone is WRONG on the Internet!
Here's a sample chapter about process management.
cpghost at Cordula's Web.