As some others unix-like operating systems FreeBSD has some particularities aside to the UNIX heritage, licensing and the like. The init system is the way a system starts up and the BSD has always been different. If you happen to be a UNIX admin I am sure you are aware of this and the folks from the Linux side may have heard about it. Back in the day there were two UNIX camps. SysV and BSD. And one of their main differences were found in the init system. SysV has runlevels. BSD has configuration files. Both methods solve a not trivial problem and a difficult one. In the recent years the SysV camp adopted some practices similar to the BSD side of things. In the recent time Linux has adopted and interesting but very controverted on its implementation new init system called SystemD. It brings new and desired features. But the way it’s done seems to dislike to way many people. That said the main distributions are adopting. And this is one sign of the GPL working in favor or companies interest instead of the community. The BSD equivalent would be the implementation of LaunchD from Apple. There is a port effort done but it is still not in approved in the system. And a fork from FreeBSD, a very promising one, is already taking advantage of it. It’s called NextBSD.
Why is this init thing relevant at all to a newbie? It is relevant because in the Linux camp nowadays things seem to happen magically, although there are still distros using the “old fashioned” way. But in the FreeBSD system there is one place where you can configure all the services at startup time. This place is the file rc.conf located inside the /etc directory.
Speaking of directories. The order of things and naming conventions are important. They are not sacred for the sake of a religious belief but because of usefulness. Linux mixes application configuration files and system ones into the same /etc folder. FreeBSD and many other systems don’t. Here lies in one the big differences. The system configuration files in FreeBSD are found in the /etc folder. And the applications are found into the /usr/local/etc/. So don’t look for the firefox or apache config files in /etc but do it in /usr/local/etc.
Speaking of boundaries, naming and sanity. In the recent time a new package management tool has appeared in the Linux ecosystem. It comes from Red Hat Inc. And it has a stupid syntax. It´s called DNF. And the convention for those three letters is Did Not Finish. The guy developing the program apparently didn’t know this, nor did the team. Anyway…
Some Linux distributions change the default configuration, files location and structure from some applications. In the web server realm this means basically Apache and Nginx. FreeBSD doesn’t do this unless it is completely necessary. If you install Apache in FreeBSD you will find the Apache application in the way the developers from that application thought it to be. Not any other “better” or “simpler” way. Obviously this is a matter of taste. But in computing terms and specially for the newbies this is relevant. For example if you happen to install Debian or its best known derivative Ubuntu you will find the Apache configuration broken into different directories and different files to configure it. They made a great effort to document it. But what happens if you wish to follow the Apache official documentation is that you will be completely confused and lost. And frankly, it’s a bit difficult to understand the reasoning behind some changes. The open source unix world sometimes looks like if change was looked per se and not for any tangible and useful purpose.
Shells. There are many shells to play with and each of them has some interesting features and design mindsets. The most common one found is bash. But FreeBSD uses sh by default. You can select in between sh, csh and tcsh for any new user at installation time. But you can also modify the shell completely and use bash if you desire to after the installation time. It is a very easy task to do and the handbook covers it very well.
These are just a few of the worth mention FreeBSD particularities. There are some others such as the ZFS file system, jails (a kind of host-level virtualization) just to mention two big ones.
If you find the articles in Adminbyaccident.com useful to you, please consider making a donation.
Use this link to get $200 credit at DigitalOcean and support Adminbyaccident.com costs.
Get $100 credit for free at Vultr using this link and support Adminbyaccident.com costs.
Mind Vultr supports FreeBSD on their VPS offer.