Backups to the Future: Eliminate Tape Backups with FreeNAS and Bacula

The future of backups is here, but unfortunately, there aren't any Delorians.

Backups in today's environment are in a state of flux. Tapes have been the mainstay of most organizations for years—and in some cases, decades. However, as the cost of hard drives decreases and their capacity increases, conventional wisdom about backups and tapes is changing. Although tapes still prove useful for archiving and offsite storage, inexpensive disk-based technology slowly is creeping into areas that tape has traditionally dominated.

Many enterprises find it's just as easy and reliable to back up data over their network to near-line storage, such as a Storage Area Network (SAN) or Network-Attached Storage (NAS), instead of tape. Also sometimes referred to as disk-to-disk (D2D) backups, the benefits of near-line storage are many—especially speed and capacity. When deciding to go near line, you really have only two choices: SAN or NAS. Of the two, NAS is more cost-practical for most shops. In this article, I explain how to implement a near-line backup to a NAS to illustrate how easy it is to begin the transition from tapes to disks.

I've chosen two programs for reaching the goal of a tapeless backup: FreeNAS (to create a networked storage area for backup files) and Bacula (to automate backups and provide a pseudo-daily, weekly and monthly rotation).

To keep things simple, let's build two systems, one running FreeNAS and one running Bacula on top of Fedora 8. All configuration done on the Bacula system for this article was performed as root, but it also could be done with sudo. Bear in mind, the options covered in both programs here represent only a handful of their full capabilities.

FreeNAS

FreeNAS is one of the simplest programs I have ever deployed. It's small enough to run a system from a CD or USB key. However, for this example, let's install it on our server to the local hard disk. On your system, I suggest at least 256MB of memory and SATA drives for decent performance. If you want to use RAID on your drives, use hardware-based solutions. They are faster, and there have been issues with the built-in software RAID capabilities of FreeNAS. If you opt to use hardware RAID, check the FreeBSD hardware compatibility list, on which FreeNAS is based, before making a purchase.

Download the latest ISO from the FreeNAS site, and burn it to CD (version .684b at the time of this writing). Boot the system from CD, and when you come to the options menu (Figure 1), select option 7 to install the server image to a local hard disk. Next, select option 2 to create two UFS partitions. UFS is the native filesystem in FreeNAS, and as we plan to access our data on the disk via a networked protocol (NFS), any system should connect to it. Select these options to create a small partition for the server software, and use the rest of the space for a second data partition. When prompted, enter the name of the CD drive (acd0 in my install), and then enter the destination drive (da0). When the install routine is complete, enter 3 at the prompt to return to the main menu, and then enter 1 to assign an interface. Accept the default interface, and give it an IP address (unless you are using DHCP). Once assigned, return to the main menu, and reboot the machine. Remove the CD, and the system now should boot from the system partition on the disk.

Figure 1. FreeNAS Install Options

Once the system is back up, open a Web browser from another system, and enter the IP of the FreeNAS machine as the URL to access the management site. At the prompt, enter admin as the user name and freenas as the password. From this management site, you can change a multitude of settings, but for now, we need to change only our hostname (Figure 2), mount the auto-created DATA partition and enable NFS.

Figure 2. Setting the Hostname on the FreeNAS Management Page

Click the Management link under the Disks section of the Web page. You should see a message saying that you need to add your hard drive to the disk list. Click the + icon to add it (Figure 3). Leave all the options at their defaults, except PreFormatted FS. Set this to UFS, as FreeNAS already has done the work for us. Once you click the Apply Changes button, the status column of your disk will change to ONLINE.

Figure 3. Adding the Disks

Now click the Mount Point link, and click the + icon again on this page to edit the Mount Point properties (Figure 4). From this screen, change the partition to 2, as partition 1 is the system partition, which cannot be used. Leave the File System as UFS, and enter DATA as the share name. Click Add when finished. This takes you back to the original Mount Point page. Click Apply Changes.

Figure 4. Mounting the DATA Share

Under the Services links, click NFS. Check the Enable box to turn NFS on, and type your network address range in CIDR notation. Click the Save button, and your NAS build is complete.

______________________

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Tape Sets

zied's picture

Hi,

I followed this article with great interest, it's really instructive.

I implemented the same "algorithm" but with tapes.

I'm confused about how many do I need, and when to change ??

can you help please ?

kind regards,
Zied.

Share what you learn what you don't

ahhhhhh!

uslacker's picture

Did he really tell us to change all the passwords to a default so we can get the system up and running? Then go back later....

Isn't this how we got ourselves in to the security quagmire we've been trying to get out of for years? Too many simple passwords or "we'll do it later.." has left back doors the size of trucks in our networks.
Please, teach us better than this!

\\uSlacker

\\uSlacker

White Paper
Linux Management with Red Hat Satellite: Measuring Business Impact and ROI

Linux has become a key foundation for supporting today's rapidly growing IT environments. Linux is being used to deploy business applications and databases, trading on its reputation as a low-cost operating environment. For many IT organizations, Linux is a mainstay for deploying Web servers and has evolved from handling basic file, print, and utility workloads to running mission-critical applications and databases, physically, virtually, and in the cloud. As Linux grows in importance in terms of value to the business, managing Linux environments to high standards of service quality — availability, security, and performance — becomes an essential requirement for business success.

Learn More

Sponsored by Red Hat

White Paper
Private PaaS for the Agile Enterprise

If you already use virtualized infrastructure, you are well on your way to leveraging the power of the cloud. Virtualization offers the promise of limitless resources, but how do you manage that scalability when your DevOps team doesn’t scale? In today’s hypercompetitive markets, fast results can make a difference between leading the pack vs. obsolescence. Organizations need more benefits from cloud computing than just raw resources. They need agility, flexibility, convenience, ROI, and control.

Stackato private Platform-as-a-Service technology from ActiveState extends your private cloud infrastructure by creating a private PaaS to provide on-demand availability, flexibility, control, and ultimately, faster time-to-market for your enterprise.

Learn More

Sponsored by ActiveState