[진주]님이 남기신 글:
>/dev/null파일로 심볼릭 링크 시키다가 잘 안되서(-_-;)
>null파일을 날리구
>touch null에서 새로 만들었는데
>로긴 할때마다 이런 것이 뜨네여.
>
>bash: /dev/null: 허가 거부됨
>[: -eq: unary operator expected
>bash: /dev/null: 허가 거부됨
>[: integer expression expected before -eq
>
>원래 null crw-rw----이었는데
>touch로 만든 null의 퍼미션은 -rw-rw----이거덩여?
>이것을 crw-rw----로 바꿔줘야할 것 같은데..
>당최 c란 것이 뭔지 몰겠네여.
>
>좀 가르쳐 주세여..
========================================
# mknod -m 660 /dev/null c 1 3
으로 해보세요....
------------------------
# man null
NULL(4) Linux Programmer's Manual NULL(4)
NAME
null, zero - data sink
DESCRIPTION
Data written on a null or zero special file is discarded.
Reads from the null special file always return end of
file, whereas reads from zero always return 0 characters.
null and zero are typically created by:
mknod -m 666 /dev/null c 1 3
mknod -m 666 /dev/zero c 1 5
chown root:mem /dev/null /dev/zero
NOTES
If these devices are not writable and readable for all
users, many programs will act strange.
FILES
/dev/null
/dev/zero
SEE ALSO
mknod(1), chown(1)
-------------------
# man mknod
SYNOPSIS
mknod [OPTION]... NAME TYPE [MAJOR MINOR]
DESCRIPTION
Create the special file NAME of the given TYPE.
-m, --mode=MODE
set permission mode (as in chmod), not 0666 - umask
--help display this help and exit
--version
output version information and exit
MAJOR MINOR are forbidden for TYPE p, mandatory otherwise.
TYPE may be:
b create a block (buffered) special file
c, u create a character (unbuffered) special file
p create a FIFO
REPORTING BUGS
Report bugs to <bug-fileutils@gnu.org>.
SEE ALSO
The full documentation for mknod is maintained as a Tex
info manual. If the info and mknod programs are properly
installed at your site, the command
info mknod
should give you access to the complete manual.
|