Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to create a file of a certain size by linux

2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces linux how to create a certain size file, has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand it.

Linux create file command: dd command

Copies the specified input file to the specified output file, and the format can be converted during the copy process. Syntax:

CODE: [Copy to clipboard] dd (option)

QUOTE:

If = enter the file (or device name).

Of = output file (or device name).

Ibs = bytes reads bytes bytes at a time, that is, the number of bytes read into the buffer.

Skip = blocks skips the ibs*blocks block at the beginning of the read-in buffer.

Obs = bytes writes bytes bytes at a time, that is, the number of bytes written to the buffer.

Bs = bytes also sets the number of bytes in the read / write buffer (equal to setting obs and obs).

Cbs = bytes converts bytes bytes at once.

Count = blocks copies only the input blocks blocks.

Conv = ASCII converts EBCDIC codes to ASCII codes.

Conv = ebcdic converts ASCII codes to EBCDIC codes.

Conv = ibm converts ASCII codes to alternate EBCDIC codes.

Conv = blick converts variable bits to fixed characters.

Conv = ublock converts the fixtures into motions.

Conv = ucase changes letters from lowercase to uppercase.

Conv = lcase changes letters from uppercase to lowercase.

Conv = notrunc does not truncate the output file.

Conv = swab swaps each pair of input bytes.

Conv = noerror does not stop processing when there is an error.

Conv = sync adjusts the size of each input record to the size of ibs (filled with ibs).

Fdformat command

Low-level formatted floppy disk.

Example:

Create an empty file of 100m

Dd if=/dev/zero of=hello.txt bs=100M count=1

Thank you for reading this article carefully. I hope the article "how to create a certain size document in linux" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 287

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report