OSDN Git Service

Import translated manuals from JM CVS Repository.
[linuxjm/jm.git] / manual / LDP_man-pages / release / man2 / getdomainname.2
1 .\" Hey Emacs! This file is -*- nroff -*- source.
2 .\"
3 .\" Copyright 1993 Rickard E. Faith (faith@cs.unc.edu)
4 .\"
5 .\" Permission is granted to make and distribute verbatim copies of this
6 .\" manual provided the copyright notice and this permission notice are
7 .\" preserved on all copies.
8 .\"
9 .\" Permission is granted to copy and distribute modified versions of this
10 .\" manual under the conditions for verbatim copying, provided that the
11 .\" entire resulting derived work is distributed under the terms of a
12 .\" permission notice identical to this one.
13 .\"
14 .\" Since the Linux kernel and libraries are constantly changing, this
15 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
16 .\" responsibility for errors or omissions, or for damages resulting from
17 .\" the use of the information contained herein.  The author(s) may not
18 .\" have taken the same level of care in the production of this manual,
19 .\" which is licensed free of charge, as they might when working
20 .\" professionally.
21 .\"
22 .\" Formatted or processed versions of this manual, if unaccompanied by
23 .\" the source, must acknowledge the copyright and authors of this work.
24 .\"
25 .\" Modified 1997-08-25 by Nicolas Lichtmaier <nick@debian.org>
26 .\" Modified 2004-06-17 by Michael Kerrisk <mtk.manpages@gmail.com>
27 .\" Modified 2008-11-27 by mtk
28 .\"
29 .\" Japanese Version Copyright (c) 1997 SUTO, Mitsuaki
30 .\"         all rights reserved.
31 .\" Translated 1997-06-27, SUTO, Mitsuaki <suto@av.crl.sony.co.jp>
32 .\" Updated 2000-10-03, Yuichi SATO <sato@complex.eng.hokudai.ac.jp>
33 .\" Updated & Modified 2004-12-29, Yuichi SATO <ysato444@yahoo.co.jp>
34 .\" Updated 2008-12-26, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v3.15
35 .\"
36 .TH GETDOMAINNAME 2 2009-09-27 "Linux" "Linux Programmer's Manual"
37 .SH Ì¾Á°
38 getdomainname, setdomainname \- ¥É¥á¥¤¥ó̾¤Î¼èÆÀ¡¦ÀßÄê¤ò¤¹¤ë
39 .SH ½ñ¼°
40 .B #include <unistd.h>
41 .sp
42 .BI "int getdomainname(char *" name ", size_t " len );
43 .br
44 .BI "int setdomainname(const char *" name ", size_t " len );
45 .sp
46 .in -4n
47 glibc ¸þ¤±¤Îµ¡Ç½¸¡ºº¥Þ¥¯¥í¤ÎÍ×·ï
48 .RB ( feature_test_macros (7)
49 »²¾È):
50 .in
51 .sp
52 .ad l
53 .BR getdomainname (),
54 .BR setdomainname ():
55 _BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE\ <\ 500)
56 .ad b
57 .SH ÀâÌÀ
58 ¤³¤ì¤é¤Î´Ø¿ô¤Ï¡¢¥Û¥¹¥È¥·¥¹¥Æ¥à¤Î¥É¥á¥¤¥ó̾¤ò¼èÆÀ¡¦Êѹ¹¤¹¤ë¤¿¤á¤Ë»È¤ï¤ì¤ë¡£
59
60 .BR setdomainname ()
61 ¤Ï¡¢¥É¥á¥¤¥ó̾¤ò¡¢Ê¸»úÇÛÎó
62 .I name
63 ¤Ç»ØÄꤵ¤ì¤¿ÃͤËÀßÄꤹ¤ë¡£
64 °ú¤­¿ô
65 .I len
66 ¤Ë¤Ï¡¢
67 .I name
68 ¤Î¥Ð¥¤¥È¿ô¤ò»ØÄꤹ¤ë
69 (¤½¤Î¤¿¤á¡¢
70 .I name
71 ¤Ç¤Ïʸ»úÎó½ªÃ¼¤Î NULL ¥Ð¥¤¥È¤ÏɬÍפʤ¤)¡£
72
73 .BR getdomainname ()
74 ¤Ï¡¢NULL ½ªÃ¼¤µ¤ì¤¿¥É¥á¥¤¥ó̾¤ò¡¢
75 .I len
76 ¥Ð¥¤¥È¤ÎŤµ¤Îʸ»úÇÛÎó
77 .I name
78 ¤Ë³ÊǼ¤·¤ÆÊÖ¤¹¡£
79 NULL ½ªÃ¼¤µ¤ì¤¿¥É¥á¥¤¥ó̾¤¬ \fIlen\fP ¥Ð¥¤¥È¤è¤êŤ¤¾ì¹ç¡¢
80 .BR getdomainname ()
81 ¤Ï¡¢(glibc ¤Ç¤Ï) »Ï¤á¤Î \fIlen\fP ¥Ð¥¤¥È¤òÊÖ¤·¡¢(libc ¤Ç¤Ï) ¥¨¥é¡¼¤È¤Ê¤ë¡£
82 .SH ÊÖ¤êÃÍ
83 À®¸ù¤·¤¿¾ì¹ç 0 ¤¬Ê֤롣¼ºÇÔ¤·¤¿¾ì¹ç \-1 ¤¬Ê֤ꡢ
84 .I errno
85 ¤¬¥¨¥é¡¼¤ÎÆâÍƤ˽¾¤Ã¤ÆÀßÄꤵ¤ì¤ë¡£
86 .SH ¥¨¥é¡¼
87 .BR setdomainname ()
88 ¤Ï°Ê²¼¤Î¥¨¥é¡¼¤Ç¼ºÇÔ¤¹¤ë²ÄǽÀ­¤¬¤¢¤ë¡£
89 .TP
90 .B EFAULT
91 .I name
92 ¤¬¥æ¡¼¥¶¥¢¥É¥ì¥¹¶õ´Ö¤Î³°¤ò»Ø¤·¤¿¡£
93 .TP
94 .B EINVAL
95 .I len
96 ¤¬Éé¤Ç¤¢¤ë¤«¡¢Ä¹¤¹¤®¤ë¡£
97 .TP
98 .B EPERM
99 .BR setdomainname ()
100 ¤Ë¤ª¤¤¤Æ¡¢¸Æ¤Ó½Ð¤·¤¿¿Í¤ËÆø¢¤¬¤Ê¤¤
101 (Linux ¤Ç¤Ï
102 .B CAP_SYS_ADMIN
103 ¥±¡¼¥Ñ¥Ó¥ê¥Æ¥£ (capability) ¤¬¤Ê¤¤)¡£
104 .PP
105 .BR getdomainname ()
106 ¤Ï°Ê²¼¤Î¥¨¥é¡¼¤Ç¼ºÇÔ¤¹¤ë²ÄǽÀ­¤¬¤¢¤ë¡£
107 .TP
108 .B EINVAL
109 libc ¤Ç¤Î
110 .BR getdomainname ()
111 ¤Ë¤ª¤¤¤Æ¡¢
112 .I name
113 ¤¬ NULL ¥Ý¥¤¥ó¥¿¤Ç¤¢¤ë¤«¡¢
114 .I len
115 ¥Ð¥¤¥È¤è¤êŤ¤¡£
116 .SH ½àµò
117 POSIX ¤Ç¤Ï¡¢¤³¤ì¤é´Ø¿ô¤ÏÄêµÁ¤µ¤ì¤Æ¤¤¤Ê¤¤¡£
118 .\" ¤·¤«¤·¡¢¤Û¤È¤ó¤É¤Î¥·¥¹¥Æ¥à¤Ë¤¢¤ë...
119 .SH Ãí°Õ
120 Linux 1.0 °Ê¹ß¤Ç¤Ï¡¢¥É¥á¥¤¥ó̾¤ÎŤµ¤Î¾å¸Â¤Ï
121 ½ªÃ¼¤Î NULL ¥Ð¥¤¥È¤ò´Þ¤á¤Æ 64 ¥Ð¥¤¥È¤Ç¤¢¤ë¡£
122 ¤â¤Ã¤È¸Å¤¤¥«¡¼¥Í¥ë¤Ç¤Ï 8 ¥Ð¥¤¥È¤Ç¤¢¤Ã¤¿¡£
123
124 (x86 ¤ò´Þ¤à) Linux ¤Î¤Û¤È¤ó¤É¤Î¥¢¡¼¥­¥Æ¥¯¥Á¥ã¤Ç¤Ï¡¢
125 .BR getdomainname ()
126 ¤È¤¤¤¦¥·¥¹¥Æ¥à¥³¡¼¥ë¤Ï¸ºß¤·¤Ê¤¤¡£
127 ¤½¤ÎÂå¤ï¤ê¡¢glibc ¤Ç
128 .BR getdomainname ()
129 ¤¬¥é¥¤¥Ö¥é¥ê´Ø¿ô¤È¤·¤Æ¼ÂÁõ¤µ¤ì¤Æ¤ª¤ê¡¢¤³¤Î´Ø¿ô¤Ï
130 .BR uname (2)
131 ¤Î¸Æ¤Ó½Ð¤·¤ÇÊÖ¤µ¤ì¤¿
132 .I domainname
133 ¥Õ¥£¡¼¥ë¥É¤Î¥³¥Ô¡¼¤òÊÖ¤¹¡£
134 .SH ´ØÏ¢¹àÌÜ
135 .BR gethostname (2),
136 .BR sethostname (2),
137 .BR uname (2)