6 ms·
I have been an OpenBSD and FreeBSD user, as well as minor contributor, since the mid-90s. All the answers here are good, and I would like to add: * FreeBSD is
by bl4k 16y ago
I have been an OpenBSD and FreeBSD user, as well as minor contributor, since the mid-90s. All the answers here are good, and I would like to add:
* FreeBSD is on the cutting edge of performance. Because it is a total OS (as opposed to just a kernel), performance improvements are made and integrated into the binary packages and ports build options of common packages. FreeBSD was one of the first operating systems to implement kqueue, which is now available on OS X. This was part of the reason why for years FreeBSD dominated high-performance web serving. If you asked this question 5-10 years ago, the answer would simply be 'FreeBSD performs a lot better than Linux with web serving', but that is not as true today since Linux has caught up in the 2.6.x branch (with epoll). For more info see the classic: http://www.kegel.com/c10k.html http://www.kegel.com/c10k.html
The good servers like nginx and varnish take advantage of these performance benefits that FreeBSD offers.
(there was a similar system here with the virtual memory manager, while the Linux kernel struggled with this issue ~01-02 FreeBSD was miles ahead). FreeBSD is the starting and development point for a lot of new technologies.
2. Everything is done the BSD way, from directory layout to the rc.x startup system. It is the same and uniform and integrated with the kernel and doesn't vary across releases. There is a single reference handbook, and POSIX compliance. I have always preferred the BSD way of file system layout, and that is what I have become accustomed to. (ie. /usr/local/ really is usr local).
3. The BSD's are a monolithic kernel (which Linux is today, mostly, if you choose to) which has performance implications. FreeBSD support kernel modules, but the monolithic approach is preferred. It is very easy to build your own custom kernel (I suggest you do for servers) and the defaults are include nothing and build what you need from there, which provides a very small, fast and optimized kernel image. Linux distributions tend to take a 'kitchen sink' approach, since they are aimed at people who don't want to compile and load a kernel module for device XYZ. FreeBSD places the onus on the user to know what they are doing - which forces you to understand the internals of the operating system and how it works. Linux usually has different distributions depending on the target, but FreeBSD is flexible enough to only have a single distro that can be customized from a 20MB install image through to a desktop system that will support your Chinese webcam when plugged in. It can do this without compromising on performance or bloat. I suggest you start FreeBSD with the minimal binary install plus the ports tree (the ISO is 50MB, install is about that).
4. You can take this one 'distro' and way of doing things across a multitude of architectures.
5. jemalloc - a virtual memory manager for parallel processing that outperforms Linux, see: http://people.freebsd.org/~kris/scaling/7.0%20Preview.pdf http://people.freebsd.org/~kris/scaling/7.0%20Preview.pdf
6. The GCC compiler and toolchain are steadily being replaced by the less bloated and much faster Clang/LLVM which are part of Xcode and BSD licensed. It allows much better IDE integration, is modular and a lot lot faster than GCC. Clang/LLVM are already at the point now where they can compile all of FreeBSD
7. The TrustedBSD event auditing, ACL, stack protection, other security features and OpenBSM make FreeBSD orange book compliant in terms of security. OS X also has this (it is the same security model). This is important if you are in a corporate environment and need to stamp some certifications or meet compliance regulations with the systems you choose.
8. Zen and VMWare virtualization support available in kernel. Virtualization support is very good in Linux, but the virtualization providers have been supporting FreeBSD for a while now, and have hired core team members to develop software. EC2 needs better support, but I am sure it is coming.
9. Linux has abandoned the development branch approach (ie. 2.7.x) and instead trails along 2.6 releases with releases candidates. With FreeBSD you can be assured that STABLE is stable and CURRENT is current. Releases are taken very seriously, as can be seen by FreeBSD 5 (one of the best OS releases every, IMO) took years to finalize. Point releases are binary and API compatible with .0 releases (ie. 5.5 binaries are guaranteed to run on 5.0)
10. You have linux binary compatibility anyway, at near-zero cost.
11. A more liberal license to use in commercial environments (ie. if you sell a firewall, or an embedded device, no need to release your own code - Apple have done this spectacularly).
12. ZFS (works)
13. Excellent handbook that encompasses the entire operating system: http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/ http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/
14. Average knowledge of a FreeBSD/OpenBSD community member is higher than Linux (personal experience) and since there is usually only one way of doing things, you will find consistant answers and advice on your questions or issues across the web.
15. FreeBSD hasn't had a default install, STABLE security advisory in ~10 years.
In conclusion, if you like to know what is actually happening on your server or machine so that you can tweak, optimize and better understand performance and other issues, BSD will almost force you into understanding it. If you are running linux and just downloading and installing binary packages, you are simply unaware of what is happening on your system (no different to running Windows, really). BSD will teach you the old school UNIX way of doing things, is consistant throughout and through just using it it will teach you a lot more about your system and operating systems in general than Linux.
- ax0n 16y agoThis post is awesome, but I do have to argue your point on FreeBSD 5. The release might have been very structured, but for me it was a gigantic clustercoitus that caused me to turn my back on FreeBSD. Just one of the many annoyances: The package manager would attempt to use gunzip on the new packages which had been tar/bzipped and thus binary package installation was completely borked for a good while after release. I ended up having to manually patch the package utils. I agree with everything else. It's amazing how Open, Net and FreeBSD work together on a lot of things, particularly hardware support and userland performance. The BSD Way (all of it) is a great comfort to me, and knowing The BSD Way ahead of time really helped me out when I went to start working on big enterprise platforms like Solaris and AIX. I fear many GNU/Linux admins would take much longer to adapt to how things are done on those platforms than someone with a really solid BSD background.
- fjarlq 16y agoRe: "15. FreeBSD hasn't had a default install, STABLE security advisory in ~10 years." You make several good points here, but I'm not sure what you mean by that one. Consider the most recent advisory, FreeBSD-SA-10:07.mbuf, listed here: http://www.freebsd.org/security/advisories.html http://www.freebsd.org/security/advisories.html default install: yep, kernel mbuf code STABLE: yep, FreeBSD 7.1 and later security advisory: yep, privilege escalation in the past 10 years: yep, three weeks old
- bl4k 16y agoYou are correct. It would be more accurate to say 'remote attack' with an up-to-date stable release. The point could be scaled back to say that FreeBSD has undergone extensive peer-review and security auditing to the point that the stable branches have not seen a remotely exploitable security vulnerability in a long time. That said, FreeBSD doesn't excuse sysadmins from not being vigilant with monitoring advisories and keeping their systems up to date. Nor does it prevent vulnerabilities being introduced through installed userland software or other applications. One benefit would be that with patches and ports, you can patch any vulnerability in a service without being forced to upgrade to a new version that might have incompatibilities with your system or that might introduce performance degradation. You see this all the time with PHP, sysadmins run binary upgrades on the packages because of a security vulnerability, only for the website to spit out a bunch of warnings about functions that have been deprecated in the new version.