Several backup tools under Linux system competition

  

Users who have used the Linux system will know that the backup tools under the standard Linux system are very complete. They provide backup functions to allow us to better maintain the system. However, there are many backup tools under Linux. I don't know what you will choose, what is the function?

dump

dump can back up the directory or the entire file system to the specified device, or back up to a large file. Dump can perform tar-like functions. However, dump tends to consider file systems rather than individual files. The following is taken from the dump manual file: “dump Check the files on the ext2 file system and determine which files need to be backed up. These files will be copied to a given disk, tape, or other storage medium for security purposes, and dumps larger than the output media capacity will be divided into multiple volumes. On most media, capacity is determined by writing until an end-of-media tag is returned. ”

The program that works with dump is restore , which is used to restore files from the dump image.

The restore command performs the reverse function of the dump. You can restore a full backup of the file system first, and subsequent incremental backups can be overridden on a restored full backup. You can restore individual files or directory trees from full or partial backups.

Both dump and restore can run on the network, so you can back up or restore from a remote device. Dump and restore use tape drives and file devices that offer a wide range of options. However, both are limited to ext2 and ext3 file systems. If you are using JFS, Reiser, or other filesystems, you will need additional utilities such as tar.

cpio

If there is no dump instruction or if the dump version does not match, then cpio is your next good choice. Cpio has been around for a long time compared to other backup tools and has some important features that are lacking in other tools. But the first thing to note is that some function dumps are provided and cpio is not available, as follows:

◆You can perform incremental backup without using touch or find files;

◆ Atime and ctime do not change the data after backup;

◆ Perform data recovery in an interactive manner, such as the restore option -i.

cpio is a very useful backup tool. The biggest difference is that you can back up files from standard input (stdin). Some new versions of tar currently support file backups from standard input, but most of them do not yet have this feature.

Why is cpio less commonly used?

If cpio is so easy to use, why is tar more popular? The most likely reason is the same functionality, tar is easier to use than cpio (also More standard). For example, each version of tar supports tar cf device and tar xf device. However, cpio sometimes supports I and O; some versions do not. If you accumulate the options for each version of cpio, there are nearly 40 options, and even some parameters that use the same letter have different meanings in different versions of Unix. But as long as you use the standard options on most platforms, cpio is almost as easy to use as tar.

Copyright © Windows knowledge All Rights Reserved