The DD command is used to copy files and convert and format the contents of the original file. The DD command is powerful, and for some of the lower-level problems, using the DD command can often get unexpected results. Use more or use DD to back up the bare device. However, it is not recommended that if you need to back up Oracle bare devices, you can use Rman backup, or use a third-party software backup, using DD, it is not easy to manage.
It is recommended that you use DD for Physical disk operations when needed, and that it is more convenient to use other commands such as the file system or the tar backup cpio. In addition, it is best to use a block device file when using DD for disk operations.
Grammar
DD (option)
Options
bs=< bytes;: Sets the IBS (input) and the granny (output) to the specified number of bytes;cbs=< bytes;: Convert, convert only the specified number of bytes at a time;conv=< keyword;: Specifies how the file is converted;count=< Number of chunks;: Read only the specified number of chunks;ibs=< bytes;: bytes per read;obs=< bytes;: Number of bytes per output;of=< file;: Output to file;seek=< chunks > : Skips the specified number of chunks at the beginning of the output;skip=< chunks;: Skips the specified number of chunks at the start of the read;--help: Assist;--version: Displays version information.
Instance
Du-sh sun.txt 1.1M sun.txt
The command creates a 1M size file sun.txt, where the parameters are interpreted:
- The if represents the input file. If you do not specify if, the input is read from the stdin by default.
- The of represents the output file. If you do not specify a, stdout is the default output by default.
- BS represents the block size for bytes.
- Count represents the number of blocks being copied.
- /dev/zero is a character device that continually returns a value of 0 bytes.
In addition, you can use this command to do Linux U-disk boot
Ext.: HTTP://MAN.LINUXDE.NET/DD
Reference: https://www.cnblogs.com/jikexianfeng/p/6103500.html
U-Disk start reference: http://www.upantool.com/jiaocheng/qidong/2012/1721.html
DD Copy command in Linux