Freenas Backup To Backblaze



Cloud Backup is Simple. If you don’t have a second data center to back up to, TrueNAS includes the tools to back up your data to public or private clouds like Amazon S3, Azure, Backblaze B2, Box, and Google Cloud Storage. Pay for what you use with no upfront costs and no additional TrueNAS licenses. By incremental I mean it will only sync files that are changed, not do a full backup each time. I know you can set backblaze to retain old file versions but that has nothing to do with freenas or snapshots. Sync sounds the best for push then. Sync there as well? By incremental I mean it will only sync files that are changed, not do a full backup each time. I know you can set backblaze to retain old file versions but that has nothing to do with freenas or snapshots. Sync sounds the best for push then. Sync there as well? In that instance, you were relying on Backblaze’s versioning as a “backup,” as corrupted or encrypted source files would simply sync to Backblaze B2. Hyper Backup is a true backup – and coupled with Backblaze B2 – a great option for important data!

  1. Backup Freenas To Backblaze
  2. Freenas Cloud Backup
  3. Iphone Backup To Freenas

FreeNAS is an open-source operating system based on FreeBSD that allows you to create your own NAS on a dedicated machine or a virtual machine in a few simple steps. A NAS created with FreeNAS is the fastest and cheapest way to create a network device for file-sharing or backup.

FreeNAS is based on ZFS, which is an open-source file system, a RAID controller and an enterprise-level volume manager, which guarantees perfect data integrity. Eliminates most, if not all, of the deficiencies found in legacy file systems and hardware RAID devices. Among the other basic and advanced features, which make FreeNAS a professional choice, we find a sophisticated web interface, the ability to create SMB / CIFS shares (Windows File shares), NFS (Unix File shares), AFP (Apple File Shares) and iSCSI (block sharing), the ability to connect via FTP and S3 (based on Minio), and data snapshot and replication capabilities.

See also:Backup to NAS with Iperius Backup

In this guide, we will configure a basic system on a Hyper-V virtual machine, with the configuration below:

  • One virtual disk on IDE interface to install the FreeNAS operating system
  • Two identical SCSI virtual disks with which we will then create the RAID system for data storage

Please note: in this tutorial we used a virtual machine only for testing purposes. To get the maximum safety when using a RAID array, please consider using a physical machine, or make sure the virtual disk files used to build the RAID array are saved on different physical drives.

Let’s see the configuration in the image below:

Clearly, the exact same configuration and installation can be done on a physical machine. In this tutorial, the user is considered to be able to configure and start a Hyper-V virtual machine in a basic way.

The first thing to do is to download the FreeNAS installation disc from the official site, in the form of an .ISO file: https://www.freenas.org/download-freenas-release/

Once you have created a new virtual machine in the Hyper-V management console, connect the .ISO file as a virtual machine boot CD, as shown in the images below:

Then proceed starting the virtual machine (the boot from CD should be set by default, as shown in the image above) and the FreeNAS installation:

In the next step, the installer will ask you to select the disk to install. Select the single disk that we have created earlier for this purpose, but leave the other two deselected (we created them to be used as a RAID volume to store data, so we will configure them later):

On the next screen, set the password for the root user. This password will then allow you to access the web interface of the NAS:

On the next screen, select the BIOS boot mode, for a better compatibility:

Then the installation will be completed in a few seconds. Now disconnect the ISO file (the installation CD) and restart the machine:

FreeNAS configuration

Upon restarting, the FreeNAS system will be ready for configuration, showing the following interface:

Here you can see the IP address of the NAS system, which is the one needed also to access the web interface for configuration. You also have the ability to configure different system settings, such as the network parameters and the root user password. From here you can also restart the FreeNAS system or access the shell.

Now let’s see how to access the web interface to configure the FreeNAS system.

The first thing to do is to configure the two SCSI disks we have created as a single RAID volume, which will be used as the main disk for data storage and network shares.

After logging in, proceed with the configuration:

Quit the wizard and check if the disks are correctly detected:

Then proceed to create a RAID volume with the two disks highlighted in the image above.

Let’s go to “Volume Manager” and set everything up as follows:

Give the Volume a name (here we chose “RAID”), click on the “+” button to add the available disks, then set the volume layout to “Mirror” (ie a RAID 1). By default, the maximum available capacity will be selected. Click on “Add Volume” (any data on the disks will be erased). Then check that the RAID volume is created correctly:

