Backing up a Linux System to a ReadyNAS

0

So I'm hoping for some guidance here. What I have is a NetGear ReadyNAS 10TB connected to our subnet. Additionally I have a number of servers that serve a fairly mission critical function.

So what I need is a set-up, that can automatically take a full image of the server and then upload it to the NAS on a nightly basis. We also have a backup server that is just sitting there empty... So if one of the other servers fails for whatever reason, I want to be able to simply pull the saved image from the NAS, slap it on a USB and restore the server with minimal downtime.

I initially thought to use CloneZilla to accomplish this, but everything I've seen requires CloneZilla to run off a live CD, or a separate server... Maybe I can install CloneZilla on the NAS and instruct it to pull the images nightly with some kind of shell script? I don't know, I'm really at a loss here.

ajax1515

Posted 2016-03-31T16:10:45.547

Reputation: 3

I'm not sure I'm understanding the question correctly. Perhaps the partimage tool is what you are looking for. It makes backup images of Linux partitions. Similar in function to Ghost. Although I'm surprised to see its main site saying ext4 partitions are not supported yet – infixed – 2016-03-31T17:12:52.860

Forums discussing partimage and ext4 are discussing CloneZilla as an alternative. I've used partimage, but not CloneZilla – infixed – 2016-03-31T17:19:11.733

Ok, some of this software looks like it might work for my purposes, however I was hoping I'd be able to do this using just the features provided by NetGear's ReadyNAS – ajax1515 – 2016-03-31T18:39:28.663

Well, isn't storing the generated images on the NAS using it? You were using rsync before, why not clonezilla now? – infixed – 2016-03-31T19:43:26.620

Ok, I see what you're saying, after doing a bit more reading I think that will work for my purposes. If you want to post an answer rather than a comment I'll go ahead and accept it. – ajax1515 – 2016-03-31T20:21:04.327

Answers

0

A partition imaging utility like partimage or CloneZilla can be used to copy images of the linux partitions you wish to backup out on your NAS.

Be aware that partimage claims it does not support ext4 filesytems

infixed

Posted 2016-03-31T16:10:45.547

Reputation: 759

So after trying what you suggested I realize it's not as simple as it sounds... CloneZilla may indeed work however it seems that there are still some missing pieces to the overall puzzle I need help with. – ajax1515 – 2016-04-05T21:56:46.653

Too bad I don't know how to start a chat here without the system nagging about chatting in comments. What aspects are giving you problems. I sort of pictured you having /home mounted on it's own parttion. To back up, you'd unmount it, back up the partition on the NAS, then remount it. If you are trying to back it up mounted live, then partition imaging is probably not what you want to do – infixed – 2016-04-05T22:03:37.360

You're not interested in doing something like tar cjf /some/place/on/NAS/Hostname_backup_040516.tar.bz2 /home, are you? It'd be sort of risky if /home was active during the backup. @ajax1515 – infixed – 2016-04-05T22:16:04.690

Unmounting the partition is not necessarily a problem, as long as the process can be automated and done relatively quickly... The function these servers perform needs to be continuously active 24/7 however load is very low overnight so we can afford a small amount of down time.

Additionally it's not so much the data that I care about backing up, but the server settings and functionality, each of my nine servers is an essential piece of the overall system so if one dies, I need to be able to bring it back on the "blank" backup server in minutes. This is the backup solution I'm struggling with. – ajax1515 – 2016-04-06T14:38:24.540

So the server setup is stored in /etc and not very dynamic? Or will blanking a server require rebuilding some disk storage area to 'new' state. On thing is if you have a known good partition image, you can clone that over and over again. Restore from your template image, then make any customized changes afterwards, host names, etc – infixed – 2016-04-06T15:48:12.907

I know my use case is strange. The server set up and service configs are indeed dynamic... The servers all update and change their configurations as a unit, so if one goes down, it needs to be brought back (on the blank) already in sync with the other servers. Making the "customized changes" that you're refering to is exactly what I can't afford to do, that set-up process would take at least 30 minutes, which is far too long for even one of these servers to be out of commission. – ajax1515 – 2016-04-06T15:56:18.903

Well, one possibility that leaps to mind is a tar file that contains the customized files. Restore the template images, then untar the customized files over it. Slightly more complex is a script (that you'd have to create)the uses sed or perl to change files in place. – infixed – 2016-04-06T16:04:57.737

Let us continue this discussion in chat.

– ajax1515 – 2016-04-06T20:48:24.127