FreeBSD Support for Leap Seconds

FreeBSD has recently announced a “fix” for the recent leap second added to the Earth’s time. The following has been pulled from their official documentation.



1. Introduction

A leap second is an ad-hoc one-second correction to synchronize atomic timescales with Earth rotation. This article describes how FreeBSD interacts with leap seconds.

As of this writing, the next leap second will occur at 2015-Jun-30 23:59:60 UTC. This leap second will occur during a business day for North and South America and the Asia/Pacific region.

Leap seconds are announced by IERS on Bulletin C.

Standard leap second behavior is described in RFC 7164. Also see time2posix(3).

2. Default Leap Second Handling on FreeBSD

The easiest way to handle leap seconds is with the POSIX time rules FreeBSD uses by default, combined with NTP. When ntpd(8) is running and the time is synchronized with upstream NTP servers that handle leap seconds correctly, the leap second will cause the system time to automatically repeat the last second of the day. No other adjustments are necessary.

If the upstream NTP servers do not handle leap seconds correctly, ntpd(8) will step the time by one second after the errant upstream server has noticed and stepped itself.

If NTP is not being used, manual adjustment of the system clock will be required after the leap second has passed.

3. Cautions

[Read more…]

pfSense 2.2.3-RELEASE Now Available!

The developers of pfSense have made available version 2.2.3-RELEASE. Also, if you missed the update — they have converted the webGUI to Bootstrap.


pfSense® software version 2.2.3 release is now available, bringing a number of bug fixes and some security updates.

Security Fixes

  • pfSense-SA-15_06.webgui: Multiple XSS Vulnerabilities in the pfSense WebGUI
    • The complete list of affected pages and fields is large and all are listed in the linked SA.
  • FreeBSD-SA-15:10.openssl: Multiple OpenSSL vulnerabilities (Including Logjam): CVE-2015-1788, CVE-2015-1789, CVE-2015-1790, CVE-2015-1791, CVE-2015-1792, CVE-2015-4000

Bug Fixes and Change List

The bug fixes and changes in this release are detailed here.

Upgrade Guidance

As always, you can upgrade from any previous version straight to 2.2.3. For those already running any 2.2x version, this is a low risk upgrade. This is a high priority upgrade for those using IPsec on 2.2x versions. For those on 2.1.x or earlier versions, there are a number of significant changes which may impact you. Pay close attention to the 2.2 Upgrade Notes for the details.


Downloads are available on the mirrors as usual.

Downloads for New Installs

Downloads to Upgrade Existing Systems – note it’s usually easier to just use the auto-update functionality, in which case you don’t need to download anything from here. Check the Firmware Updates page for details.

[Read more…]

Running FreeBSD on a Raspberry Pi computer

Raspberry_Pi_Logo.svg FreeBSD is a relative newcomer to the tiny RaspBerry Pi computer, particularly the young Raspberry Pi 2 models. However, FreeBSD developers are working rapidly to bring FreeBSD 11 (-current) to the inexpensive Pi.

DistroWatch has a quick overview of what it is like to install and run FreeBSD on the Raspberry Pi 2 computer board.

Before diving into my experiment with FreeBSD on the Pi, I think it is important to note that FreeBSD is just now getting support for the Raspberry Pi 2. The wiki page for FreeBSD’s status on the Pi has been changing quickly. In fact, the week I purchased my Raspberry Pi 2, virtually no features were reported to work on the device. A week or so later, most of the feature matrix changed from red to green, indicating most of the Pi’s hardware would work with FreeBSD. I think it is also worth mentioning there are no images of FreeBSD’s stable (10.x) branch for the Raspberry Pi 2. There are stable releases for the earlier Raspberry Pi machines, but not the most recent hardware. People who want to use FreeBSD on a Raspberry Pi 2 need to download an image of FreeBSD 11, the development branch of FreeBSD. Running the development (aka Current) branch of FreeBSD may lead to some regressions or unstable behaviour. In short, FreeBSD on the Raspberry Pi 2 is highly experimental and likely to be unstable, use it at your own risk.

Sounds exciting! Read the rest of the article to learn about the benefits and drawbacks of running FreeBSD’s -current branch on the Raspberry Pi 2.

Installing FAMP (FreeBSD 10, Apache, MySQL, PHP) on a Cloud or VPS Server

This tutorial by user Jose Velazquez shows us how to get FreeBSD 10 set up with Apache, MySQL, and PHP on a cloud or VPS server. Thanks to Atlantic.Net, a cloud hosting service that also offers the FreeBSD platform.


apache_software_foundation_logo_3074     mysql-php


This how-to will help you with your FAMP installation in FreeBSD 10 so that you can successfully run a high available stable platform for your web environment. FAMP is simply a software bundle that consists of 4 components that work together to form a powerful web server.  However, in this setup the acronym’s are as follows: FreeBSD (F) is the core of the platform which will sustain the other components. Apache (A) is used for the web service. MySQL (M) is used for database management,  and PHP (P) is used as the programming language.


You need a FreeBSD server that is configured with a static IP address. If you do not have a server already, you can visit our Cloud Hosting page here and spin a new server up in under 30 seconds.

