Skip to main content

By clicking Submit, you agree to the developerWorks terms of use.

The first time you sign into developerWorks, a profile is created for you. Select information in your profile (name, country/region, and company) is displayed to the public and will accompany any content you post. You may update your IBM account at any time.

All information submitted is secure.

  • Close [x]

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerworks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

By clicking Submit, you agree to the developerWorks terms of use.

All information submitted is secure.

  • Close [x]

Why FreeBSD

A quick tour of the BSD alternative

Frank Pohlmann (frank@linuxuser.co.uk), U.K. Technical Editor, Linuxuser and Developer
Frank Pohlmann dabbled in the history of Middle Eastern religions before various funding committees decided that research in the history of religious polemics was quite irrelevant to the modern world. He has focused on his hobby -- free software -- ever since. He admits to being the technical editor of U.K.-based Linuxuser and Developer and came to FreeBSD via a strong interest in UNIX kernel internals and an interest in Linux applications for writers and artists.

Summary:  The FreeBSD operating system is the unknown giant among free operating systems. Starting out from the 386BSD project, it is an extremely fast UNIX®-like operating system mostly for the Intel® chip and its clones. In many ways, FreeBSD has always been the operating system that GNU/Linux®-based operating systems should have been. It runs on out-of-date Intel machines and 64-bit AMD chips, and it serves terabytes of files a day on some of the largest file servers on earth.

Date:  19 Jul 2005
Level:  Introductory PDF:  A4 and Letter (154 KB | 8 pages)Get Adobe® Reader®
Also available in:   Japanese  Portuguese

Activity:  92135 views
Comments:  

The Berkeley Software Distribution (BSD) family of operating systems can be traced back to the BSD UNIX operating system created and maintained at the University of California, Berkeley, since the late 1970s. Today, the BSD family consists of five main branches, and even Linux activists, comfortable with a plethora of distributions, find themselves bemused by the number of BSD flavors appearing in ever-greater numbers. Since 2001, when the last major branch -- DragonFly BSD -- was launched, FreeBSD, OpenBSD, NetBSD, and Mac OS X represent a new creative surge in the UNIX world. All of them are POSIX-compliant. All present similar command-line interfaces to their users. All use kernels and system libraries that make similar programming models and application usage characteristics possible.

For legal reasons, BSD cannot be called a UNIX system, but it is widely accepted that the BSD flavors represent open source UNIX. Amazingly, in the late 1980s and early 1990s, no free operating system worth the name running on the PC or Mac was available. UNIX lived on mainframes and the Scalable Processor Architecture (SPARC). Proprietary UNIX companies had balkanized the commercial UNIX scene.

In the beginning, there was 386BSD

In 1993, two events occurred that were to change the UNIX scene permanently: The NetBSD group was founded, and the 386BSD patch kit was revived. Ten years before, BSD UNIX developers had been recruited from the ranks of U.C. Berkeley staff and Ph.D. students; the money had largely come from the Defense Advanced Research Projects Agency (DARPA), but the funding was coming to an end. The 386BSD project came into being in 1985 as an attempt to get BSD UNIX to run on an Intel chip. The first release did not occur before 1989, and for various reasons, the project ended up becoming a reference operating system publicized by Dr. Dobb's Journal in July 1992. Known as 386BSD 0.1, it experienced 250,000 downloads.

The 386BSD was mainly based on Bill and Lynne Jolitz's ideas to improve the very concepts on which UNIX was based. It was meant to be free, but supporting a complete operating system virtually on their own proved to be beyond the Jolitzes. The system lost out to the armada of programmers joining an almost unknown Finnish student help build Linux.

The history of FreeBSD

Another group that took the original vision of porting BSD UNIX to the Intel chip to its conclusion formed in the course of 1993. Relying on previous work by Bill Jolitz, FreeBSD V1.0 was released in December 1993. Jordan Hubbard, the project leader, drove the project, managing infrastructure and a group of committers that grew to 200 developers by early 1997. FreeBSD is supposed to reach version 6.0 by the end of this year and is arguably the most important of all free UNIX systems. FreeBSD is not a UNIX clone, but rather a system that not only works like UNIX but whose internals and system APIs are UNIX-compliant.

