Backup FreeNAS to an external USB hard drives

Status
Not open for further replies.

Bostjan

Contributor
Joined
Mar 24, 2014
Messages
122
I would like to backup my FreeNAS to an external USB hard drives, but I don't know how.
All tutorials I found online are after the point where drives were already connected.


I have a beginner problem. Once I plugin USB hard drive to FreeNAS box, where does it appear? As I understand it does not appear in GUI but you have to do it in command line.
I would like to know after I plug the drive in what to type in command line to see the drive? What to do to ‘prepare’ the drive? Mount it? What to mount? What to type?


I’ll use ZFS send and receive to manually backup my snapshops. When I’ll connect second drive how will I know which dive is which and where to copy a particular snapshot?

How to prepare hard drive for ZFS FreeNAS? Format it? How to format to ZFS?

I hope you’ll help me with these beginners questions.

Thanks.
 
Joined
Jan 9, 2015
Messages
430
A better option would be to plug the drive into a client machine of your choice(I'm assuming Windows here). Format the drive NTFS and backup the drive over the network. If your FreeNAS was to crash you'd have a backup right to go in your clients native format.

May programs can handle this backing up in Windows. Personally, I use robocopy by Microsoft. It is free and very similar to rsync. Only copies the files that have changed. Others may jump in with some other programs. I only have one Windows machine on my network. All the rest are Linux or BSD. So I use rsync 99.9% of the time.
 

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
what is a better idea?
If you want to back up to a directly connected disk, eSATA is a better bet than USB.

In this forum you'll be actively discouraged from using USB for anything important because it's just not particularly reliable. Not only that, but many of the benefits you get with directly attached devices are lost with USB - primarily passing through SMART data so FreeNAS can give you early warning of certain types of disk failure.
 

Bostjan

Contributor
Joined
Mar 24, 2014
Messages
122
Thanks for replies.

My motherboard doesn’t support eSATA so, USB is my another option.

I haven’t thought about backup over network so far. I was looking for an option that also verifies the backup – something like ZSF send and receive.

Does Robocopy also provides a backup verification– and latter that also checks older backups that are still valid, that haven’t been corrupted yet. Some sort of checksums like in ZSF.

Nevertheless I would still like an answer for my first question: when I plug the USB drive in, how can I find it and prepare (mount?) in command line?

Thanks.
 

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
My motherboard doesn’t support eSATA so, USB is my another option.
As long as you have a spare PCIe x1 or better slot, there are plenty of options available for eSATA expansion cards. The cards I'm using are based on the SiI3132 controller, which is well supported in FreeNAS. My box actually has an eSATA port too, but I generally use them in pairs, hence the expansion card.
when I plug the USB drive in, how can I find it and prepare (mount?) in command line?
I wish I could help you with that. When I plugged a USB drive into my box, it was detected but I got "(da6:umass-sim2:2:0:0): fatal error, failed to attach to device" in the console.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
If you really want to connect your USB hard drive to your FreeNAS box and copy your data, as far as I know you can still do this but it's all a manual process. Because you are asking how to do it makes me assume you are not ready for this and you are apt to cause more harm than good. If you are really wanting to pursue this, do a search on how to mount ntfs on freenas for write operations because there are several threads here that describe the process.

In my opinion, your best bet is to use the advice given above, connect your USB drive to a networked computer and copy your data over. If this is a Windoze based computer, I have had great success with SyncToy v2.1 from Microsoft. It will copy your files without issue from the source to the destination and if you run it again later, it will only copy/remove changes. Check out the software, but there are others as well. From a winodze perspective, it doesn't get much easier.
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
If you have a spare SATA port and 3.5" drive bay available, you could mount a removable drive in your server. I have a Vantec MRK-401ST-BK in my primary Windows machine.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
If you have a spare SATA port and 3.5" drive bay available, you could mount a removable drive in your server. I have a Vantec MRK-401ST-BK in my primary Windows machine.
That is also a good viable option, however I would caution the end user to power down FreeNAS when installing and removing the drive, do not hot-swap unless you have to because there is always a risk of a problem.
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
Thanks for pointing that out. I always power down my machine when installing & removing the drive. I'm sure others might not be so careful.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
I know for a fact others are not so careful. I watched one fella standing right in front of me and said something like "look, it's hot-swap", pulled the drive out, we all looked at the Raptor drive, then he shoved it in. A loud POP and white smoke. The server survived however when he reinstalled the drive, the power SATA connector was just slightly off and he shorted the power out and melted the hard drive SATA conector. The server was examined and was unharmed and put back into service. And the thing is, it likely would have been fine if he took his time reinserting the drive vice shoving it home.

Yes, I never hot-swap.
 
Status
Not open for further replies.
Top