📜 ⬆️ ⬇️

Clonezilla Server - backup 100 PCs at night is no longer a problem

If you are not familiar with the problem, when due to an incorrect update of Ubuntu or from the pranks of another virus in Windows, you need to raise the system from its knees, then it will be boring.

Backup is a system administrator's insurance. Usually back up data that can be permanently lost - 1C databases, files and folders, Oracle databases, DHCP configs, etc. What happens to the PC, on which the usual clerk works, if the HDD suddenly dies? The whirlwind begins - we put the OS, roll in software, uchetki, printers, etc.
But what about the top director, chief accountant and other important personalities who, firstly, need it the way it was, and secondly, a working and set-up computer in 30-60 minutes?

Use Clonezilla Server (CE)!

CE is a logical continuation of Clonezilla, its network brother.
For reference, Clonezilla is free open source software for cloning disks and individual partitions on a hard disk, as well as creating backup copies and disaster recovery system.
')
Clonezilla itself is a godsend. Download the LiveCD , boot up, and in a few clicks of ENTER, the backup of partitions or the entire HDD to another HDD, which can be an external USB drive, starts. Of course, a copy is not dd with bit-wise copying, it will be equal to the amount of used disk space and in compressed form.

Clonezilla is friends with file systems such as: FAT, NTFS, ext2, ext3, ext4, reiserfs, reiser4, XFS, JFS, JFS, VMFS, and HFS +.

Those. for one-time backup operations, Clonezilla is more than.
Important note: CE does not distinguish software RAID, breaking it into separate devices!

CE helps us out when
  1. There are about ten PCs of the same type, without OS. We put the OS and the necessary software on the first PC, make a "cast", deploy the network simultaneously on the remaining ones.
  2. Backup one or more PCs over the network, preferably at night.

I don’t see the point of installing CE, as it’s been written more than once .

How to wake up the PC at night? Wake On Lan! We check support Motherboard WOL, we read the instruction on inclusion. By the way, my p5b-deluxe could not wake up, and cheap P5KPL-CM without problems.

Putting CE, you make sure that the thing is inflexible. It sets its own DHCP, which the station loading is then oriented on, checks the match of the IP address of the CE server and the IP address of the cloned system to 3 (!) Digits. If there is a mismatch, it sets the IP address of the NFS server as it pleases.

Hence the following helpful changes.


On the already raised DHCP server on the network, configure:
  1. 066 parameter - CE server IP address
  2. 067 parameter - pxelinux.0

Next, remove the verification of the name of the DHCP server:
/opt/drbl/sbin/mknic-nbi -cn

Then we expand the IP check to at least the second digit:
  1. edit the file / tftpboot / node_root / sbin / init
  2. change IP_prefix = "$ (echo $ IP | cut -d". "-f1-3)" to IP_prefix = "$ (echo $ IP | cut -d". "-f1-2)"

We change the final directory for backing up from the local / home / partimag to the SMB ball of the backup server. To do this, add the parameters of the SMB balls in the / tftpboot / nodes / $ IP / etc / fstab file, then create a template:
/ opt / drbl / sbin / drbl-gen-ssi-files $ IP

Well, to top it off, I have briefly written a script to wake the computer by IP and the subsequent HDD clonerHDD backup.

More to come:
  1. Make a rotation of backups so that no more than two backups from one machine
  2. To send the status of the backup, its size and name of the machine in Nagios
  3. Add script, adding restore from backup by command

Source: https://habr.com/ru/post/128558/


All Articles