FreeBSD is not the Intel-/AMD-only system it once was. It also runs on SPARC64 machines and has a fairly long history on Alpha architectures. If a BSD user is interested in the chips running Mac OS X, he could switch over to Darwin OS, the open source core of Mac OS X, which in turn relies on much of FreeBSD V5.0 and its successors. NetBSD, of course, has been running on all Mac architectures since 1995.


What FreeBSD does and Linux doesn't

BSD on the Mac

BSD on the Mac is old hat. UNIX has been running on Mac architectures for even longer. Hardly anyone remembers it these days, but there was a time when a version of AT&T UNIX ran on Apple's Quadra machines. In the late 1980s, this UNIX version was known as Apple UNIX, and it represented Apple's bid for a part of the UNIX server space. Apple UNIX was never ported to the newer PowerPC architecture, but it ran well enough on Motorola 68x00 chips. Obviously, the code was proprietary, usually requiring a low four-figure monetary investment. We might take comfort in the fact that even a luminary as exalted as Bill Joy was dismissing the Mac in the mid-1980s as a machine no one in the UNIX world cared about. Oh well.

When 386BSD came along in 1991, Mac was not far off some peoples' minds. Brad Grantham, Lawrence Kesteloot, and Chris Caputo managed to port 386BSD to the Mac under the name MacBSD. In late 1992, BSD UNIX had found a new home on a Mac II, although the concurrent breakup of BSD UNIX was beginning to be seen at the time as a necessity, rather than a possibility: The legal shenanigans around AT&T and U.C. Berkeley had made the freeing of the BSD UNIX project a technical as much as a legal necessity. It is still remarkable, though, that an early Macintosh architecture ran free UNIX before the Intel chip had a BSD flavor dedicated to it. 386BSD was never meant to do much except suggest which UNIX should go on the Intel chip. It didn't work very well at the best of times and never really reached version 1.0.

In the summer of 1993, Allen Briggs and Michael Finch started to merge NetBSD V0.8 and MacBSD to avoid balkanization before it became a serious issue. After all, the UNIX wars were fresh in everyone's mind, and NetBSD seemed a worthy project for trying to incorporate as many architectures under the BSD mantle as possible. By the time NetBSD V1.0 came around, the NetBSD/mac68k project was firmly established, and it has been going strong ever since.

The NetBSD/macppc project is of more recent vintage. The PowerPC port was included among the NetBSD ports in 1999, although all post-1995 PPC architectures are included. It supports all Mac architectures since the 604 PowerPC.

OpenBSD/macppc is based on NetBSD code, although it took the OpenBSD project a little longer to have a fully functioning port. For obvious reasons, the FreeBSD project remained aloof, focusing instead on Intel and AMD support, although FreeBSD code has been running on Macintosh architectures since Darwin -- the OSS kernel of Mac OS X -- was released. This seems less relevant these days, as Apple has announced Intel support. But there is considerable overlap between FreeBSD and Darwin development, and quite a few FreeBSD developers are Apple employees.

FreeBSD is an operating system, not just a kernel. This statement does not mean quite as much as it used to, however, because the very notion of a kernel is fairly arbitrary. In a UNIX context, it means that users can't access certain libraries and executables after booting has finished. The kernel manages the hardware for applications, even though today many UNIX-type operating systems would give user-level threads a role in managing kernel resources. You can safely assume that anything users cannot access during run time is part of the kernel. This does not mean that users can't influence kernel behavior. Certain utilities can report and tune memory management, for instance, and they are definitely within the purview of the user. These utilities communicate through the system's API, which is not part of the kernel, although it is quite clearly part of the operating system. FreeBSD, of course, includes all these and many other utilities and applications that deal with the characteristics of networking and hardware.

If you were to compare the contents of a complete Linux kernel download and a FreeBSD download, there would be much that the downloads have in common. Both have IP stacks, memory-management routines, file system implementations, and so on. The file system hierarchy has demonstrably similar origins, and most command-line applications have identical names and similar command-line semantics. The actual implementations look somewhat different, of course, but you would still be able to see that both systems have similar conceptual origins. A major architectural difference lies in the way FreeBSD reads and writes files to the so-called buffer cache, which (strictly speaking) does not even exist as an entity separate from virtual memory. Linux has always managed buffer cache sizes automatically, but its memory-management routines work differently from FreeBSD's.


