OSDN Git Service

LDP: Update original to LDP v3.68
[linuxjm/LDP_man-pages.git] / original / man4 / null.4
1 .\" Copyright (c) 1993 Michael Haardt (michael@moria.de),
2 .\"     Fri Apr  2 11:32:09 MET DST 1993
3 .\"
4 .\" %%%LICENSE_START(GPLv2+_DOC_FULL)
5 .\" This is free documentation; you can redistribute it and/or
6 .\" modify it under the terms of the GNU General Public License as
7 .\" published by the Free Software Foundation; either version 2 of
8 .\" the License, or (at your option) any later version.
9 .\"
10 .\" The GNU General Public License's references to "object code"
11 .\" and "executables" are to be interpreted as the output of any
12 .\" document formatting or typesetting system, including
13 .\" intermediate and printed output.
14 .\"
15 .\" This manual is distributed in the hope that it will be useful,
16 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
17 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 .\" GNU General Public License for more details.
19 .\"
20 .\" You should have received a copy of the GNU General Public
21 .\" License along with this manual; if not, see
22 .\" <http://www.gnu.org/licenses/>.
23 .\" %%%LICENSE_END
24 .\"
25 .\" Modified Sat Jul 24 17:00:12 1993 by Rik Faith (faith@cs.unc.edu)
26 .TH NULL 4 2009-02-23 "Linux" "Linux Programmer's Manual"
27 .SH NAME
28 null, zero \- data sink
29 .SH DESCRIPTION
30 Data written to a
31 .BR null
32 or
33 .B zero
34 special file is discarded.
35 .PP
36 Reads from the
37 .B null
38 special file always return end of file (i.e.,
39 .BR read (2)
40 returns 0), whereas
41 reads from
42 .B zero
43 always return bytes containing zero (\e0 characters).
44 .LP
45 .B null
46 and
47 .B zero
48 are typically created by:
49 .RS
50 .sp
51 mknod \-m 666 /dev/null c 1 3
52 .br
53 mknod \-m 666 /dev/zero c 1 5
54 .br
55 chown root:root /dev/null /dev/zero
56 .RE
57 .SH FILES
58 .I /dev/null
59 .br
60 .I /dev/zero
61 .SH NOTES
62 If these devices are not writable and readable for all users, many
63 programs will act strangely.
64 .SH SEE ALSO
65 .BR chown (1),
66 .BR mknod (1),
67 .BR full (4)
68 .SH COLOPHON
69 This page is part of release 3.68 of the Linux
70 .I man-pages
71 project.
72 A description of the project,
73 information about reporting bugs,
74 and the latest version of this page,
75 can be found at
76 \%http://www.kernel.org/doc/man\-pages/.