save a few seconds by seeking instead of copying zeros
This commit is contained in:
parent
46ad2de5d9
commit
236943fe54
1 changed files with 2 additions and 2 deletions
|
@ -89,8 +89,8 @@ BASE=build.$$
|
|||
IMG=$BASE.img
|
||||
MNT=$BASE/
|
||||
|
||||
# create a 2GB blank filesystem
|
||||
dd if=/dev/zero of=$IMG bs=1024k count=2048
|
||||
# (quickly) create a 2GB blank filesystem
|
||||
dd bs=1 count=1 seek=$((2*1024*1024*1024)) if=/dev/zero of=$IMG
|
||||
# force it to be initialized as ext2
|
||||
mkfs.ext2 -F $IMG
|
||||
|
||||
|
|
Loading…
Reference in a new issue