Linux Backup Files command collection _unix Linux

Source: Internet
Author: User
Tags bz2 control characters time and date uncompress
Ar

Function Description: Create or modify the stored files, or extract files from the saved files.

Syntax:ar[-dmpqrtx][cfossuvv][a< member file >][b< member file >][i< member file >][file [member file]

Supplemental Note: AR allows you to assemble a number of files into a single standby file. In a saved file, all member files retain their original attributes and permissions.

Parameters
Instruction parameters
-D deletes the member files in the saved file.
-M to change the order of member files in the stored file.
-P Displays the contents of the member files in the saved file.
-Q will ask home attached at the end of the standby file.
-R inserts a file into the saved file.
-T displays the files contained in the saved file.
-X to remove the member file from the saved file.
Option parameters
a< member File > Inserts a file into the member file specified in the saved file.
b< member File > Inserts a file before the member file specified in the stored file.
C. Establish a storage document.
F to avoid an excessive file name that is incompatible with the AR instruction directives of other systems, you can use this parameter to truncate the name of the member file that is too long in the stored file.
i< member File > will ask the home before inserting the member file specified in the saved file.
O retains the date of the file in the saved file.
S. If the file contains an object pattern, you can use this parameter to create a symbol table for the file you are saving.
S does not produce a symbol table.
You insert only the date newer than the new file into the saved file.
The V program displays detailed information when it is executed.
V Displays version information.



--------------------------------------------------------------------------------

Bunzip2

Function Description:. bz2 file's decompression program.

Syntax: BUNZIP2 [-fklsvv][.bz2 Compressed file]

Supplemental Note: BUNZIP2 can extract compressed files in the. bz2 format. BUNZIP2 is actually a bzip2 symbolic connection, and the execution of BUNZIP2 is the same as the bzip2-d effect.

Parameters
When the-F or--force is uncompressed, the preset does not overwrite the existing file if the output file has the same name as an existing file. To overwrite, use this parameter.
The preset deletes the original compressed file after the-K or--keep is uncompressed. Use this parameter if you want to keep the compressed file.
-S or--small reduces the amount of memory used when the program executes.
Displays detailed information when you unzip a file-V or--verbose.
-L,--license,-v or--version display version information.



--------------------------------------------------------------------------------
Bzip2

Function Description:. bz2 file's compression program.

Syntax: bzip2 [-cdfhklstvvz][--repetitive-best][--repetitive-fast][-compression level] [files to compress]

Additional explanation: Bzip2 adopts the new compression algorithm, the compression effect is better than the traditional lz77/lz78 compression algorithm. Without any parameters, bzip2 compresses the file and then produces a. bz2 compressed file and deletes the original file.

Parameters
-C or--stdout sends the results of compression and decompression to standard output.
-D or--decompress to perform the decompression.
-F or--force bzip2 when compressing or decompressing, presets do not overwrite existing files if the output file has the same name as an existing file. To overwrite, use this parameter.
-h or--help display Help.
A-K or--keep bzip2 deletes the original file after compression or decompression. Use this parameter if you want to keep the original file.
-S or--small reduces the amount of memory used when the program executes.
-T or--test test. bz2 the integrity of the compressed file.
Displays detailed information when you compress or unzip a file-V or--verbose.
-Z or--compress to enforce compression.
-L,--License,
-V or--version display version information.
--repetitive-best If there are duplicate data in the file, this parameter can be used to improve the compression effect.
--repetitive-fast This parameter can be used to speed up execution if there are duplicate data in the file.
-Block size at compression level compression.



--------------------------------------------------------------------------------


--------------------------------------------------------------------------------

Bzip2recover

Feature description: Used to repair damaged. bz2 files.

Syntax: bzip2recover [. bz2 compressed file]

Supplementary Note: Bzip2 is a block of the way to compress files, each block as a separate unit. Therefore, when a block is damaged, bzip2recover can be used to try to isolate the blocks in the file to extract the normal chunks. Usually applies only in cases where the compressed file is large.



--------------------------------------------------------------------------------

Compress

Function Description: Compress or extract files.

Syntax: Compress [-cdfrvv][-b < compression efficiency >][files or directories ...]

Add: Compress is a long history of the compression program, the file after it compressed, its name will be more ". The extension of Z. When you want to decompress, you can execute the uncompress instruction. In fact, the uncompress is a symbolic connection to the compress, so either compression or decompression can be done individually through the compress instruction.

Parameters
-b< compression Efficiency > Compression efficiency is a value between 9-16, the preset is "16", the larger the value, the higher the compression efficiency.
-C Output The compressed file to the standard output device, not to change the original file.
-D unzip the file instead of compressing it.
-F forces a compressed file to be saved regardless of whether the file name or hard connection exists, whether the file is a symbolic connection, and the compression efficiency problem.
-R recursive processing of all files and subdirectories under the specified directory.
-V Displays the instruction execution process.
-V Displays the command version and program preset values.



--------------------------------------------------------------------------------

Cpio (copy in/out)

Feature Description: Back up files.

Syntax: cpio [ -0aabcklovv][-c < input/output size >][-f < backup file >][-h < backup format >][-o < backup file >][--block-size=< block size >][--force-local][--help][--quiet][--version] or Cpio [-bbcdfikmnrsstuvv][-c < input/output size &GT;][-E < template file >][-f < backup files >][-h < backup format >][-i < backup files >][-m < return information >][-r < owner ><:/.>< Group >][--block-size =< Chunk Size >][--force-local][--help][--no-absolute-filenames][--no-preserve-owner][--only-verify-crc][--quiet ][--sparse][--version][template style ...] or cpio [ -0adkilmpuvv][-r < owner ><:/.>< owning group >][--help][-- no-preserve-owner][--quiet][--sparse][--version][Purpose]

Supplemental Note: Cpio is used to build, restore the backup file of the tool program, it can join, unlock cpio or tra backup files.

Parameters
-0 or--null accepts new column control characters, usually in conjunction with the "-print0" parameter of the find instruction.
-A or--reset-access-time to reset the file's access time.
A-A or--append is attached to an existing backup file, and the backup file must be stored on disk and not placed in the tape drive.
-B or--swap the effect of this parameter is the same as specifying the "-SS" parameter.
-B Change the input/output chunk size to 5210 Bytes.
-C uses the old ASCII backup format.
-c< Chunk Size > or--io-size=< block size > set the input/output chunk size, in bytes.
-D or--make-directories if necessary cpio will set up its own directory.
The-e< template file > or--pattern-file=< template file > Specifies a template file that contains one or more template styles, allowing Cpio to unlock files that conform to the template criteria in a template style for each column.
-F or--nonmatching let Cpio unlock all files that do not conform to the template criteria.
The-f< backup file > or--file=< backup file > Specifies the name of the backup file to replace the standard input or output, and to access the backup file over the network using a storage device from another host.
-h< backup Format > Specify the file format you want to use when backing up.
-I or--extract perform copy-in mode to restore backup files.
The-l< backup file > Specifies the name of the backup file, which replaces the standard input, and can also be used to read the backup file over the network using a save device from another host.
-K This parameter ignores no processing and is responsible only for resolving compatibility issues between different versions of Cpio.
The-L or--link replaces the copied file in a hard connection and can be used in Copy-pass mode.
-L or--dereference does not establish a symbolic connection, directly copying the original file that the connection points to.
-M or preserve-modification-time does not change the time the file was changed.
-m< return information > or--message=< return information > settings to replace the saved media information.
When-N or--numeric-uid-gid lists the contents of the backup file using the "-tv" parameter, if the parameter "-n" is added, the file list is listed with the user ID and group identifier instead of the owner and group name.
-O or--create executes the copy-out mode and establishes the backup file.
The-o< backup file > Specifies the name of the backup file, which replaces the standard output, and can also be used to store backup files over the network using a storage device from another host.
-P or--pass-through executes the copy-pass mode, skipping the backup steps and copying the files directly to the destination directory.
-R or--rename use interactive mode when a file name needs to be altered.
-r< Owners ><:/.>< Affiliation Group > or
----owner< owners ><:/.>< groups > To restore the backup files in copy-in mode, or Copy-pass mode to copy a file, you can specify these backups, the owners of the copied files, and the groups they belong to.
-S or--swap-bytes exchange the contents of each pair of bytes.
-S or--swap-halfwords swaps the contents of each half byte.
-T or--list renders the input content.
-U or--unconditional replaces all files, regardless of the date time of the old or new or not, without asking and directly covered.
-V or--verbose details the execution of the instruction.
The-V or--dot executes the instruction by adding "." Before each file's execution program. Resolution
--block-size=< Block Size > set the input/output block size, if the setting value is 5, the chunk size is 2500, and if set to 10, the chunk size is 5120, and so on.
--force-local forces the backup file to reside on the local host.
--help online Help.
--no-absolute-filenames uses a relative path to establish the file name.
--no-preserve-owner does not keep the owner of the file, who unlocks the backup file, and who owns the files.
-ONLY-VERIFY-CRC When the backup file is in the CRC backup format, you can use this parameter to check that every file in the backup files is correct.
--quiet does not show how many blocks were copied.
--sparse If a file contains a large number of consecutive 0 bytes, save the file as a sparse file.
--version Displays version information.



--------------------------------------------------------------------------------

Dump

Function Description: Back up the file system.

Syntax: dump [-cnu][-0123456789][-b < chunk size >][-b < block number >][-d < density >][-f < device name >][-h < level >][-s < Tape length >][-t < date >][directory or file system] or dump [-WW]

Supplemental Note: Dump is a backup utility that backs up the directory or the entire file system to a specified device, or backs up a large file.
Parameters
-0123456789 levels of backup.
-b< Chunk Size > Specifies the size of the block in kilobytes.
Number of-b< blocks > Specifies the number of blocks for the backup volume.
-C modifies the density and capacity of the backup tape preset.
-d< density > Set the density of the tape. The unit is a BPI.
-f< Device name > Specify backup device.
-h< level > When the backup level equals or rains the specified level, the file marked "Nodump" by the user is not backed up.
-Ñ notifies users in all "operator" groups when a backup operation requires administrator intervention.
-s< tape length > Backup tape length, in feet.
-t< Date > Specifies the time and date when the backup starts.
-U after backup, record the backup file system, hierarchy, date and time in/etc/dumpdates.
-W is similar to-W, but only displays files that need to be backed up.
-W Displays the level, time, and date of the file that needs to be backed up and its last backup.



--------------------------------------------------------------------------------

Gunzip (GNU Unzip)

Function Description: Extract the file.

Syntax: gunzip [-acfhllnnqrtvv][-s < compressed word tail string >][file ...] or gunzip [-acfhllnnqrtvv][-s < compressed word tail string >][directory]

Supplemental Note: Gunzip is a widely used decompression program, which is used to undo gzip-compressed files, which are preset with the last extension ". gz". In fact, Gunzip is a hard connection to gzip, so either compression or decompression can be done individually through the gzip instruction.

Parameters
-A or--ASCII uses ASCII text mode.
-C or--stdout or--to-stdout to output the extracted files to the standard output device.
-F or-force forcibly unzip the compressed file regardless of whether the file name or hard connection exists and whether the file is a symbolic connection.
-H or--help online Help.
-L or--list lists information about compressed files.
-L or--license displays version and copyright information.
-N or--no-name uncompressed, if the compressed file contains a remote file name and time stamp, then ignore it.
-N or--name uncompressed, if the compressed file contains the original file name and time stamp, it is saved to the unpacked file.
-Q or--quiet does not display a warning message.
-R or--recursive recursively, all files and subdirectories under the specified directory are processed together.
-s< compressed Word tail string > or--suffix< compressed tail string > Change compressed Word tail string.
-T or--test test that the compressed file is correct.
The-V or--verbose displays the instruction execution process.
-V or--version display version information.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.