Ports and file systems

FreeBSD works immediately after it has been installed. It works because a FreeBSD system installs a working system using the FreeBSD installer, also known as sysinstall, and it uses a package-management system that has clear UNIX origins. But FreeBSD goes much further than that: Package management has been thoroughly streamlined; binary and source packages are not subject to the whims of the package-management system de jour, an affliction common to Linux distributions. FreeBSD integrates package management and Internet-wide updates with the Ports system, allowing you to address source download and compilation in one procedure. One could argue that Debian has similar advantages, but one should not forget that Debian is an operating system whose reliance on the Linux kernel is accidental. The Hurd and the NetBSD kernel would work just as well, provided the Debian project remembers to update the packages.

The FreeBSD file system is also somewhat reminiscent of its BSD UNIX past: It comes under the Fast File System (FFS) and the UNIX File System (UFS) monikers. Users are more likely to interact with the FFS portion of the file system, which regulates file and directory access. The UFS system, version 2 of which was released in 2003, sets the file system limits and the basic data structures organizing raw disk access. UFS and FFS are also available on NetBSD and OpenBSD. The more well-known journaling file systems current on Linux, like Reiser File System (Reiser FS) and Journaling File System (JFS), are not available on FreeBSD, mostly for security reasons. UFS has the additional advantage of stability and (now) scalability because its behavior and performance rely on research dating back more than two decades.


Security and compatibility

Other benefits can influence your choice to take FreeBSD more seriously. Although not in the same league as OpenBSD with regard to code-level security, FreeBSD comes with a formidable array of security mechanisms that work out of the box. Since FreeBSD V5.0, it is possible to add fine-grained access controls and security policies that have their origin in the DARPA-funded TrustedBSD project. FreeBSD supports access control lists (ACLs) and mandatory access control (MAC) modules. The latter is of course accessible only to systems administrators and managers, but it enables small businesses to run networks with fine-grained security measures that apply to subsets of the system exposed to the outside world. UFS V2 has excellent ACL support via extended attributes; you must configure UFS V1 separately if ACLs are a requirement.

If you have been introduced to the mysteries of Linux, you might be concerned to see applications available for, say, SuSE Linux and Mac OS X, but have no separate source or binary for FreeBSD. FreeBSD is able to run a Linux binary compatibility module, which you must enable at installation time or from the command line. Linux run-time libraries might be required, as well, but you can add them from the Ports collection.

Of course, FreeBSD runs all major X Window System-based desktop shells, such as the KDE desktop and the GNU Network Object Model Environment (GNOME) desktop. FreeBSD used to be the desktop user's UNIX version of choice until the FreeBSD-based OS X came along. It still gives UNIX users operating under budgetary constraints an extremely good deal and does not require additional licenses when configured as a server or a client.


FreeBSD derivatives

Like most operating systems with a long history, FreeBSD has generated its fair share of offspring. It is possible to start a FreeBSD system from a CD without having to compile and produce a CD. The work has already been done with the fairly mature Free System Burned in Economy (FreeSBIE) V1.1 LiveCD system, which in turn is based on FreeBSD V5.3. If allocating part of the hard disk and writing to the master boot record (MBR) seems risky, it is a perfect starting point to begin testing FreeBSD.

DragonFly BSD is based on the FreeBSD V4.x series release, but it does not aim at the average user at all. It mentions secure Internet-wide clustered file systems on the first page of its Web site -- not a requirement likely to trouble first-time UNIX users. DragonFly BSD was founded by the resident FreeBSD virtual memory guru and tries to implement a completely new approach to massive secure file system and memory management.


Documentation matters

It is unusual to mention operating system documentation that comes with UNIX systems because such documentation tends to be as unreadable as it is intrinsically interesting and useful. FreeBSD documentation is a great exception to this rule because it does not pay much attention to old-style manual pages or copy the style or organization of UNIX documentation.