Create a user account

Iphone

Our purpose in configuring this FreeNAS system is to create a network device for data backup, through an SMB share for Windows systems.

The volume /mnt/RAID we have just created is also called a “Dataset“. As you can see in the menu on the left, you can create additional Datasets, to which you can also assign different SMB shares and different user permissions. In this example, we will use the newly created volume, /mnt/RAID, directly as a Dataset.

Now you need to create a user who must have write and read permissions in the Dataset /mnt/RAID and an SMB share to access the data from Windows systems.

To create the user, go to the appropriate menu and click on “Add user”:

Specify the username, the Full Name, and the password. You can leave all other settings to their default values.

After you added the user account, you must make sure it has all the necessary Dataset permissions. So go into the list of volumes, and under /mnt /RAID, click on “Change Permissions”:

As we can see in the image above, you must select the user you just created, then set “Permission Type” to “Windows” and check the “Set permission recursively” option. Apply the settings by clicking on “Change”.

Create an SMB share

All that remains now is to create the SMB share.

Go into “Services – Control Services” to enable the SMB service, to allow access to the share from Windows:

Click on “Start Now” and select the “Start on boot” option.

Go to the “Windows (SMB) Shares” menu and click on “Add Windows (SMB) Shares”. As you can see in the image below, it will be required to specify the path of the share (in our case always /mnt/RAID) and its name (for the sake of clarity we have called it “RAID”, like the Dataset, but the name, will then be the one visible from Windows and can be any name of your choice).

At this point, the configuration is completed. From any Windows machine on the network you can immediately access the share and copy any files into it.

Backup to NAS

Now that your FreeNAS device is configured and the shared folder accessible by the specific user and password you created (this is very important to avoid data loss due to ransomware viruses), you can use it as a network destination for Windows backup.

To perform backups to FreeNAS of files, drive images, database backups or virtual machines, it is advisable to use Iperius Backup, which, in addition to providing many types of backups, allows you to automatically authenticate by user name and password in network shares, to guarantee a high level of security.

To see how easy it is to back up files on NAS with Iperius, see this tutorial: https://www.iperiusbackup.net/en/backup-nas-make-iperius/

(Italian, French, German, Spanish, Portuguese (Brazil))

Context

  • I have a FreeNAS setup
  • I want a cheap offsite backup solution
  • Backblaze only offer S3 storage solution
  • I have virtual machines on zvol to backup (not just files)
  • ZFS send/receive is very convenient if you have another zfs system in other
    location

I choose zfsbackup-go, this tool use zfs send/receive to generate archives on S3 storage space. This software is not ready for very critical use, still in « beta » missing some features like deletation on remote location from the command line.

Advantages

  • Can backup zvol as well as dataset
  • Differential backups based on snapshots
  • Encrypted backups
  • Compressed backups
  • Compatible with all S3 solutions

Drawbacks

  • You can’t use backups without re-import in a ZFS pool (so real backups
    not a archives solution)
  • Still in beta

How to

Backup Freenas To Backblaze

  1. (Optional) Build zfsbackup-go for freebsd with crosscompile from a linux
    1. You need GO
    2. git clone git@github.com:someone1/zfsbackup-go.git
    3. GOOS=freebsd GOARCH=amd64 go build -o zfsbackup main.go
  2. Generate a gpg key gpg --full-generate-key
  3. Export the private/public gpg keys

    1. gpg --list-keys
    2. gpg --export-secret-keys -a keyid
    3. gpg --export -a keyid
  4. Create the S3 credentials you need
    I use BackBlaze because it’s the cheapper one, but you can use every S3 storage service or implementation you want.

  5. Configure periodic snapshot in FreeNas

  6. Configure zfsbackup cron task

    • You need to ensure the schedule is after the snapshot
    • I have develop a very little script to have a more simpler crontask because zfsbackup only support one Dataset at a time
    • Command DATASETS='Tank/Dataset1 Tank/Group/Data1' /root/zfsbackup.sh

Freenas Cloud Backup

Conclusion

Iphone Backup To Freenas

  • This solution offer very good performance like 15MB/s during backup operation with only 10% cpu usage on Xeon D1521. My Orange ISP uplink is the limitation here.
  • With incremental snapshot, BackBlaze is a very effective solution at low cost like less than 60€ a year for a 100GB on disk backuped VM.
  • DO BACKUPS
  • DO BACKUPS
  • DO BACKUPS