使用dd命令在Linux下创建一个大文件

在当前目录下创建一个2G的文件test

dd if=/dev/zero of=./test=1G count=2

清空文件:

echo /dev/null > ./test