FreeBSD documentation is available as a concisely written book, on the Internet and on paper, covering each and every aspect of the system in a pleasant and considered style. It does not presuppose much familiarity with UNIX systems and, indeed, has been used profitably by UNIX neophytes. It does teach the miracle of a simple FreeBSD installation, but it also gives a clear introduction to the whys and wherefores of FreeBSD kernel compilation or securing a FreeBSD installation. It is interesting to see what the documentation omits -- for example, Perl and Apache -- and what it includes -- such as the Berkeley Internet Name Daemon (BIND) and the FreeBSD-specific storage manager Vinum. Vinum implements virtual disk drive management and can cope with RAID 0, RAID 1, and RAID 5.


The administrator's operating system

It is possible to describe FreeBSD as a network administrator's operating system: It's fast, SMP-capable, and well integrated with a large number of networking tools. However, FreeBSD is just as slick and fast when run on laptops, when running office applications, and when running mail clients and databases. Its installation routines are simple enough for a Microsoft® Windows® power user to be comfortable with. It also has a lot to offer to Linux users, simply because in binary-compatible mode, applications native to Linux run without changes. FreeBSD is extremely scalable and runs most applications written for Linux or BSD flavors. Don't assume that FreeBSD is a Swiss army knife among free operating systems, though: It's neither as secure as OpenBSD nor as scalable as a future Open Solaris version can be safely thought to be. But it competes with any operating system -- commercial or free -- on the Intel chip and, in many cases, provides a more stable and scalable platform than any of its nearest competitors.


Resources

  • FreeBSD is the main FreeBSD portal. It provides access to the source code, the FreeBSD handbook, and new FreeBSD versions.

  • To delve into the beginnings of FreeBSD, the 386BSD site gives an account written by Bill Jolitz. 386BSD source code is available from this site, as well.

  • Although used widely, UFS 2 is not well known.

  • The DragonFly BSD Project has substantial and technically demanding documentation.

  • FreeSBIE provides a live FreeBSD version on CD.

  • The Debian operating system is commonly thought to be GNU/Linux-based, but as you'll see when you look on the Debian Web site, it can run other kernels as well, like NetBSD and Hurd.

  • For those who like to go back along the Mac timeline to Motorola 68k-based architectures, the NetBSD/mac68k Web site provides large doses of fun.

  • The PPC port for NetBSD is represented by the very active NetBSD/macppc group.

  • OpenBSD's focus on security has found friends among Mac specialists and the PPC port is developed here.

  • Hard disk management is often dominated by commercial tools, but FreeBSD comes with its own OSS tool called Vinum.

  • Berkeley UNIX was the original test bed for IP networking. BIND, or the Berkeley Internet Name Domain, represents an implementation of all DNS protocols, including name server and resolver library, without which the Internet domain name infrastructure is impossible.

  • See the developerWorks tutorial "Installing FreeBSD" to learn how to make FreeBSD run on your computer.

  • Visit the developerWorks Open source zone for extensive how-to information, tools, and project updates to help you develop with open source technologies and use them with IBM's products.

  • Innovate your next open source development project with IBM trial software, available for download or on DVD.

  • Get involved in the developerWorks community by participating in developerWorks blogs.

About the author

Frank Pohlmann dabbled in the history of Middle Eastern religions before various funding committees decided that research in the history of religious polemics was quite irrelevant to the modern world. He has focused on his hobby -- free software -- ever since. He admits to being the technical editor of U.K.-based Linuxuser and Developer and came to FreeBSD via a strong interest in UNIX kernel internals and an interest in Linux applications for writers and artists.

Report abuse help

Report abuse

Thank you. This entry has been flagged for moderator attention.


Report abuse help

Report abuse

Report abuse submission failed. Please try again later.


developerWorks: Sign in


Need an IBM ID?
Forgot your IBM ID?


Forgot your password?
Change your password

By clicking Submit, you agree to the developerWorks terms of use.

 


The first time you sign into developerWorks, a profile is created for you. Select information in your profile (name, country/region, and company) is displayed to the public and will accompany any content you post. You may update your IBM account at any time.

Choose your display name

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerWorks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

(Must be between 3 – 31 characters.)

By clicking Submit, you agree to the developerWorks terms of use.

 


Rate this article

Comments

static.content.url=http://www.ibm.com/developerworks/js/artrating/
SITE_ID=1
Zone=Open source, Linux
ArticleID=89018
ArticleTitle=Why FreeBSD
publish-date=07192005