6324 Add an `ndp' tool for manipulating the neighbors table
[illumos-gate.git] / usr / src / man / man1m / smbadm.1m
blobb1e6e2de98fac554ae6de10455067bd0b55f257e
1 '\" te
2 .\" Copyright 2011 Nexenta Systems, Inc.  All rights reserved.
3 .\" Copyright (c) 2009, Sun Microsystems, 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 SMBADM 1M "Jan 8, 2009"
8 .SH NAME
9 smbadm \- configure and manage CIFS local groups and users, and manage domain
10 membership
11 .SH SYNOPSIS
12 .LP
13 .nf
14 \fBsmbadm add-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.] \fIgroup\fR
15 .fi
17 .LP
18 .nf
19 \fBsmbadm create\fR [-d \fIdescription\fR] \fIgroup\fR
20 .fi
22 .LP
23 .nf
24 \fBsmbadm delete\fR \fIgroup\fR
25 .fi
27 .LP
28 .nf
29 \fBsmbadm disable-user\fR \fIusername\fR
30 .fi
32 .LP
33 .nf
34 \fBsmbadm enable-user\fR \fIusername\fR
35 .fi
37 .LP
38 .nf
39 \fBsmbadm get\fR [[-p \fIproperty\fR] \&.\|.\|.] \fIgroup\fR
40 .fi
42 .LP
43 .nf
44 \fBsmbadm join\fR -u \fIusername\fR \fIdomain\fR
45 .fi
47 .LP
48 .nf
49 \fBsmbadm join\fR -w \fIworkgroup\fR
50 .fi
52 .LP
53 .nf
54 \fBsmbadm list\fR
55 .fi
57 .LP
58 .nf
59 \fBsmbadm lookup\fR \fIaccount-name\fR [\fIaccount-name\fR [\&.\|.\|.]]
60 .fi
62 .LP
63 .nf
64 \fBsmbadm remove-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.] \fIgroup\fR
65 .fi
67 .LP
68 .nf
69 \fBsmbadm rename\fR \fIgroup\fR \fInew-group\fR
70 .fi
72 .LP
73 .nf
74 \fBsmbadm set\fR -p \fIproperty\fR=\fIvalue\fR [[-p \fIproperty\fR=\fIvalue\fR] \&.\|.\|.] \fIgroup\fR
75 .fi
77 .LP
78 .nf
79 \fBsmbadm show\fR [-m] [-p] [\fIgroup\fR]
80 .fi
82 .SH DESCRIPTION
83 .sp
84 .LP
85 The \fBsmbadm\fR command is used to configure \fBCIFS\fR local groups and to
86 manage domain membership. You can also use the \fBsmbadm\fR command to enable
87 or disable SMB password generation for individual local users.
88 .sp
89 .LP
90 \fBCIFS\fR local groups can be used when Windows accounts must be members of
91 some local groups and when Windows style privileges must be granted. Solaris
92 local groups cannot provide these functions.
93 .sp
94 .LP
95 There are two types of local groups: user defined and built-in. Built-in local
96 groups are predefined local groups to support common administration tasks.
97 .sp
98 .LP
99 In order to provide proper identity mapping between \fBCIFS\fR local groups and
100 Solaris groups, a \fBCIFS\fR local group must have a corresponding Solaris
101 group. This requirement has two consequences: first, the group name must
102 conform to the intersection of the Windows and Solaris group name rules. Thus,
103 a \fBCIFS\fR local group name can be up to eight (8) characters long and
104 contain only lowercase characters and numbers. Second, a Solaris local group
105 has to be created before a \fBCIFS\fR local group can be created.
108 Built-in groups are standard Windows groups and are predefined by the
109 \fBCIFS\fR service. The built-in groups cannot be added, removed, or renamed,
110 and these groups do not follow the \fBCIFS\fR local group naming conventions.
113 When the \fBCIFS\fR server is started, the following built-in groups are
114 available:
116 .ne 2
118 \fBAdministrators\fR
120 .sp .6
121 .RS 4n
122 Group members can administer the system.
126 .ne 2
128 \fBBackup Operators\fR
130 .sp .6
131 .RS 4n
132 Group members can bypass file access controls to back up and restore files.
136 .ne 2
138 \fBPower Users\fR
140 .sp .6
141 .RS 4n
142 Group members can share directories.
147 Solaris local users must have an SMB password for authentication and to gain
148 access to CIFS resources. This password is created by using the \fBpasswd\fR(1)
149 command when the \fBpam_smb_password\fR module is added to the system's PAM
150 configuration. See the \fBpam_smb_passwd\fR(5) man page.
153 The \fBdisable-user\fR and \fBenable-user\fR subcommands control SMB
154 password-generation for a specified local user. When disabled, the user is
155 prevented from connecting to the Solaris CIFS service. By default, SMB
156 password-generation is enabled for all local users.
159 To reenable a disabled user, you must use the \fBenable-user\fR subcommand and
160 then reset the user's password by using the \fBpasswd\fR command. The
161 \fBpam_smb_passwd.so.1\fR module must be added to the system's PAM
162 configuration to generate an SMB password.
163 .SS "Escaping Backslash Character"
166 For the \fBadd-member\fR, \fBremove-member\fR, and \fBjoin\fR (with \fB-u\fR)
167 subcommands, the backslash character (\fB\e\fR) is a valid separator between
168 member or user names and domain names. The backslash character is a shell
169 special character and must be quoted. For example, you might escape the
170 backslash character with another backslash character:
171 \fIdomain\fR\fB\e\e\fR\fIusername\fR. For more information about handling shell
172 special characters, see the man page for your shell.
173 .SH OPERANDS
176 The \fBsmbadm\fR command uses the following operands:
178 .ne 2
180 \fB\fIdomain\fR\fR
182 .sp .6
183 .RS 4n
184 Specifies the name of an existing Windows domain to join.
188 .ne 2
190 \fB\fIgroup\fR\fR
192 .sp .6
193 .RS 4n
194 Specifies the name of the \fBCIFS\fR local group.
198 .ne 2
200 \fB\fIusername\fR\fR
202 .sp .6
203 .RS 4n
204 Specifies the name of a Solaris local user.
207 .SH SUB-COMMANDS
210 The \fBsmbadm\fR command includes these subcommands:
212 .ne 2
214 \fB\fBadd-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.]
215 \fIgroup\fR\fR
217 .sp .6
218 .RS 4n
219 Adds the specified member to the specified \fBCIFS\fR local group. The \fB-m\fR
220 \fImember\fR option specifies the name of a \fBCIFS\fR local group member. The
221 member name must include an existing user name and an optional domain name.
223 Specify the member name in either of the following formats:
225 .in +2
227 [\fIdomain\fR\e]\fIusername\fR
228 [\fIdomain\fR/]\fIusername\fR
230 .in -2
233 For example, a valid member name might be \fBsales\eterry\fR or
234 \fBsales/terry\fR, where \fBsales\fR is the Windows domain name and \fBterry\fR
235 is the name of a user in the \fBsales\fR domain.
239 .ne 2
241 \fB\fBcreate\fR [\fB-d\fR \fIdescription\fR] \fIgroup\fR\fR
243 .sp .6
244 .RS 4n
245 Creates a \fBCIFS\fR local group with the specified name. You can optionally
246 specify a description of the group by using the \fB-d\fR option.
250 .ne 2
252 \fB\fBdelete\fR \fIgroup\fR\fR
254 .sp .6
255 .RS 4n
256 Deletes the specified \fBCIFS\fR local group. The built-in groups cannot be
257 deleted.
261 .ne 2
263 \fB\fBdisable\fR \fIusername\fR\fR
265 .sp .6
266 .RS 4n
267 Disables SMB password-generation capabilities for the specified local user. A
268 disabled local user is prevented from accessing the system by means of the CIFS
269 service. When a local user account is disabled, you cannot use the \fBpasswd\fR
270 command to modify the user's SMB password until the user account is reenabled.
274 .ne 2
276 \fB\fBenable\fR \fIusername\fR\fR
278 .sp .6
279 .RS 4n
280 Enables SMB password-generation capabilities for the specified local user.
281 After the password-generation capabilities are reenabled, you must use the
282 \fBpasswd\fR command to generate the SMB password for the local user before he
283 can connect to the CIFS service.
285 The \fBpasswd\fR command manages both the Solaris password and SMB password for
286 this user if the \fBpam_smb_passwd\fR module has been added to the system's PAM
287 configuration.
291 .ne 2
293 \fB\fBget\fR [[\fB-p\fR \fIproperty\fR=\fIvalue\fR] \&.\|.\|.] \fIgroup\fR\fR
295 .sp .6
296 .RS 4n
297 Retrieves property values for the specified group. If no property is specified,
298 all property values are shown.
302 .ne 2
304 \fB\fBjoin\fR \fB-u\fR \fIusername\fR \fIdomain\fR\fR
306 .sp .6
307 .RS 4n
308 Joins a Windows domain or a workgroup.
310 The default mode for the \fBCIFS\fR service is workgroup mode, which uses the
311 default workgroup name, \fBWORKGROUP\fR.
313 An authenticated user account is required to join a domain, so you must specify
314 the Windows administrative user name with the \fB-u\fR option. If the password
315 is not specified on the command line, the user is prompted for it. This user
316 should be the domain administrator or any user who has administrative
317 privileges for the target domain.
319 \fIusername\fR and \fIdomain\fR can be entered in any of the following formats:
321 .in +2
323 \fIusername\fR[+\fIpassword\fR] \fIdomain\fR
324 \fIdomain\fR\e\fIusername\fR[+\fIpassword\fR]
325 \fIdomain\fR/\fIusername\fR[+\fIpassword\fR]
326 \fIusername\fR@\fIdomain\fR
328 .in -2
331 \&...where \fIdomain\fR can be the NetBIOS or DNS domain name.
333 If a machine trust account for the system already exists on a domain
334 controller, any authenticated user account can be used when joining the domain.
335 However, if the machine trust account does \fBnot\fR already exist, an account
336 that has administrative privileges on the domain is required to join the
337 domain.
341 .ne 2
343 \fB\fBjoin\fR \fB-w\fR \fIworkgroup\fR\fR
345 .sp .6
346 .RS 4n
347 Joins a Windows domain or a workgroup.
349 The \fB-w\fR \fIworkgroup\fR option specifies the name of the workgroup to join
350 when using the \fBjoin\fR subcommand.
354 .ne 2
356 \fB\fBlist\fR\fR
358 .sp .6
359 .RS 4n
360 Shows information about the current workgroup or domain. The information
361 typically includes the workgroup name or the primary domain name. When in
362 domain mode, the information includes domain controller names and trusted
363 domain names.
365 Each entry in the ouput is identified by one of the following tags:
367 .ne 2
369 \fB\fB- [*] -\fR\fR
371 .RS 11n
372 Primary domain
376 .ne 2
378 \fB\fB- [.] -\fR\fR
380 .RS 11n
381 Local domain
385 .ne 2
387 \fB\fB- [-] -\fR\fR
389 .RS 11n
390 Other domains
394 .ne 2
396 \fB\fB- [+] -\fR\fR
398 .RS 11n
399 Selected domain controller
405 .ne 2
407 \fB\fBlookup\fR\fR \fIaccount-name\fR [\fIaccount-name\fR [\&.\|.\|.]]
410 .sp .6
411 .RS 4n
412 Lookup the SID for the given \fIaccount-name\fR, or lookup the
413 \fIaccount-name\fR for the given SID.  This sub-command is
414 primarily for diagnostic use, to confirm whether the server
415 can lookup domain accounts and/or SIDs.
419 .ne 2
421 \fB\fBremove-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.]
422 \fIgroup\fR\fR
424 .sp .6
425 .RS 4n
426 Removes the specified member from the specified \fBCIFS\fR local group. The
427 \fB-m\fR \fImember\fR option specifies the name of a \fBCIFS\fR local group
428 member. The member name must include an existing user name and an optional
429 domain name.
431 Specify the member name in either of the following formats:
433 .in +2
435 [\fIdomain\fR\e]\fIusername\fR
436 [\fIdomain\fR/]\fIusername\fR
438 .in -2
441 For example, a valid member name might be \fBsales\eterry\fR or
442 \fBsales/terry\fR, where \fBsales\fR is the Windows domain name and \fBterry\fR
443 is the name of a user in the \fBsales\fR domain.
447 .ne 2
449 \fB\fBrename\fR \fIgroup\fR \fInew-group\fR\fR
451 .sp .6
452 .RS 4n
453 Renames the specified \fBCIFS\fR local group. The group must already exist. The
454 built-in groups cannot be renamed.
458 .ne 2
460 \fB\fBset\fR \fB-p\fR \fIproperty\fR=\fIvalue\fR [[\fB-p\fR
461 \fIproperty\fR=\fIvalue\fR] \&.\|.\|.] \fIgroup\fR\fR
463 .sp .6
464 .RS 4n
465 Sets configuration properties for a \fBCIFS\fR local group. The description and
466 the privileges for the built-in groups cannot be changed.
468 The \fB-p\fR \fIproperty\fR\fB=\fR\fIvalue\fR option specifies the list of
469 properties to be set on the specified group.
471 The group-related properties are as follows:
473 .ne 2
475 \fB\fBbackup=[on|off]\fR\fR
477 .sp .6
478 .RS 4n
479 Specifies whether members of the \fBCIFS\fR local group can bypass file access
480 controls to back up file system objects.
484 .ne 2
486 \fB\fBdescription=\fR\fIdescription-text\fR\fR
488 .sp .6
489 .RS 4n
490 Specifies a text description for the \fBCIFS\fR local group.
494 .ne 2
496 \fB\fBrestore=[on|off]\fR\fR
498 .sp .6
499 .RS 4n
500 Specifies whether members of the \fBCIFS\fR local group can bypass file access
501 controls to restore file system objects.
505 .ne 2
507 \fB\fBtake-ownership=[on|off]\fR\fR
509 .sp .6
510 .RS 4n
511 Specifies whether members of the \fBCIFS\fR local group can take ownership of
512 file system objects.
518 .ne 2
520 \fB\fBshow\fR [\fB-m\fR] [\fB-p\fR] [\fIgroup\fR]\fR
522 .sp .6
523 .RS 4n
524 Shows information about the specified \fBCIFS\fR local group or groups. If no
525 group is specified, information is shown for all groups. If the \fB-m\fR option
526 is specified, the group members are also shown. If the \fB-p\fR option is
527 specified, the group privileges are also shown.
530 .SH EXIT STATUS
533 The following exit values are returned:
535 .ne 2
537 \fB0\fR
539 .RS 13n
540 Successful completion.
544 .ne 2
546 \fB>0\fR
548 .RS 13n
549 An error occurred.
552 .SH ATTRIBUTES
555 See the \fBattributes\fR(5) man page for descriptions of the following
556 attributes:
561 box;
562 c | c
563 l | l .
564 ATTRIBUTE TYPE  ATTRIBUTE VALUE
566 Utility Name and Options        Uncommitted
568 Utility Output Format   Not-An-Interface
570 \fBsmbadm join\fR       Obsolete
573 .SH SEE ALSO
576 \fBpasswd\fR(1), \fBgroupadd\fR(1M), \fBidmap\fR(1M), \fBidmapd\fR(1M),
577 \fBkclient\fR(1M), \fBshare\fR(1M), \fBsharectl\fR(1M), \fBsharemgr\fR(1M),
578 \fBsmbd\fR(1M), \fBsmbstat\fR(1M), \fBsmb\fR(4), \fBsmbautohome\fR(4),
579 \fBattributes\fR(5), \fBpam_smb_passwd\fR(5), \fBsmf\fR(5)