Hacker News new | past | comments | ask | show | jobs | submit login
BSD For Linux Users: Intro (over-yonder.net)
100 points by tzury on Nov 26, 2010 | hide | past | favorite | 39 comments



The article is an "ok" intro to the differences between Linux and BSD, but it stays at a pretty high level (and makes it clear that it wasn't intending to go into anything more detailed than "principles/design/philosophy"

The article is dated though - it predates GIT, and still refers to the odd/even devel/production numbering in linux, which went out of vogue a couple years ago (at least)

It is, of course, not entirely accurate when discussing BSD as consisting of a system that is designed with all its "core" components by the BSD system. Some of the "base" stuff in BSD is actually still from outside the tree. For example, rtadvd, the IPv6 Router-Ad daemon, originally came from the WIDE Hydrangea IPv6. The rtadvd.conf files, in Open BSD, aren't the elegant/simple OpenBSD standard, but instead use the termcap(5) format. OpenBSD's approach to situations like this is to use the software until someone is inspired to build an "OpenBSD from the ground up" version, rather than mess around too much with upstream contributions to make them look more "OpenBSDsh"

We use OpenBSD a lot where I work - its firewall, and routing configurations are rock solid. And configuring the systems is a dream. I far prefer the OpenBSD /etc/hostname.if approach to the various /etc/sysconfig/network-scripts approach that various RHEL releases have taken (and changed between releases).

For some reason, 95%+ of our deployed systems (around 500) and our target for application development, is Linux though. Probably because there is no equivalent of RHEL/SUSE in the OpenBSD world.


This is pretty informative. I've used OpenBSD for years, and what he says holds there as well. (OpenBSD fits me better, but FreeBSD is a great OS.)

He alludes to OpenBSD favoring reinstalling rather than upgrading in place. To some extent, this is probably because the OpenBSD installer is quite spartan. Once you know the process, a whole OpenBSD server can be running and configured in well under a half hour. Depending on the system, that can be simpler than merging / updating everything. I update my desktop (chasing snapshots) and laptop (each numbered release, which for OpenBSD happens every 6 months), and just reinstall my firewall/server when I feel like it.

Also, OpenBSD runs a monolithic kernel - all the drivers for the platform are included by default, so if your hardware is supported, it's autodetected on boot. No kernel rebuilding or modules necessary. (I don't think FreeBSD does this.) I've used an OpenBSD install disc to identify weird hardware that Linux didn't recognize.

There are a lot of benefits from a packaging system that primarily builds from source: It's much easier to build a package with various options (OpenBSD calls them "FLAVORS"); build this, no-x11, use postgres for its stats, add support for vorbis, etc. He mentions this, but seeing apt-get struggle with dependencies if you go away from the default configuration (or worse yet, build something from source that other packages use!) really makes it clear. You don't have to build everything from source, either - there are cached packages for most things on the mirrors. (Building all of KDE or GNOME from source would take quite a while!) If PKG_PATH is set to a mirror, "pkg_add pkgname" will attempt to fetch the binary package and its dependencies.


While this was an interesting read, and pretty well written. I - as a long time Linux user, wasn't really able to figure out the advantages BSD has over Linux.

I agree that the author put a nice disclaimer warning us he will not be telling us why BSD is better - but he definitely mentioned that it is .

It is rather obvious the author is biased towards BSD - For example - "Chaos VS Order" and "Right VS Wrong" as titles when comparing BSD and Linux from a philosophical POV. Reading this reminded me of how I was as a young Linux user 15 years ago (Slackware 3.4...) and was proud of using a barely usable OS - blinded by my own pride arguing in favor of Linux without any true understanding of the internals - and unable to hold a single argument of what makes it any better.

If i wanted to sum everything i would basically be saying - Linux is different. But thats why Linux has many different flavors - It depends on what you like - and your level of expertise. If you like compiling everything - you could use Gentoo. If you want it to "Just work" - you could try out Ubuntu. If you need something Robust and supported - use RHEL. While it is true that Linux development might be more "chaotic" than BSD, there is order in the chaos. What seems to be unordered and unorganized in fact has its own way of making things play in harmony.

PS. I would really love if anyone has a more technical comparison of BSD VS Linux (FS, Scheduling Etc..)


