 FreeNAS with ZFS is an excellent place to store all of your data, but as so many people have learned The hard way is the best way to describe it. RAID is not a backup. No matter how many drives you put in this and how resilient ZFS is, bad things happen to hardware occasionally. It can go completely wrong. It can completely fail. Disaster can strike and you want to make sure you have it backed up. Now I've already covered previously in another video how to do ZFS replication with FreeNAS to another FreeNAS box. So great, you've got it stored in another FreeNAS box. Even better if you have it stored in a FreeNAS box off-site. But what about cloud credentials? How do we get it to sync to places like back plays? Well, as I'm going to cover in this video is how to set up Cloud sync tasks and how to get the data out to two another servers such as, you know, in the cloud, whatever cloud you may choose, which yes, I know it's just someone else's computer, but it's someone's computer in a big data center with lots of hopefully infrastructure built around it to keep it all safe and secure. Now, the first thing I wanted to highlight was I'm in the RT FM here, which I always recommend people do. Read the manual, read the fine manual here. Cloud credentials are stored in encrypted form to be able to restore cloud credentials from a saved configuration, export password, secret seed must be set when saving a configuration. Let me cover that real quick here because I bring these things up for a really good reason. First, let's say you did back up to the cloud and then disaster struck and you're whatever destroyed your FreeNAS completely eradicated its existence and you go, but I got a backup of the backup file because I went here and I hit save config, but then you forgot to check the box. And if you forget to check the box, you lost your cloud credentials. And maybe you don't have those cloud credentials somewhere else where you can pull that data back down. And if you don't have that that data, if you encrypted it especially, you may not be able to get it back down. So this is unfortunately things that have happened. So I just want to start right here with important detail of this, making sure you export the password, secret seed as I stated in their documentation. Now, for clarity, we are using 11 to you for that one. That's the latest version as of June 2019. And I will also note a bug that I consider a bug. It's a feature request, but it's a bug as far as I'm concerned. And the priority set to low, which also makes me unhappy. The cloud sync tasks, we're going to when we cover all of them, you're probably going to ask the question, what if it fails? There is a notice inside the cloud sync tasks, but not one sent to you. And user comments and feel free to add your two cents here, that we really would love to see this feature before it says status ready for testing, it's stated for 11.3 beta one. But I would really love to see this sooner, cross their fingers, maybe someone likes to do this. Basically, what this is, is letting us know that if a cloud sync fails, if it does not upload the data in a sync fails, you don't get an email or a notice. I don't know how this didn't get put in as a base feature, but I will at least cover that this is a concern and an issue right now that you do kind of have to check or set up your own scripts to check to make sure the task is working. All right, let's take a look at the settings here in the cloud credentials, I've set up two of them for this demonstration back plays b2 for any actually to demo. One thing I'll comment here when you do this, I'm blurring these, but yeah, they're in the clear, you can see the account ID application ID, and you can see the master application key right here. So I'm blurring them out, but yeah, they do not obscure them. But when you go through and I also set up a demo with SFTP, it does do here and you have the show option. So you can show the password. So interesting, I didn't set this up, but it does have an option to do put a path in. So this is SFTP over SSH, which is great and secure. I'm using password authentication, but yes, it does support key authentication. And they do have an instruction how to set the key up, I just didn't do it for the demo of this video. All right, so once you have your cloud credentials, they're pretty easy to add. And like I said, they get quite a long list, you give it a name, you choose all the options, Dropbox, Google Cloud Storage, Google Drive, Hubic, Mega. For anything you choose, if you go over here to the little help option, it leaves a link, switch to another one like Microsoft OneDrive even go here. And it will link to the documentation for either creating an account or how to do it, and especially in the case of like the Google one, if you use your Google Drive, you have to build an access token, and they leave you right to the link of how to build the access token for your account, which was great to actually have that in there. So you're not just kind of left a hole in the bag of, okay, now I got to figure out how to get this done. Now the thing missing from here is generic S3. I don't know a way to do this, because I haven't done a lot of testing, but it looks like it supports Amazon S3, but not what they refer to as like generic S3. So you can use companies that are just S3 compatible. I haven't really done any testing in that. So I didn't, I looked a little bit, but it didn't really seem to have an option other than all the different S3 options. And I bring this up because there are other services that you may want to add that use bucket storage, but don't, that aren't one of these companies that you want to add. I'm, maybe I'll do some experiment with that in the future, but it does support the ones that are listed here. So we'll just leave it at that. All right, we're going to go ahead and close this. Once you have your cloud credentials, then you're going to move over to your task. So let's go over here to tasks and cloud sync tasks. Now I've got a handful of them set up. Let me make this a little bit. Well, we'll just do this. You can see things a little better. The hour, minute, day of the month, month, day of the week. So let's talk about how to set up a task. These are all set up to run hourly. This one, because of the asterisk, is set up to run every minute because I was playing around with that. And to add one first, we get an inscription backup, whether we want to push or pull. Push means get all the data there. Pull means get all the data back over here. So if you're restoring a free NAS, you're going to want to do a pull. If not, you do a push. Here's all the different options that we have. We just have the two different cloud credentials. So back plays B2 or Linux test box. We'll go ahead and choose Linux test box. Some test folder. And what this does is it's where you want to save it. So it's going to start at the root because we loaded here, but then some test folder means create a test folder for that, then choose the path that we want. And actually what I've got set up here is a cloud backup demo. Remote encryption, choose your encryption password, choose the encryption salt, and then choose a custom sync task and whether or not you want this enabled. Now if you hit custom, it lets you choose here and it's going to tell you when it's going to go. Maybe you want something daily, weekly, monthly. And if you go, I have a weird schedule. I wanted to do it like every eight minutes or every 10 minutes, you can put commas, actually be 16 comma 24 comma 32 comma 40, I'm a 48. And then you kind of get the idea from here, you're going to go and say, I wanted to run every so many minutes. And now you can see that how many, what times it will run. Run it all hours by putting an asterisk in there. But you kind of get what, sorry, you get the idea that you can build these custom scripts, or when you want the schedule to run. We'll hit save. Encrypt, I've chosen encryption without encryption salt. Now it also has the options for file encryption of the file name as well, not just remote encryption, but re-crypting a name. So anyways, I've got these already set up and already have a data synced with there. So let's look at the names here. So let's look at the back plays one first. So this is a push back plays encrypted back plays no encrypted, I'm just going to force them both to run right now. Now, yep, we'll run this one right now. Yes. And you can click here to get the detailed status, whatever checks transfers, etc, etc, success tells you what was changed. And you can download the log for each of these. And this is why I pointed out before, this is the only place you know if there's success or failures by looking at it, it does not send you an email alert. Let's close these things here. So here are the two spots where we have the data going to inside of there. So we have the free nas encrypted. And you can see all the gibberish that's in here, because you can't see the files, the files are completely scrambled and encrypted. And we're not going to see anything. Here's the no encryption. And here's the envelope for our company with our address on it. That's right here. Here's some text if I wanted to download or create a link to it. You know, I have this right here. Now there's also, because there's more than one of this, some text file, this is the copy one of this one here, we can expand and it keeps your vision. So this is a feature of back plays, not a feature of free nas. So depending on how you set your bucket up, you can decide how many revisions you want to keep, what versions of the file you want to keep. And obviously, that's important because you don't necessarily want it to just automatically back up everything and overwrite every time because what if something corrupt the defile, so you want to keep revisions, the good news is the default back plays accounts do set up and offer revisioning on there. So we're able to get either version of the file. Now, one of the questions people might have is when you do the restore, which we're going to cover, how do I know what version of the file I'm getting by default, you're always going to get the latest version of file, but there is options and simply deleting the current version of the file that's in here means when you do a poll, it will grab the previous version. So we'll cover that in a second so we know which one we're getting when I go to the restore. So the difference between it obviously the encrypted and unencrypted is whether or not you trust the bucket provider to provide the data and hold on to it in a secure manner if you encrypt because it encryptions happening prior to it leaving. If someone were to somehow figure out how to get into your back plays bucket, they would have nothing but a pile of gibberish. Now your gibberish is only as good as the password you use to encrypt it. So let's look at this and we're edit this. We did a horrible job of encrypting this because the encryption passwords Thomas 123 and encryption salt is 123. So you set these up. It does allow you to choose the passwords for these things. But please remember what they are and seeing as you don't have to type them in very often document what you put or back it all up. So this gets backed up with it with the export set a secret seat as well and make sure that you have a high entropy password. So make it difficult that way in the worst case scenario where someone somehow found their way into your bucket. Like I said all your backup should be gibberish to them and it's going to be only as good as the password is right here. And as long as this all matches when you do the restore away you go. Now there's a couple different ways when you do this encryption when you do the restore to handle that. So direction push we could say direction poll and then run the same task again and away we go. I kind of wish they had an option just to hit like clone this task but they don't but I did do a pull data back option right here. So what this does is pull data back and go here and we're going to edit. We see we have the same password we've seen everything's the same except for doing a poll and it's going to cloud restore demo. So let's actually open up a window and show what files we have on there and we'll make some changes and we'll do a restore. All right so you can see the path here this is the Freeness server this is the cloud restore demo folder and this is the cloud backup demo. So here's where we have our backups and we'll go ahead and open with text editor. This is some text some more text and even more text. All right we'll save close and double check make sure I saved it yep even more text awesome. So now we've created a couple revisions of this some text file and we're going to go ahead and run the backup so cancel let's run it it doesn't really matter what we'll run it on the encrypted one so here's the b2 encrypted run now continue as started but obviously it'll complete almost instantly we'll go ahead and refresh the files in here this is where things get tricky and also why I chose the encrypted one you don't necessarily know the revisions of things when you're encrypted because you chose to encrypt the file names hence the reason you may want to consider that before you're doing this so when we do a restore by default it's going to restore this last version I only know it's the last version because the date on it I did this one on six eight this one's from six nine so if I do a restore and let's go ahead and see our cloud restore demo folders empty fullback data we'll just show you and look at right here go to edit show you what it's doing the bucket is the freelance demo freelance encrypted we're pulling from it's landing in restore demo we're doing a poll we have the same password now please know I don't have this task enables I don't want it to restore things on a regular basis but we wanted to be able to pull that data and have this set up so when I choose to like right now run now continue running success you pulled all the data back even more text is in here but what if I wanted that one that before we put even more text in there how would that work well what we're going to do here is delete this file so I can download this file if I want and by the way they're using our clone on the back end maybe one tail do a video on how to do our clone from the command line and do this manually but for the most part you want to just rely on the free nas one if you're using the free nas upload it all rely on free nas download it all but in the background it is running our clone in case you're wondering what it's doing we just know by the revision date this is not the file I want I wanted that one that had more text in it so I'm going to go ahead and delete this I'm sure delete that file but now I only have two copies from six eight ones at 11 o'clock ones at 10 19 so it'll actually now pull this one the other one still exists but because free nas isn't handling a revision back blazes back blazes only pulling the last version of said file so now we're going to go ahead and run that same task again it ran let's see what's in this file now hey look it's now the previous version file that just has some more text in there so this way it handles the restores on here for pulling them back and the revisions but like I said this is a feature of the cloud storage provider not a feature of how the system works in terms of free nas itself it does not have a revisioning system for this it does in terms of snapshots that you should be keeping but in terms of the backups it's just backing up whatever you said was in that folder and it does not back up the snapshot so this is simply a file level backup this is not like zfs replication where it's backing up at the block level so we're still just doing everything as files so let's talk about what happens when you use this as an sfdp now the same rules apply go ahead and edit this this is unencrypted and we've told it to just go to a folder called no encryption i'm logged into a standard linux box run in devian uh there's nothing in here this is the home slash free nas the username is free nas here logged in as that user so you see there's no files here it's just empty and what we wanted to do was put things into well actually we'll show you what happens when you don't so what if you didn't put anything in here we'll hit save and we're backing up the same cloud backup demo spot get rid of some of these columns so back up to linux no encryption go ahead and run this right now and with no folder on it and there's all those files some text some text copy lts symbol if they didn't go in any folder or anything at all because we didn't specify once so now let's go ahead rm star uh get rid of all the files back to empty here so let's go ahead and edit this we're gonna make a folder called no encrypt no encryption save back up to linux no encryption let's go ahead and run that now and now there's a folder called no encryption look in the no encryption folder there's all the things now next one do is linux box encrypted so same thing we'll run it but we'll also here look at what it did here we made a folder called encrypted same files are back up same stupid weak password that you should ever use and we chose file name encryption and remote encryption so let's go ahead and and now we have an encrypted with nothing but garbage in here now maybe you do want the file names there and like I said you can just check this box save switch back to over here actually we'll get rid of everything and we'll run it again because we'll run it with encryption now but we chose not to encrypt the file names so now I can see the names of all these files but they all end in a dot bin because they're encrypted so let's try to text up in and it's gibberish and it's letting you know it's done with our clone so there's not any way without the password to unencrypt it but that's pretty much it it's pretty straightforward to do it's easy enough to set up you can choose your destinations or easy to have everything configured it's probably good while you're creating it because if you're a sysad man and you're using this go ahead and create an not enabled restore option so you know we are going to restore things too because you know you don't want to be scrambling to do it if someone says hey I accidentally deleted that file so creating a pullback data from whatever cloud source you're doing it's not a bad idea to do spot check once in a while well anytime you're doing any type of backups any untested backups are just wishful thinking so I always recommend when you create a backup that you test it any untested backup like I said I can't repeat this enough to people untested backs up a wishful thinking because you should not only make sure that things are backed up and trust that we have a success but make sure you can restore because that's another phone call we've gotten a lot is people go well it was all set up and we were checking the logs and it was uploading but then we tried to restore something and it's there they weren't trying to restore it because they were testing they were usually trying to restore it under duress which creates quite a bit of problems for people sometimes because they can't get things put back so please test everything just I don't want to sound like a broken record but the calls come in a little too often for that but that was it for setting it up it's pretty straightforward it's pretty easy please free nas which I'm sure the folks at free nas are listening and I will leave a link to this in the description of can we have this before the 11 3 beta 1 or maybe 11 3 beta 1 is going to be out sooner than later so that would be good too I don't know when and I didn't look at the roadmap to see exactly when it's tight titled for but I do want a notification if this backup fails so we don't have to just go in there and check it once in a while but that was it like I said back plays a great service really affordable for doing this if you're looking for a cloud backup on there I don't have I should set an affiliate link with them I do not have one but it does work great with back plays it does work great if you want to set up your own ftp or I'm sorry sftp please don't use ftp unless it's some horrible worst-case scenario that you have to but like I said it's a great system it does work you can encrypt everything which is wonderful that is a feature that was added in the 11 2 series was pre-encrypting all the data before it goes up there this checks a lot of compliance boxes and makes you sleep better at night that you're encrypting everything that you're saying to the cloud and it's safe and you know protect it all right thanks thanks for watching if you like this video give it a thumbs up if you want to subscribe to this channel to see more content hit that subscribe button and the bell icon and maybe youtube will send you a notice when we post if you want to hire us for a project that you've seen or discussed in this video head over to LawrenceSystems.com where we offer both business IT services and consulting services and are excited to help you with whatever project you want to throw at us also if you want to carry on the discussion further head over to forums.laurancesystems.com where we can keep the conversation going and if you want to help the channel out in other ways we offer affiliate links below which offer discounts for you and a small cut for us that does help fund this channel and once again thanks again for watching this video and see you next time