summaryrefslogtreecommitdiff
path: root/man/1/zeros
blob: 68e1a9fbd9df9d540edcd8d4e905daff920b0aa6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
.TH ZEROS 1
.SH NAME
zeros \- write sequence of bytes
.SH SYNOPSIS
.B zeros
[
.IR -r
]
[
.IR -v value
]
[ [
.IR blocksize ...
[
.IR numblocks
] ]
.SH DESCRIPTION
.B Zeros
writes a sequence of bytes to standard output. The arguments
specify the nature of the bytes,
block size in bytes, and the number of blocks to output.
The
.I -r
option requests that each block be the same, but randomly
generated. The
.IR -v value
option sets the value of each byte (default 0).
Typically
.IR zeros
has a specialised use:
ensuring a file has the desired number of blocks in it to hold a file system image,
before reaming it.
.SH EXAMPLE
To create and initialize a file system containing 2048 1024 byte
blocks 
.IP
.EX
zeros 1024 2048 >kfs.file
mount -c {disk/kfs -r kfs.file} /n/local
.EE
.SH SOURCE
.B /appl/cmd/zeros.b
.SH SEE ALSO
.IR kfs (4)