dd相关命令

用指定大小的块拷贝一个文件,并在拷贝的同时进行指定的转换。

if= 输入文件或设备名称

  eg:if=u-boot-with-spl.bin

of=输出文件或设备名称

  eg:of=/dev/sdb

bs=bytes 同时设置读/写缓冲区的字节数(等于设置ibs和obs)

  eg:bs=1024

seek=blocks 跳过多少blocks后输出

  eg:seek=17

ibs=bytes 一次读出bytes字节,即读入缓冲区的字节数

obs=bytes 一次写入bytes字节,即写入缓冲区的字节数

cbs=byte 一次读转换的bytes字节

count=blocks 只拷贝输入的blocks块

eg:dd if=u-boot-wirh-spl.bin of=/dev/sdb bs=1024 seek=17

  将u-boot-wirh-spl.bin烧录到SD卡的17kb偏移处,大小为1024

eg:dd if=/dev/fdo of=/tmp/tmpfile

 

posted @ 2017-12-02 20:03  张大猛  阅读(298)  评论(0编辑  收藏  举报