Install FAMP on FreeBSD 10

[Read more…]

Yes, You Can Virtualize FreeNAS

This article by Josh Paetzel informs users on implementing FreeNAS in a virtualized environment.


FreeNAS is the world’s most popular open source storage OS, and one of the more popular questions I get asked is, “How do I run FreeNAS as a VM?” Due to the number of caveats required to answer that question, I would typically short-circuit the conversation by recommending against it, or only recommend it for test environments since the prerequisite knowledge required to “do it right” can’t be passed on quickly. Somehow over time, this message morphed into a general consensus that “you cannot (or shouldn’t) virtualize FreeNAS at all under any circumstances”, which wasn’t my intention. So, I’m here to set the record straight once and for all: You absolutely can virtualize FreeNAS.


Whether you are test driving the functionality of FreeNAS, testing an upgrade for compatibility in your environment, or you want to insulate your FreeNAS system from hardware faults, virtualization can provide many well understood benefits. That said, while FreeNAS can and will run as a virtual machine, it’s definitely not ideal for every use case. If you do choose to run FreeNAS under virtualization, there are some caveats and precautions that must be considered and implemented. In this post I’ll describe what they are so that you can make well-informed choices.

Before we get started though, I should probably start with a disclaimer…


If best practices and recommendations for running FreeNAS under virtualization are followed, FreeNAS and virtualization can be smooth sailing. However, failure to adhere to the recommendations and best practices below can result in catastrophic loss of your ZFS pool (and/or data) without warning. Please read through them and take heed.

[Read more…]

BayLISA June 2015 – Why Groupon uses FreeBSD by Sean Chittenden

Sean Chittenden speaks about Groupon’s use of FreeBSD during BayLISA June 2015.

Groupon is making use of FreeBSD for its databases. In this talk, the following will be covered:

Why Groupon made the switch
What have been some of the benefits
What performance impacts have been observed
What did it take to begin supporting FreeBSD for production use
What have been some of the benefits
What were some of the challenges that were encountered from the
Interesting work happening in FreeBSD that is relevant to the future


Install Sonarr on FreeBSD

sonarrThis short tutorial will show you how to get Sonarr set up on FreeBSD.

Installing Sonarr on FreeBSD isn’t hard, but does require several commands. If you aren’t familiar with Unix or Linux, this guide should hopefully be enough to get you up and running. This guide was tested under FreeBSD 10.1-RELEASE.

If you want to do this safely, install and run it inside a FreeBSD jail.

mv /usr/local/etc/pkg.conf /usr/local/etc/pkg.conf.backup
pkg install mono mediainfo sqlite3
tar -xzvf NzbDrone.master.tar.gz
ee /etc/rc.d/run_drone

At this point you have a text editor open. Copy and the paste the following line into the editor:

/usr/local/bin/mono /root/NzbDrone/NzbDrone.exe --nobrowser &

  • Hit Esc, Enter, Enter to leave editor and save changes.

chmod 555 /etc/rc.d/run_drone

At this point Sonarr is installed, and we have it set to start on boot. You can execute run_drone, reboot the system or restart the jail if installed into one.

If you are wondering what is going on in the commands, here’s a brief rundown. FreeNAS 9.2 may have an older version of pkg installed. By moving the configuration file, it will heal itself and just work™, although this should not be necessary on newer versions of FreeBSD. Then we install mono, mediainfo, sqlite3 and all their required dependencies, including perl. Next up is Sonarr itself. Grab the files and extract, simple enough. Lastly we need to get Sonarr launching at boot, so we make a small script in rc.d which gets run at boot.

Unix experts will see that this is very hacky and insecure, especially as everything is running as root and listening on all IPs by default, so it’s a really good idea to put this inside a jail.


Install PostgreSQL server on Raspberry Pi from FreeBSD port

This tutorial by user Kenno shows us how to get PostgreSQL server set up on Raspberry Pi from FreeBSD port.


postgresql-logo   Raspberry_Pi_Logo.svg

Before I wrote this blog post, I had thought there was no binary package for PostgreSQL server for FreeBSD 11 running on Raspberry Pi. Hmm… how wrong I was! I just wasted the whole night compiling Postgres from source. DOH!

Anyhow, here’s the step I took to do it. If you’re familiar with FreeBSD, there’s nothing new here. But, I only use FreeBSD once in awhile, and so I tend to forget a lot what I do.

cd /usr/ports/databases/postgresql94-server
make config
make install clean

After a very long time of waiting, I was presented with the following message:

To initialize the database, run                                                                                              
  /usr/local/etc/rc.d/postgresql initdb                                                                                      
You can then start PostgreSQL by running:                                                                                    
  /usr/local/etc/rc.d/postgresql start                                                                                       
For postmaster settings, see ~pgsql/data/postgresql.conf                                                                     
NB. FreeBSD's PostgreSQL port logs to syslog by default                                                                      
    See ~pgsql/data/postgresql.conf for more info                                                                            
To run PostgreSQL at startup, add                                                                                            
'postgresql_enable="YES"' to /etc/rc.conf      

Let’s initialize the database:

[Read more…]