[TAG] System V or BSD?
rick at linuxmafia.com
Fri Dec 2 23:47:27 MSK 2005
Quoting Adam S Engel (bartleby.samsa at verizon.net):
> I thought most Linuxes, particularly the "big ones" like Fedore, Debian,
> SuSE, Mandriva, were based on System V. Even so, my MacOSX, based
> loosely on BSD, will not accept the ps -ef command. Can a system
> (Mandriva in this case) be comprised of both?
All modern Unixes (except *BSD, which are holdouts) are the result of
(or inspired by) a shotgun marriage of those two cultures (plus SunOS),
called System V R4, released by AT&T in 1988. Quoting from the Unix FAQ:
- From SVR3: sysadmin, terminal I/F, printer (from BSD?),
RFS, STREAMS, uucp
- From BSD: FFS, TCP/IP, sockets, select(), csh
- From SunOS: NFS, OpenLook GUI, X11/NeWS, virtual memory
subsystem with memory-mapped files, shared libraries
(!= SVR3 ones?)
- ANSI C
- Internationalization (8-bit clean)
- ABI (Application Binary Interface -- routines instead of
- POSIX, X/Open, SVID3
Even prior to that, retrofitting "BSD enhancements" onto System V-based
systems was a nearly ubiquitous customisation: Sys V R4 simply
acknowledged that reality, bowing to the technical community's mandate.
The general architectural description of Sys V R4 got abstracted out as
the POSIX.1 specification, which served as the blueprint from much of
what Torvalds and co. (and FSF, and others) then performed in building up
what today we call GNU/Linux systems: Linux distributions generally are
an independent implementation of (most of) the POSIX spec, which in turn
was based largely on Sys V R4. And so, here we are.
[Your new Dell Dimension:]
> It was going to be Debian, but now I'm thinking of FreeBSD. Can
> anyone tell me the major difference between FreeBSD and Linux?
Speaking in very broad terms, FreeBSD was designed and is maintained by
people who never liked AT&T Unix or any of its derivatives and
independent reimplementations at all, and who thus were unsatisfied by
the System V R4 compromise. Of course, that's hardly all there is to
it: If you'd been sued, more or less baselessly, by a Fortune 500
corporation for copyright infringement, you'd probably develop an
attitude problem, too.
The difference in init scripts, you know about. A minority of Linux
distributions have offered BSD init scripts, too, all along, e.g.,
Slackware, for those who like them.
Additionally, there are such a large number of other small but
significant architectural differences that I cannot hope to remember
The BSDs tend to favour a "BSD slice"-type partition map, as opposed to
the IBM/Microsoft-style partition map more typical of Linux systems
(at least on IA32/x86-64). Their directory layout is a bit different,
not very close to the Filesystem Hierarchy Standard promoted by the
Linux community. They tend to use variants on UFS as their main
filesystem. (FreeBSD favours a variant called FFS = Fast Filesystem,
incorporating Marshall Kirk McKusick's softupdates instead of
journaling. Softupdates are a clever and effective way to get most
of journaling's advantages in protecting metadata following crashes or
power loss -- but sadly does nothing about the problem of long fsck
times after such events.)
They tend not to have anything resembling /proc. They favour csh over
Bourne variants such as bash. They favour nvi over vim. They default
to use of the wheel group (which Linuxes usually lack mostly because
Stallman at FSF doesn't like the concept). In general, their prejudices
tend to come across to Linux users as a bit old-fogey-ish.
They offer both binary packages plus a very successful build-from-source
architecture called the "ports" system. The closest thing to the latter
on Linux would be Gentoo's portage and the GAR build system (and similar
things in other build-from-source Linux distros).
They have their own libc (not based on GNU's, as Linux always has been)
and their own implementation of make. Otherwise, a lot of the userspace
toolsets are literally exactly the same (except compiled to a different
ELF binary format).
Spend some time reading "The FreeBSD Handbook", online: It's a landmark
in clarity for technical documentation, and worth reading on that basis
> I've heard that FreeBSD is known for its security and other network
FreeBSD is not _especially_ known for security. (You might be thinking
of OpenBSD.) I would say that it best known for scalable network
performance under heavy load, and for stability. It's also known for
having relatively narrow scope of hardware compatibility (i.e., driver
selection), compared to Linux, and for relatively slow and conservative
development: You may or may not find FreeBSD 6.0-STABLE's driver
support for your new Dell Dimension's chipsets to be adequate.
Specific comparisons of FreeBSD with typical Linux systems have been
done repeatedly, but tend to have the problem of being out of date
(which doesn't stop people from alluding to them, out of ignorance).
E.g., often-heard claims about better FreeBSD VM performance rely on
Linux 2.4.x results, back when Linux had a real problem, there. For
that matter, Linux's entire TCP/IP stack has been thrown out and
rewritten four or five times during the kernel's history, so you can
imagine the large opportunity for outdated comparisons, there.
It used to be the case that FreeBSD's SCSI subsystem gave significantly
better performance than that of the Linux kernels, but I suspect that
difference, too, has been eliminated. What probably does remain is the
matter of NFS/autofs/amd: If you're a heavy NFS user, you'll find that
FreeBSD's NFSv3 implementation still has fewer bugs than Linux's, though
the gap is pretty small by now.
Rick Moen "Anger makes dull men witty, but it keeps them poor."
rick at linuxmafia.com -- Elizabeth Tudor
More information about the TAG