6253 F_GETLK doesn't always return lock owner
[illumos-gate.git] / usr / src / man / man1m / soconfig.1m
blob6166bba6276729f9469668491a6068eca12375d0
1 '\" te
2 .\"  Copyright (c) 2008, Sun Microsystems, Inc.  All Rights Reserved
3 .\"  Copyright 2015 Nexenta Systems, Inc. All rights reserved.
4 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
5 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
6 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
7 .TH SOCONFIG 1M "May 21, 2015"
8 .SH NAME
9 soconfig \- configure transport providers for use by sockets
10 .SH SYNOPSIS
11 .LP
12 .nf
13 \fB/sbin/soconfig\fR \fB-d\fR \fIdir\fR
14 .fi
16 .LP
17 .nf
18 \fB/sbin/soconfig\fR \fB-f\fR \fIfile\fR
19 .fi
21 .LP
22 .nf
23 \fB/sbin/soconfig\fR \fIfamily\fR \fItype\fR \fIprotocol\fR [\fImodule\fR | \fIpath\fR]
24 .fi
26 .LP
27 .nf
28 \fB/sbin/soconfig\fR \fB-l\fR
29 .fi
31 .SH DESCRIPTION
32 .sp
33 .LP
34 The \fBsoconfig\fR utility configures the transport provider driver for use
35 with sockets. It specifies how the family, type, and protocol parameters in the
36 \fBsocket\fR(3SOCKET) call are mapped to the name of a transport provider such
37 as \fB/dev/tcp\fR. This utility can be used to add an additional mapping or
38 remove a previous mapping.
39 .sp
40 .LP
41 The \fBinit\fR(1M) utility uses \fBsoconfig\fR with the \fBsock2path.d\fR(4)
42 directory during the booting sequence.
43 .SH OPTIONS
44 .sp
45 .LP
46 The following options are supported:
47 .sp
48 .ne 2
49 .na
50 \fB\fB-d\fR \fIdir\fR\fR
51 .ad
52 .RS 11n
53 Set up the \fBsoconfig\fR configuration for each driver
54 according  to  the  information stored in the
55 files in \fIdir\fR.
56 .RE
58 .sp
59 .ne 2
60 .na
61 \fB\fB-f\fR \fIfile\fR\fR
62 .ad
63 .RS 11n
64 Set up the \fBsoconfig\fR configuration for each driver according to the
65 information stored in \fIfile\fR. A \fBsoconfig\fR file consists of lines of at
66 least the first three fields listed below, separated by spaces:
67 .sp
68 \fIfamily  type  protocol  [module | path]\fR
69 .sp
70 These fields are described in the \fBOPERANDS\fR section below.
71 .sp
72 An example of \fIfile\fR can be found in the \fBEXAMPLES\fR section below.
73 .RE
75 .sp
76 .ne 2
77 .na
78 \fB\fB-l\fR
79 .ad
80 .RS 11n
81 Print the in-kernel socket configuration table.
82 .RE
84 .SH OPERANDS
85 .sp
86 .LP
87 The following operands are supported:
88 .sp
89 .ne 2
90 .na
91 \fB\fIfamily\fR\fR
92 .ad
93 .RS 17n
94 The protocol family as listed in the \fB/usr/include/sys/socket.h\fR file,
95 expressed as an integer.
96 .RE
98 .sp
99 .ne 2
101 \fB\fItype\fR\fR
103 .RS 17n
104 The socket type as listed in the \fB/usr/include/sys/socket.h\fR file,
105 expressed as an integer.
109 .ne 2
111 \fB\fIprotocol\fR\fR
113 .RS 17n
114 The protocol number as specified in the family-specific \fBinclude\fR file,
115 expressed as an integer. For example, for \fBAF_INET\fR this number is
116 specified in \fB/usr/include/netinet/in.h\fR. An unspecified protocol number is
117 denoted with the value zero.
121 .ne 2
123 \fB\fImodule\fR | \fIpath\fR\fR
125 .RS 17n
126 The module name or path name of a device that corresponds to the transport
127 provider, such as \fBtcp\fR or \fB/dev/tcp\fR. Modules must reside in
128 \fBkernel/socketmod\fR. A device name must begin with \fB/dev\fR. If this
129 parameter is specified, the configuration will be added for the specified
130 family, type, and protocol. If this parameter is not specified, the
131 configuration will be removed.
134 .SH EXAMPLES
136 \fBExample 1 \fRUsing \fBsoconfig\fR
139 The following example sets up a module for family \fBAF_INET\fR and type
140 \fBSOCK_STREAM\fR:
143 .in +2
145 example# \fBsoconfig 2 2 0 tcp\fR
147 .in -2
152 The following example sets up \fB/dev/tcp\fR for family \fBAF_INET\fR and type
153 \fBSOCK_STREAM\fR:
156 .in +2
158 example# \fBsoconfig 2 2 0 /dev/tcp\fR
160 .in -2
165 The following is a sample file used with the \fB-f\fR option. Comment lines
166 begin with a hash mark (\fB#\fR):
169 .in +2
171 #   Family  Type  Protocol   Module | Path
172       2       2       0          tcp
173       2       2       6          tcp
175       2       1       0          udp
176       2       1       17         udp
178       1       2       0          /dev/ticotsord
179       1       1       0          /dev/ticlts
181       2       4       0          icmp
183 .in -2
186 .SH FILES
188 .ne 2
190 \fB\fB/etc/sock2path.d\fR\fR
192 .RS 18n
193 Directory containing files with mappings from
194 sockets  to transport providers.
197 .SH SEE ALSO
200 \fBinit\fR(1M), \fBsock2path.d\fR(4), \fBattributes\fR(5)
203 \fINetwork Interface Guide\fR