1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
|
'\" te
.\" Copyright 2011 Nexenta Systems, Inc. All rights reserved.
.\" Copyright (c) 2009, Sun Microsystems, Inc. All Rights Reserved.
.\" 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.
.\" 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.
.\" 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]
.TH SMBADM 1M "Jan 8, 2009"
.SH NAME
smbadm \- configure and manage CIFS local groups and users, and manage domain
membership
.SH SYNOPSIS
.LP
.nf
\fBsmbadm add-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.] \fIgroup\fR
.fi
.LP
.nf
\fBsmbadm create\fR [-d \fIdescription\fR] \fIgroup\fR
.fi
.LP
.nf
\fBsmbadm delete\fR \fIgroup\fR
.fi
.LP
.nf
\fBsmbadm disable-user\fR \fIusername\fR
.fi
.LP
.nf
\fBsmbadm enable-user\fR \fIusername\fR
.fi
.LP
.nf
\fBsmbadm get\fR [[-p \fIproperty\fR] \&.\|.\|.] \fIgroup\fR
.fi
.LP
.nf
\fBsmbadm join\fR -u \fIusername\fR \fIdomain\fR
.fi
.LP
.nf
\fBsmbadm join\fR -w \fIworkgroup\fR
.fi
.LP
.nf
\fBsmbadm list\fR
.fi
.LP
.nf
\fBsmbadm lookup\fR \fIaccount-name\fR [\fIaccount-name\fR [\&.\|.\|.]]
.fi
.LP
.nf
\fBsmbadm remove-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.] \fIgroup\fR
.fi
.LP
.nf
\fBsmbadm rename\fR \fIgroup\fR \fInew-group\fR
.fi
.LP
.nf
\fBsmbadm set\fR -p \fIproperty\fR=\fIvalue\fR [[-p \fIproperty\fR=\fIvalue\fR] \&.\|.\|.] \fIgroup\fR
.fi
.LP
.nf
\fBsmbadm show\fR [-m] [-p] [\fIgroup\fR]
.fi
.SH DESCRIPTION
.sp
.LP
The \fBsmbadm\fR command is used to configure \fBCIFS\fR local groups and to
manage domain membership. You can also use the \fBsmbadm\fR command to enable
or disable SMB password generation for individual local users.
.sp
.LP
\fBCIFS\fR local groups can be used when Windows accounts must be members of
some local groups and when Windows style privileges must be granted. Solaris
local groups cannot provide these functions.
.sp
.LP
There are two types of local groups: user defined and built-in. Built-in local
groups are predefined local groups to support common administration tasks.
.sp
.LP
In order to provide proper identity mapping between \fBCIFS\fR local groups and
Solaris groups, a \fBCIFS\fR local group must have a corresponding Solaris
group. This requirement has two consequences: first, the group name must
conform to the intersection of the Windows and Solaris group name rules. Thus,
a \fBCIFS\fR local group name can be up to eight (8) characters long and
contain only lowercase characters and numbers. Second, a Solaris local group
has to be created before a \fBCIFS\fR local group can be created.
.sp
.LP
Built-in groups are standard Windows groups and are predefined by the
\fBCIFS\fR service. The built-in groups cannot be added, removed, or renamed,
and these groups do not follow the \fBCIFS\fR local group naming conventions.
.sp
.LP
When the \fBCIFS\fR server is started, the following built-in groups are
available:
.sp
.ne 2
.na
\fBAdministrators\fR
.ad
.sp .6
.RS 4n
Group members can administer the system.
.RE
.sp
.ne 2
.na
\fBBackup Operators\fR
.ad
.sp .6
.RS 4n
Group members can bypass file access controls to back up and restore files.
.RE
.sp
.ne 2
.na
\fBPower Users\fR
.ad
.sp .6
.RS 4n
Group members can share directories.
.RE
.sp
.LP
Solaris local users must have an SMB password for authentication and to gain
access to CIFS resources. This password is created by using the \fBpasswd\fR(1)
command when the \fBpam_smb_password\fR module is added to the system's PAM
configuration. See the \fBpam_smb_passwd\fR(5) man page.
.sp
.LP
The \fBdisable-user\fR and \fBenable-user\fR subcommands control SMB
password-generation for a specified local user. When disabled, the user is
prevented from connecting to the Solaris CIFS service. By default, SMB
password-generation is enabled for all local users.
.sp
.LP
To reenable a disabled user, you must use the \fBenable-user\fR subcommand and
then reset the user's password by using the \fBpasswd\fR command. The
\fBpam_smb_passwd.so.1\fR module must be added to the system's PAM
configuration to generate an SMB password.
.SS "Escaping Backslash Character"
.sp
.LP
For the \fBadd-member\fR, \fBremove-member\fR, and \fBjoin\fR (with \fB-u\fR)
subcommands, the backslash character (\fB\e\fR) is a valid separator between
member or user names and domain names. The backslash character is a shell
special character and must be quoted. For example, you might escape the
backslash character with another backslash character:
\fIdomain\fR\fB\e\e\fR\fIusername\fR. For more information about handling shell
special characters, see the man page for your shell.
.SH OPERANDS
.sp
.LP
The \fBsmbadm\fR command uses the following operands:
.sp
.ne 2
.na
\fB\fIdomain\fR\fR
.ad
.sp .6
.RS 4n
Specifies the name of an existing Windows domain to join.
.RE
.sp
.ne 2
.na
\fB\fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Specifies the name of the \fBCIFS\fR local group.
.RE
.sp
.ne 2
.na
\fB\fIusername\fR\fR
.ad
.sp .6
.RS 4n
Specifies the name of a Solaris local user.
.RE
.SH SUB-COMMANDS
.sp
.LP
The \fBsmbadm\fR command includes these subcommands:
.sp
.ne 2
.na
\fB\fBadd-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.]
\fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Adds the specified member to the specified \fBCIFS\fR local group. The \fB-m\fR
\fImember\fR option specifies the name of a \fBCIFS\fR local group member. The
member name must include an existing user name and an optional domain name.
.sp
Specify the member name in either of the following formats:
.sp
.in +2
.nf
[\fIdomain\fR\e]\fIusername\fR
[\fIdomain\fR/]\fIusername\fR
.fi
.in -2
.sp
For example, a valid member name might be \fBsales\eterry\fR or
\fBsales/terry\fR, where \fBsales\fR is the Windows domain name and \fBterry\fR
is the name of a user in the \fBsales\fR domain.
.RE
.sp
.ne 2
.na
\fB\fBcreate\fR [\fB-d\fR \fIdescription\fR] \fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Creates a \fBCIFS\fR local group with the specified name. You can optionally
specify a description of the group by using the \fB-d\fR option.
.RE
.sp
.ne 2
.na
\fB\fBdelete\fR \fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Deletes the specified \fBCIFS\fR local group. The built-in groups cannot be
deleted.
.RE
.sp
.ne 2
.na
\fB\fBdisable\fR \fIusername\fR\fR
.ad
.sp .6
.RS 4n
Disables SMB password-generation capabilities for the specified local user. A
disabled local user is prevented from accessing the system by means of the CIFS
service. When a local user account is disabled, you cannot use the \fBpasswd\fR
command to modify the user's SMB password until the user account is reenabled.
.RE
.sp
.ne 2
.na
\fB\fBenable\fR \fIusername\fR\fR
.ad
.sp .6
.RS 4n
Enables SMB password-generation capabilities for the specified local user.
After the password-generation capabilities are reenabled, you must use the
\fBpasswd\fR command to generate the SMB password for the local user before he
can connect to the CIFS service.
.sp
The \fBpasswd\fR command manages both the Solaris password and SMB password for
this user if the \fBpam_smb_passwd\fR module has been added to the system's PAM
configuration.
.RE
.sp
.ne 2
.na
\fB\fBget\fR [[\fB-p\fR \fIproperty\fR=\fIvalue\fR] \&.\|.\|.] \fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Retrieves property values for the specified group. If no property is specified,
all property values are shown.
.RE
.sp
.ne 2
.na
\fB\fBjoin\fR \fB-u\fR \fIusername\fR \fIdomain\fR\fR
.ad
.sp .6
.RS 4n
Joins a Windows domain or a workgroup.
.sp
The default mode for the \fBCIFS\fR service is workgroup mode, which uses the
default workgroup name, \fBWORKGROUP\fR.
.sp
An authenticated user account is required to join a domain, so you must specify
the Windows administrative user name with the \fB-u\fR option. If the password
is not specified on the command line, the user is prompted for it. This user
should be the domain administrator or any user who has administrative
privileges for the target domain.
.sp
\fIusername\fR and \fIdomain\fR can be entered in any of the following formats:
.sp
.in +2
.nf
\fIusername\fR[+\fIpassword\fR] \fIdomain\fR
\fIdomain\fR\e\fIusername\fR[+\fIpassword\fR]
\fIdomain\fR/\fIusername\fR[+\fIpassword\fR]
\fIusername\fR@\fIdomain\fR
.fi
.in -2
.sp
\&...where \fIdomain\fR can be the NetBIOS or DNS domain name.
.sp
If a machine trust account for the system already exists on a domain
controller, any authenticated user account can be used when joining the domain.
However, if the machine trust account does \fBnot\fR already exist, an account
that has administrative privileges on the domain is required to join the
domain.
.RE
.sp
.ne 2
.na
\fB\fBjoin\fR \fB-w\fR \fIworkgroup\fR\fR
.ad
.sp .6
.RS 4n
Joins a Windows domain or a workgroup.
.sp
The \fB-w\fR \fIworkgroup\fR option specifies the name of the workgroup to join
when using the \fBjoin\fR subcommand.
.RE
.sp
.ne 2
.na
\fB\fBlist\fR\fR
.ad
.sp .6
.RS 4n
Shows information about the current workgroup or domain. The information
typically includes the workgroup name or the primary domain name. When in
domain mode, the information includes domain controller names and trusted
domain names.
.sp
Each entry in the ouput is identified by one of the following tags:
.sp
.ne 2
.na
\fB\fB- [*] -\fR\fR
.ad
.RS 11n
Primary domain
.RE
.sp
.ne 2
.na
\fB\fB- [.] -\fR\fR
.ad
.RS 11n
Local domain
.RE
.sp
.ne 2
.na
\fB\fB- [-] -\fR\fR
.ad
.RS 11n
Other domains
.RE
.sp
.ne 2
.na
\fB\fB- [+] -\fR\fR
.ad
.RS 11n
Selected domain controller
.RE
.RE
.sp
.ne 2
.na
\fB\fBlookup\fR\fR \fIaccount-name\fR [\fIaccount-name\fR [\&.\|.\|.]]
.ad
.sp .6
.RS 4n
Lookup the SID for the given \fIaccount-name\fR, or lookup the
\fIaccount-name\fR for the given SID. This sub-command is
primarily for diagnostic use, to confirm whether the server
can lookup domain accounts and/or SIDs.
.RE
.sp
.ne 2
.na
\fB\fBremove-member\fR -m \fImember\fR [[-m \fImember\fR] \&.\|.\|.]
\fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Removes the specified member from the specified \fBCIFS\fR local group. The
\fB-m\fR \fImember\fR option specifies the name of a \fBCIFS\fR local group
member. The member name must include an existing user name and an optional
domain name.
.sp
Specify the member name in either of the following formats:
.sp
.in +2
.nf
[\fIdomain\fR\e]\fIusername\fR
[\fIdomain\fR/]\fIusername\fR
.fi
.in -2
.sp
For example, a valid member name might be \fBsales\eterry\fR or
\fBsales/terry\fR, where \fBsales\fR is the Windows domain name and \fBterry\fR
is the name of a user in the \fBsales\fR domain.
.RE
.sp
.ne 2
.na
\fB\fBrename\fR \fIgroup\fR \fInew-group\fR\fR
.ad
.sp .6
.RS 4n
Renames the specified \fBCIFS\fR local group. The group must already exist. The
built-in groups cannot be renamed.
.RE
.sp
.ne 2
.na
\fB\fBset\fR \fB-p\fR \fIproperty\fR=\fIvalue\fR [[\fB-p\fR
\fIproperty\fR=\fIvalue\fR] \&.\|.\|.] \fIgroup\fR\fR
.ad
.sp .6
.RS 4n
Sets configuration properties for a \fBCIFS\fR local group. The description and
the privileges for the built-in groups cannot be changed.
.sp
The \fB-p\fR \fIproperty\fR\fB=\fR\fIvalue\fR option specifies the list of
properties to be set on the specified group.
.sp
The group-related properties are as follows:
.sp
.ne 2
.na
\fB\fBbackup=[on|off]\fR\fR
.ad
.sp .6
.RS 4n
Specifies whether members of the \fBCIFS\fR local group can bypass file access
controls to back up file system objects.
.RE
.sp
.ne 2
.na
\fB\fBdescription=\fR\fIdescription-text\fR\fR
.ad
.sp .6
.RS 4n
Specifies a text description for the \fBCIFS\fR local group.
.RE
.sp
.ne 2
.na
\fB\fBrestore=[on|off]\fR\fR
.ad
.sp .6
.RS 4n
Specifies whether members of the \fBCIFS\fR local group can bypass file access
controls to restore file system objects.
.RE
.sp
.ne 2
.na
\fB\fBtake-ownership=[on|off]\fR\fR
.ad
.sp .6
.RS 4n
Specifies whether members of the \fBCIFS\fR local group can take ownership of
file system objects.
.RE
.RE
.sp
.ne 2
.na
\fB\fBshow\fR [\fB-m\fR] [\fB-p\fR] [\fIgroup\fR]\fR
.ad
.sp .6
.RS 4n
Shows information about the specified \fBCIFS\fR local group or groups. If no
group is specified, information is shown for all groups. If the \fB-m\fR option
is specified, the group members are also shown. If the \fB-p\fR option is
specified, the group privileges are also shown.
.RE
.SH EXIT STATUS
.sp
.LP
The following exit values are returned:
.sp
.ne 2
.na
\fB0\fR
.ad
.RS 13n
Successful completion.
.RE
.sp
.ne 2
.na
\fB>0\fR
.ad
.RS 13n
An error occurred.
.RE
.SH ATTRIBUTES
.sp
.LP
See the \fBattributes\fR(5) man page for descriptions of the following
attributes:
.sp
.sp
.TS
box;
c | c
l | l .
ATTRIBUTE TYPE ATTRIBUTE VALUE
_
Utility Name and Options Uncommitted
_
Utility Output Format Not-An-Interface
_
\fBsmbadm join\fR Obsolete
.TE
.SH SEE ALSO
.sp
.LP
\fBpasswd\fR(1), \fBgroupadd\fR(1M), \fBidmap\fR(1M), \fBidmapd\fR(1M),
\fBkclient\fR(1M), \fBshare\fR(1M), \fBsharectl\fR(1M), \fBsharemgr\fR(1M),
\fBsmbd\fR(1M), \fBsmbstat\fR(1M), \fBsmb\fR(4), \fBsmbautohome\fR(4),
\fBattributes\fR(5), \fBpam_smb_passwd\fR(5), \fBsmf\fR(5)
|