From a technical standpoint, Linux is a System V-style Unix and BSD is (unsurprisingly) a Berkeley-style Unix. One of the most striking differences (which he didn't mention) is the init system - SysV uses /etc/init.d/, while BSD uses /etc/rc.conf and the like. Also, see the "hier" (filesystem layout) man pages for FreeBSD (http://www.freebsd.org/cgi/man.cgi?query=hier) and OpenBSD (http://www.openbsd.org/cgi-bin/man.cgi?query=hier).

He responds directly to the "Chaos VS Order" bit on his response page, BTW:

"Chaos means that you're moving every which way at once. Linux (and its various distributions) are moving in all sorts of different directions, with very little real coordination. That means they're going to end up in a lot of places the BSDs, with their more careful and orderly progression, will only get to more slowly (if at all). A lot of those places are going to be icky and horrible, and places you don't want to be. But some of them are going to be absolute jewels, that you could never reach any other way.

Thus, Linux may hit lower lows, and they may even be more numerous. But the sheer number of people and projects pushing in so many different directions practically assures you of striking gold. You can't get that sort of serendipitous perfection, without accepting a whole lot of chaos and a lot of wrong turns." (http://www.over-yonder.net/~fullermd/rants/bsd4linux/11)

He's being pretty diplomatic about it - I've read far less flattering descriptions of the Linux development model (http://www.jwz.org/doc/cadt.html), though things have gotten better since 2003.


As a matter of fact, some Linux distros use /etc/rc.conf as well (Arch linux). The way Linux is designed and works is that everything is configurable and rather easily done. This is almost definitely true for *BSD as well, but probably not as easy.

In the case of BSD VS Linux I prefer the model of "Shooting at all directions until you hit" kind of philosophy. BSD is a "Like it or not" kind of OS. While Linux is more of a "Everyone can find a flavor he likes" kind.


I am far more of a Linux user, but one thing that irks me on a BSD is that I feel like the GNU tools have more features and feel more natural than the BSD alternatives. I'm probably just not used to them but things like colors and such seem more prevalent with the GNU tools.


"Chaos VS Order" here is about release management practices, and if you look at it in detail you'll see in Linux they are chaotic indeed.


"Unix-the-code is owned by SCO"

Not according to a judge, A jury, and at least one judicial review. Unix, the code, is owned by Novell.

http://www.groklaw.net/pdf/Novell-271.pdf

http://groklaw.net/pdf2/Novell-846.pdf


And now it's apparently owned by a company partially owned by Microsoft.


I found his article to be very informative, well-written, and I'm glad he took the time to write it.

It's interesting to note the criticisms that he has gotten -- but not surprising. Most developers that I have met share the same trait; they take things personally. When you talk to someone who has spent years of his life learning Linux (or Windows, or C++, or whatever) and then you make a comparison against that, the developer will feel like you personally insulted him. He feels that you are invalidating all of the knowledge that he has painstakingly acquired. We should all, as a group, move beyond this behavior and seek to have healthier and more neutral debates on these things. I have the same bad habit so I'm not pointing fingers here -- just a commentary. We should all thank people like the OP for sharing their knowledge with us.


BTW I was referring to the comments on his website, not the ones here, which seem to all be very friendly.



Yes, yet again, BSD is better, but none of the reasons given here are good enough to be "the guy who wanted to put BSD on the servers."


At work, I develop on OS X (aka Darwin, derived in part from BSD) and deploy on Linux (mostly Debian). For personal endeavours, I have FreeBSD running.

In general, I've found FreeBSD to be more stable and to have more of an "engineered" feel to it (if you'll excuse the use of the term "feel"), while Linux.. well, as pointed out elsewhere is a little more chaotic in terms of it's development.

I can't speak for Net/OpenBSD, but FreeBSD certainly has a Linux compatibility layer that let's you run most, if not all, Linux code, so potentially it's "win/win" (or "Lose/Lose" depending on your POV).

But I can say that, over the years, comparing Linux and FreeBSD, FreeBSD is my choice as it has generally been less of a hassle to set up and administer, and the documentation - whilst not completely perfect - is pretty damn good.

My tuppenny opinion, YMMV etc..


See another discussion on the subject on a previously posted FreeBSD Quickstart Guide for Linux: http://news.ycombinator.com/item?id=1759761

This story was also posted in the comments.


I think he meant FreeBSD for Linux users. Since most of the points in there are only relevant to FreeBSD.

I am an OpenBSD user, but the reason I don't use it as often is because most of the VPS/dedicated servers providers only offer Linux.


I've used RootBSD, which primarily deploys FreeBSD guests, but they do offer other choices, including OpenBSD 4.8 [1].

I also have no benefit from advertising this provider.

[1] http://www.rootbsd.net/blog/2010/openbsd-4-8/


Have a look at elastichosts.com - they provide VPS on KVM so basically you can run any OS you want.

(I have no benefit from advertising this specific provider)


package management and administration is a great start to explaining the differwnces, but what I would really like to see is a low level explanation of the differences. To what extent does BSD follow the "everything is a file" philosophy that linux does. Where is information about devices and processes to be found?

coming from a Gentoo background, where portage is based on the bsdports system, package management is not all that foreign in BSD. But when it comes time to tweak things, I start missing my sysfs and procfs, mostly throug ignorance of how BSD does such things.


> To what extent does BSD follow the "everything is a file" philosophy that linux does. Where is information about devices and processes to be found?

You got this the wrong way around. "Everything is a file" is a core UNIX feature, and predates Linux by more than 20 years.


I think that "most everything is a file" is a core UNIX feature. "Everything is a file" really comes from Plan 9: http://en.wikipedia.org/wiki/Plan_9_from_Bell_Labs (see Design Concepts, /net, and /proc)


In Unix it is rather "everything has a file descriptor at API level" while in Plan9 it is really "everything is a file" from the system standpoint.

It is not surprising since Plan9 also came from Bell Labs, and they learned the lessons of Unix, raising the idea to a new level.


The "everything is a file" philosophy came from the original Unix, but didn't quite stay consistent when things like sockets were added later. Like Linux, BSD keeps its device info in /dev.

/proc doesn't come from Linux, it comes from plan9. The /proc in Linux is a weak knock-off, since Linux doesn't support per-process mount points the way plan9 does. I don't know about FreeBSD, but OpenBSD has a port of /proc roughly on par with Linux's.


FreeBSD has procfs, although it's not mounted by default.

    mount -t procfs proc /proc
    ls -alR /proc


I have not been using a bsd system for a long long time, but from what I recall at least freebsd had the same kind of virtual FSs that linux had, procfs on /proc and devfs on /dev but no separate sysfs on /sys.

I suspect though that you may have wanted to investigate sysctl(8) for your tweaking needs http://www.freebsd.org/cgi/man.cgi?query=sysctl&sektion=...


I understand that this is a UNIX trait, I tried to choose my words carefully. Linux follows that philosophy (to some extent). Not: that is a Linux philosophy.

My main curiosity comes from how Mac OS X, being a sort of flavor of BSD, also follows that philosophy. The Mach kernel probably messes all that up though. Anyone familiar with the such things?


I wonder if anybody still uses BSD.. AFAIK some companies (for example stackoverflow) use OpenBSD as firewall, but FreeBSD? Yahoo used it but then switched over to Linux.


Yahoo is still using FreeBSD.

FreeBSD is also used by ISPs (NYI, Pair, Verio), storage companies (NetApp, EMC), internet infrastructure companies (Cisco, Juniper), hedge funds (not sure if I should mention names), antivirus companies (probably shouldn't mention names), large defence contractors, several US national laboratories...

There are permanent FreeBSD deployments on every continent (yes, including antarctica) and in some of the most remote regions on earth (when the European Southern Observatory in Chile needed to send data wirelessly over 100 km, they used FreeBSD).

Yes, people still use BSD.


And maybe Tarsnap?;) Thx for the excellent answer.


EC2 has no support for BSD, if my cursory search was right, and Tarsnap runs partially on an EC2 instance.


The Tarsnap server isn't running on FreeBSD (yet...) but a very large portion of the Tarsnap client code comes from the libarchive library, which grew out of FreeBSD. Whether that counts or not is a matter of opinion.


Most of the unix userland tools of MacOSX come from FreeBSD.

Airport Extreme and Time Capsule run NetBSD.


OpenSSH (http://openssh.org/) grew out of OpenBSD, and that's used pretty widely (http://www.openssh.com/users.html).


Several components of OS X are directly from FreeBSD.


Yes I know that, so it's probably worth the time to look into a newer FreeBSD release. I wonder if it works well on a laptop.


I run FreeBSD CURRENT on my MacBook Pro with a light tiling window manager. It is not as featured as Linux but it does run decently. Wireless configuration is done through editing wpa_supplicant.conf and restarting netif, suspend/resume don't work correctly, I haven't yet configured my audio to switch output from either the headphones or the speakers without having to edit /boot/device.hints and restarting, and a handful other things, for example. On the other hand, 9.0-CURRENT has included many new drivers for things like the Apple touchpad (atp(4)). Support for desktop use is slow, but it isn't ignored.

I would highly recommend you scrutinize your hardware compatibility before committing to an install on a desktop or laptop system.


FYI, OpenBSD -current wireless works like this:

    ifconfig ral0 nwid my_router wpakey my_password
No wpa_supplicant!


I used PC-BSD (which kind of is to FreeBSD what Ubuntu is to Debian) for a while on my laptop. I really liked the system as a whole, but I had some issues with wireless support, and found KDE a bit sluggish (very low RAM on my laptop). But it's certainly worth a try - if you can get everything to work right, it's a very nice system.


Printable/Saveable version please!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: