s3/docs: Add documentation for 'net sam rights'.
[Samba/gbeck.git] / docs-xml / manpages-3 / net.8.xml
blob107a96ae96016a998af5612638eca2be9a8fdc94
1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//Samba-Team//DTD DocBook V4.2-Based Variant V1.0//EN" "http://www.samba.org/samba/DTD/samba-doc">
3 <refentry id="net.8">
5 <refmeta>
6         <refentrytitle>net</refentrytitle>
7         <manvolnum>8</manvolnum>
8         <refmiscinfo class="source">Samba</refmiscinfo>
9         <refmiscinfo class="manual">System Administration tools</refmiscinfo>
10         <refmiscinfo class="version">3.5</refmiscinfo>
11 </refmeta>
14 <refnamediv>
15         <refname>net</refname>
16         <refpurpose>Tool for administration of Samba and remote
17         CIFS servers.
18         </refpurpose>
19 </refnamediv>
21 <refsynopsisdiv>
22         <cmdsynopsis>
23                 <command>net</command>
24                 <arg choice="req">&lt;ads|rap|rpc&gt;</arg>
25                 <arg choice="opt">-h</arg>
26                 <arg choice="opt">-w workgroup</arg>
27                 <arg choice="opt">-W myworkgroup</arg>
28                 <arg choice="opt">-U user</arg>
29                 <arg choice="opt">-I ip-address</arg>
30                 <arg choice="opt">-p port</arg>
31                 <arg choice="opt">-n myname</arg>
32                 <arg choice="opt">-s conffile</arg>
33                 <arg choice="opt">-S server</arg>
34                 <arg choice="opt">-l</arg>
35                 <arg choice="opt">-P</arg>
36                 <arg choice="opt">-d debuglevel</arg>
37                 <arg choice="opt">-V</arg>
38                 <arg choice="opt">--request-timeout seconds</arg>
39         </cmdsynopsis>
40 </refsynopsisdiv>
42 <refsect1>
43         <title>DESCRIPTION</title>
45         <para>This tool is part of the <citerefentry><refentrytitle>samba</refentrytitle>
46         <manvolnum>7</manvolnum></citerefentry> suite.</para>
48         <para>The Samba net utility is meant to work just like the net utility 
49         available for windows and DOS. The first argument should be used 
50         to specify the protocol to use when executing a certain command. 
51         ADS is used for ActiveDirectory, RAP is using for old (Win9x/NT3) 
52         clients and RPC can be used for NT4 and Windows 2000. If this 
53         argument is omitted, net will try to determine it automatically. 
54         Not all commands are available on all protocols.
55         </para>
57 </refsect1>
59 <refsect1>
60         <title>OPTIONS</title>
62         <variablelist>
63                 &stdarg.help;
64                 
65                 <varlistentry>
66                 <term>-w target-workgroup</term>
67                 <listitem><para>
68                 Sets target workgroup or domain. You have to specify 
69                 either this option or the IP address or the name of a server.
70                 </para></listitem>
71                 </varlistentry>
73                 <varlistentry>
74                 <term>-W workgroup</term>
75                 <listitem><para>
76                 Sets client workgroup or domain
77                 </para></listitem>
78                 </varlistentry>
80                 <varlistentry>
81                 <term>-U user</term>
82                 <listitem><para>
83                 User name to use
84                 </para></listitem>
85                 </varlistentry>
87                 <varlistentry>
88                 <term>-I ip-address</term>
89                 <listitem><para>
90                 IP address of target server to use. You have to
91                 specify either this option or a target workgroup or
92                 a target server.
93                 </para></listitem>
94                 </varlistentry>
96                 <varlistentry>
97                 <term>-p port</term>
98                 <listitem><para>
99                 Port on the target server to connect to (usually 139 or 445). 
100                 Defaults to trying 445 first, then 139.
101                 </para></listitem>
102                 </varlistentry>
104                 &stdarg.netbios.name;
105                 &stdarg.configfile;
107                 <varlistentry>
108                 <term>-S server</term>
109                 <listitem><para>
110                 Name of target server. You should specify either 
111                 this option or a target workgroup or a target IP address.
112                 </para></listitem>
113                 </varlistentry>
115                 <varlistentry>
116                 <term>-l</term>
117                 <listitem><para>
118                 When listing data, give more information on each item.
119                 </para></listitem>
120                 </varlistentry>
122                 <varlistentry>
123                 <term>-P</term>
124                 <listitem><para>
125                 Make queries to the external server using the machine account of the local server.
126                 </para></listitem>
127                 </varlistentry>
129                 <varlistentry>
130                 <term>--request-timeout 30</term>
131                 <listitem><para>
132                 Let client requests timeout after 30 seconds the default is 10
133                 seconds.
134                 </para></listitem>
135                 </varlistentry>
137                 &stdarg.server.debug;
138         </variablelist>
139 </refsect1>
141 <refsect1>
142 <title>COMMANDS</title>
144 <refsect2>
145 <title>CHANGESECRETPW</title>
147 <para>This command allows the Samba machine account password to be set from an external application
148 to a machine account password that has already been stored in Active Directory. DO NOT USE this command
149 unless you know exactly what you are doing. The use of this command requires that the force flag (-f)
150 be used also. There will be NO command prompt. Whatever information is piped into stdin, either by
151 typing at the command line or otherwise, will be stored as the literal machine password. Do NOT use
152 this without care and attention as it will overwrite a legitimate machine password without warning.
153 YOU HAVE BEEN WARNED.
154 </para>
156 </refsect2>
158 <refsect2>
159         <title>TIME</title>
161         <para>The <command>NET TIME</command> command allows you to view the time on a remote server
162         or synchronise the time on the local server with the time on the remote server.</para>
164 <refsect3>
165 <title>TIME</title>
167 <para>Without any options, the <command>NET TIME</command> command 
168 displays the time on the remote server.
169 </para>
171 </refsect3>
173 <refsect3>
174 <title>TIME SYSTEM</title>
176 <para>Displays the time on the remote server in a format ready for <command>/bin/date</command>.</para>
178 </refsect3>
180 <refsect3>
181 <title>TIME SET</title>
182 <para>Tries to set the date and time of the local server to that on 
183 the remote server using <command>/bin/date</command>. </para>
185 </refsect3>
187 <refsect3>
188 <title>TIME ZONE</title>
190 <para>Displays the timezone in hours from GMT on the remote computer.</para>
192 </refsect3>
193 </refsect2>
195 <refsect2>
196 <title>[RPC|ADS] JOIN [TYPE] [-U username[%password]] [createupn=UPN] [createcomputer=OU] [options]</title>
198 <para>
199 Join a domain.  If the account already exists on the server, and 
200 [TYPE] is MEMBER, the machine will attempt to join automatically. 
201 (Assuming that the machine has been created in server manager)
202 Otherwise, a password will be prompted for, and a new account may
203 be created.</para>
205 <para>
206 [TYPE] may be PDC, BDC or MEMBER to specify the type of server
207 joining the domain.
208 </para>
210 <para>
211 [UPN] (ADS only) set the principalname attribute during the join.  The default
212 format is host/netbiosname@REALM.
213 </para>
215 <para>
216 [OU] (ADS only) Precreate the computer account in a specific OU.  The
217 OU string reads from top to bottom without RDNs, and is delimited by
218 a '/'.  Please note that '\' is used for escape by both the shell
219 and ldap, so it may need to be doubled or quadrupled to pass through, 
220 and it is not used as a delimiter.
221 </para>
222 </refsect2>
224 <refsect2>
225 <title>[RPC] OLDJOIN [options]</title>
227 <para>Join a domain. Use the OLDJOIN option to join the domain 
228 using the old style of domain joining - you need to create a trust 
229 account in server manager first.</para>
230 </refsect2>
232 <refsect2>
233 <title>[RPC|ADS] USER</title>
235 <refsect3>
236 <title>[RPC|ADS] USER</title>
238 <para>List all users</para>
240 </refsect3>
242 <refsect3>
243 <title>[RPC|ADS] USER DELETE <replaceable>target</replaceable></title>
245 <para>Delete specified user</para>
247 </refsect3>
249 <refsect3>
250 <title>[RPC|ADS] USER INFO <replaceable>target</replaceable></title>
252 <para>List the domain groups of the specified user.</para>
254 </refsect3>
256 <refsect3>
257 <title>[RPC|ADS] USER RENAME <replaceable>oldname</replaceable> <replaceable>newname</replaceable></title>
259 <para>Rename specified user.</para>
261 </refsect3>
263 <refsect3>
264 <title>[RPC|ADS] USER ADD <replaceable>name</replaceable> [password] [-F user flags] [-C comment]</title>
266 <para>Add specified user.</para>
267 </refsect3>
268 </refsect2>
270 <refsect2>
271 <title>[RPC|ADS] GROUP</title>
273 <refsect3>
274 <title>[RPC|ADS] GROUP [misc options] [targets]</title>
275 <para>List user groups.</para>
276 </refsect3>
278 <refsect3>
279 <title>[RPC|ADS] GROUP DELETE <replaceable>name</replaceable> [misc. options]</title>
281 <para>Delete specified group.</para>
283 </refsect3>
285 <refsect3>
286 <title>[RPC|ADS] GROUP ADD <replaceable>name</replaceable> [-C comment]</title>
288 <para>Create specified group.</para>
290 </refsect3>
291 </refsect2>
293 <refsect2>
294 <title>[RAP|RPC] SHARE</title>
296 <refsect3>
297 <title>[RAP|RPC] SHARE [misc. options] [targets]</title>
299 <para>Enumerates all exported resources (network shares) on target server.</para>
301 </refsect3>
303 <refsect3>
304 <title>[RAP|RPC] SHARE ADD <replaceable>name=serverpath</replaceable> [-C comment] [-M maxusers] [targets]</title>
306 <para>Adds a share from a server (makes the export active). Maxusers 
307 specifies the number of users that can be connected to the 
308 share simultaneously.</para>
310 </refsect3>
312 <refsect3>
313 <title>SHARE DELETE <replaceable>sharename</replaceable></title>
315 <para>Delete specified share.</para>
316 </refsect3>
317 </refsect2>
319 <refsect2>
320 <title>[RPC|RAP] FILE</title>
322 <refsect3>
323 <title>[RPC|RAP] FILE</title>
325 <para>List all open files on remote server.</para>
327 </refsect3>
329 <refsect3>
330 <title>[RPC|RAP] FILE CLOSE <replaceable>fileid</replaceable></title>
332 <para>Close file with specified <replaceable>fileid</replaceable> on 
333 remote server.</para>
335 </refsect3>
337 <refsect3>
338 <title>[RPC|RAP] FILE INFO <replaceable>fileid</replaceable></title>
340 <para>
341 Print information on specified <replaceable>fileid</replaceable>. 
342 Currently listed are: file-id, username, locks, path, permissions.
343 </para>
345 </refsect3>
347 <refsect3>
348 <title>[RAP|RPC] FILE USER <replaceable>user</replaceable></title>
350 <para>
351 List files opened by specified <replaceable>user</replaceable>.
352 Please note that <command>net rap file user</command> does not work
353 against Samba servers. 
354 </para>
356 </refsect3>
358 </refsect2>
360 <refsect2>
361 <title>SESSION</title>
363 <refsect3>
364 <title>RAP SESSION</title>
366 <para>Without any other options, SESSION enumerates all active SMB/CIFS 
367 sessions on the target server.</para>
369 </refsect3>
371 <refsect3>
372 <title>RAP SESSION DELETE|CLOSE <replaceable>CLIENT_NAME</replaceable></title>
374 <para>Close the specified sessions.</para>
376 </refsect3>
378 <refsect3>
379 <title>RAP SESSION INFO <replaceable>CLIENT_NAME</replaceable></title>
381 <para>Give a list with all the open files in specified session.</para>
383 </refsect3>
385 </refsect2>
387 <refsect2>
388 <title>RAP SERVER <replaceable>DOMAIN</replaceable></title>
390 <para>List all servers in specified domain or workgroup. Defaults
391 to local domain.</para>
393 </refsect2>
395 <refsect2>
396 <title>RAP DOMAIN</title>
398 <para>Lists all domains and workgroups visible on the 
399 current network.</para>
401 </refsect2>
403 <refsect2>
404 <title>RAP PRINTQ</title>
406 <refsect3>
407 <title>RAP PRINTQ INFO <replaceable>QUEUE_NAME</replaceable></title>
409 <para>Lists the specified print queue and print jobs on the server.
410 If the <replaceable>QUEUE_NAME</replaceable> is omitted, all 
411 queues are listed.</para>
413 </refsect3>
415 <refsect3>
416 <title>RAP PRINTQ DELETE <replaceable>JOBID</replaceable></title>
418 <para>Delete job with specified id.</para>
420 </refsect3>
422 </refsect2>
424 <refsect2>
425 <title>RAP VALIDATE <replaceable>user</replaceable> [<replaceable>password</replaceable>]</title>
427 <para>
428 Validate whether the specified user can log in to the 
429 remote server. If the password is not specified on the commandline, it 
430 will be prompted. 
431 </para>
433 &not.implemented;
435 </refsect2>
437 <refsect2>
438 <title>RAP GROUPMEMBER</title>
440 <refsect3>
441 <title>RAP GROUPMEMBER LIST <replaceable>GROUP</replaceable></title>
443 <para>List all members of the specified group.</para>
445 </refsect3>
447 <refsect3>
448 <title>RAP GROUPMEMBER DELETE <replaceable>GROUP</replaceable> <replaceable>USER</replaceable></title>
450 <para>Delete member from group.</para>
452 </refsect3>
454 <refsect3>
455 <title>RAP GROUPMEMBER ADD <replaceable>GROUP</replaceable> <replaceable>USER</replaceable></title>
457 <para>Add member to group.</para>
459 </refsect3>
461 </refsect2>
463 <refsect2>
464 <title>RAP ADMIN <replaceable>command</replaceable></title>
466 <para>Execute the specified <replaceable>command</replaceable> on 
467 the remote server. Only works with OS/2 servers.
468 </para>
470 &not.implemented;
472 </refsect2>
474 <refsect2>
475 <title>RAP SERVICE</title>
477 <refsect3>
478 <title>RAP SERVICE START <replaceable>NAME</replaceable> [arguments...]</title>
480 <para>Start the specified service on the remote server. Not implemented yet.</para>
482 &not.implemented;
484 </refsect3>
486 <refsect3>
487 <title>RAP SERVICE STOP</title>
489 <para>Stop the specified service on the remote server.</para>
491 &not.implemented;
493 </refsect3>
495 </refsect2>
497 <refsect2>
498 <title>RAP PASSWORD <replaceable>USER</replaceable> <replaceable>OLDPASS</replaceable> <replaceable>NEWPASS</replaceable></title>
500 <para>
501 Change password of <replaceable>USER</replaceable> from <replaceable>OLDPASS</replaceable> to <replaceable>NEWPASS</replaceable>.
502 </para>
504 </refsect2>
506 <refsect2>
507 <title>LOOKUP</title>
509 <refsect3>
510 <title>LOOKUP HOST <replaceable>HOSTNAME</replaceable> [<replaceable>TYPE</replaceable>]</title>
512 <para>
513 Lookup the IP address of the given host with the specified type (netbios suffix). 
514 The type defaults to 0x20 (workstation).
515 </para>
517 </refsect3>
519 <refsect3>
520 <title>LOOKUP LDAP [<replaceable>DOMAIN</replaceable>]</title>
522 <para>Give IP address of LDAP server of specified <replaceable>DOMAIN</replaceable>. Defaults to local domain.</para>
524 </refsect3>
526 <refsect3>
527 <title>LOOKUP KDC [<replaceable>REALM</replaceable>]</title>
529 <para>Give IP address of KDC for the specified <replaceable>REALM</replaceable>.
530 Defaults to local realm.</para>
532 </refsect3>
534 <refsect3>
535 <title>LOOKUP DC [<replaceable>DOMAIN</replaceable>]</title>
537 <para>Give IP's of Domain Controllers for specified <replaceable>
538 DOMAIN</replaceable>. Defaults to local domain.</para>
540 </refsect3>
542 <refsect3>
543 <title>LOOKUP MASTER <replaceable>DOMAIN</replaceable></title>
545 <para>Give IP of master browser for specified <replaceable>DOMAIN</replaceable>
546 or workgroup. Defaults to local domain.</para>
548 </refsect3>
550 </refsect2>
552 <refsect2>
553 <title>CACHE</title>
555 <para>Samba uses a general caching interface called 'gencache'. It 
556 can be controlled using 'NET CACHE'.</para>
558 <para>All the timeout parameters support the suffixes:
560 <simplelist>
561 <member>s - Seconds</member>
562 <member>m - Minutes</member>
563 <member>h - Hours</member>
564 <member>d - Days</member>
565 <member>w - Weeks</member>
566 </simplelist>
568 </para>
570 <refsect3>
571 <title>CACHE ADD <replaceable>key</replaceable> <replaceable>data</replaceable> <replaceable>time-out</replaceable></title>
573 <para>Add specified key+data to the cache with the given timeout.</para>
575 </refsect3>
577 <refsect3>
578 <title>CACHE DEL <replaceable>key</replaceable></title>
580 <para>Delete key from the cache.</para>
582 </refsect3>
584 <refsect3>
585 <title>CACHE SET <replaceable>key</replaceable> <replaceable>data</replaceable> <replaceable>time-out</replaceable></title>
587 <para>Update data of existing cache entry.</para>
589 </refsect3>
591 <refsect3>
592 <title>CACHE SEARCH <replaceable>PATTERN</replaceable></title>
594 <para>Search for the specified pattern in the cache data.</para>
596 </refsect3>
598 <refsect3>
599 <title>CACHE LIST</title>
601 <para>
602 List all current items in the cache.
603 </para>
605 </refsect3>
607 <refsect3>
608 <title>CACHE FLUSH</title>
610 <para>Remove all the current items from the cache.</para>
612 </refsect3>
614 </refsect2>
616 <refsect2>
617 <title>GETLOCALSID [DOMAIN]</title>
619 <para>Prints the SID of the specified domain, or if the parameter is
620 omitted, the SID of the local server.</para>
622 </refsect2>
624 <refsect2>
625 <title>SETLOCALSID S-1-5-21-x-y-z</title>
627 <para>Sets SID for the local server to the specified SID.</para>
629 </refsect2>
631 <refsect2>
632 <title>GETDOMAINSID</title>
634 <para>Prints the local machine SID and the SID of the current 
635 domain.</para>
637 </refsect2>
639 <refsect2>
640 <title>SETDOMAINSID</title>
642 <para>Sets the SID of the current domain.</para>
644 </refsect2>
646 <refsect2>
647 <title>GROUPMAP</title>
649 <para>Manage the mappings between Windows group SIDs and UNIX groups.
650 Common options include:</para>
652 <itemizedlist>
653 <listitem><para>unixgroup - Name of the UNIX group</para></listitem>
654 <listitem><para>ntgroup - Name of the Windows NT group (must be
655   resolvable to a SID</para></listitem>
656 <listitem><para>rid - Unsigned 32-bit integer</para></listitem>
657 <listitem><para>sid - Full SID in the form of "S-1-..."</para></listitem>
658 <listitem><para>type - Type of the group; either 'domain', 'local',
659   or 'builtin'</para></listitem>
660 <listitem><para>comment - Freeform text description of the group</para></listitem>
661 </itemizedlist>
663 <refsect3>
664 <title>GROUPMAP ADD</title>
666 <para>
667 Add a new group mapping entry:
668 <programlisting>
669 net groupmap add {rid=int|sid=string} unixgroup=string \
670         [type={domain|local}] [ntgroup=string] [comment=string]
671 </programlisting>
672 </para>
674 </refsect3>
676 <refsect3>
677 <title>GROUPMAP DELETE</title>
679 <para>Delete a group mapping entry. If more than one group name matches, the first entry found is deleted.</para>
681 <para>net groupmap delete {ntgroup=string|sid=SID}</para>
683 </refsect3>
685 <refsect3>
686 <title>GROUPMAP MODIFY</title>
688 <para>Update en existing group entry.</para>
690 <para>
691 <programlisting>
692 net groupmap modify {ntgroup=string|sid=SID} [unixgroup=string] \
693        [comment=string] [type={domain|local}]
694 </programlisting>
695 </para>
696 </refsect3>
698 <refsect3>
699 <title>GROUPMAP LIST</title>
701 <para>List existing group mapping entries.</para>
703 <para>net groupmap list [verbose] [ntgroup=string] [sid=SID]</para>
705 </refsect3>
706 </refsect2>
710 <refsect2>
711 <title>MAXRID</title>
713 <para>Prints out the highest RID currently in use on the local
714 server (by the active 'passdb backend').
715 </para>
717 </refsect2>
719 <refsect2>
720 <title>RPC INFO</title>
722 <para>Print information about the domain of the remote server,
723 such as domain name, domain sid and number of users and groups.
724 </para>
726 </refsect2>
728 <refsect2>
729 <title>[RPC|ADS] TESTJOIN</title>
731 <para>Check whether participation in a domain is still valid.</para>
733 </refsect2>
735 <refsect2>
736 <title>[RPC|ADS] CHANGETRUSTPW</title>
738 <para>Force change of domain trust password.</para>
740 </refsect2>
742 <refsect2>
743 <title>RPC TRUSTDOM</title>
745 <refsect3>
746 <title>RPC TRUSTDOM ADD <replaceable>DOMAIN</replaceable></title>
748 <para>Add a interdomain trust account for <replaceable>DOMAIN</replaceable>. 
749 This is in fact a Samba account named <replaceable>DOMAIN$</replaceable> 
750 with the account flag <constant>'I'</constant> (interdomain trust account). 
751 If the command is used against localhost it has the same effect as 
752 <command>smbpasswd -a -i DOMAIN</command>. Please note that both commands
753 expect a appropriate UNIX account. 
754 </para>
756 </refsect3>
758 <refsect3>
759 <title>RPC TRUSTDOM DEL <replaceable>DOMAIN</replaceable></title>
761 <para>Remove interdomain trust account for 
762 <replaceable>DOMAIN</replaceable>. If it is used against localhost 
763 it has the same effect as <command>smbpasswd -x DOMAIN$</command>. 
764 </para>
766 </refsect3>
768 <refsect3>
769 <title>RPC TRUSTDOM ESTABLISH <replaceable>DOMAIN</replaceable></title>
771 <para>
772 Establish a trust relationship to a trusting domain. 
773 Interdomain account must already be created on the remote PDC.
774 </para>
776 </refsect3>
778 <refsect3>
779 <title>RPC TRUSTDOM REVOKE <replaceable>DOMAIN</replaceable></title>
780 <para>Abandon relationship to trusted domain</para>
782 </refsect3>
784 <refsect3>
785 <title>RPC TRUSTDOM LIST</title>
787 <para>List all current interdomain trust relationships.</para>
789 </refsect3>
791 <refsect3>
792 <title>RPC RIGHTS</title>
794 <para>This subcommand is used to view and manage Samba's rights assignments (also 
795 referred to as privileges).  There are three options currently available: 
796 <parameter>list</parameter>, <parameter>grant</parameter>, and 
797 <parameter>revoke</parameter>.  More details on Samba's privilege model and its use
798 can be found in the Samba-HOWTO-Collection.</para>
800 </refsect3>
803 </refsect2>
805 <refsect2>
806 <title>RPC ABORTSHUTDOWN</title>
808 <para>Abort the shutdown of a remote server.</para>
810 </refsect2>
812 <refsect2>
813 <title>RPC SHUTDOWN [-t timeout] [-r] [-f] [-C message]</title>
815 <para>Shut down the remote server.</para>
817 <variablelist>
818 <varlistentry>
819 <term>-r</term>
820 <listitem><para>
821 Reboot after shutdown.
822 </para></listitem>
823 </varlistentry>
825 <varlistentry>
826 <term>-f</term>
827 <listitem><para>
828 Force shutting down all applications.
829 </para></listitem>
830 </varlistentry>
832 <varlistentry>
833 <term>-t timeout</term>
834 <listitem><para>
835 Timeout before system will be shut down. An interactive 
836 user of the system can use this time to cancel the shutdown.
837 </para></listitem>
838 </varlistentry>'>
840 <varlistentry>
841 <term>-C message</term>
842 <listitem><para>Display the specified message on the screen to 
843 announce the shutdown.</para></listitem>
844 </varlistentry>
845 </variablelist>
847 </refsect2>
849 <refsect2>
850 <title>RPC SAMDUMP</title>
852 <para>Print out sam database of remote server. You need
853 to run this against the PDC, from a Samba machine joined as a BDC. </para>
854 </refsect2>
856 <refsect2>
857 <title>RPC VAMPIRE</title>
859 <para>Export users, aliases and groups from remote server to 
860 local server.  You need to run this against the PDC, from a Samba machine joined as a BDC. 
861 </para>
862 </refsect2>
864 <refsect2>
865 <title>RPC VAMPIRE KEYTAB</title>
867 <para>Dump remote SAM database to local Kerberos keytab file.
868 </para>
869 </refsect2>
871 <refsect2>
872 <title>RPC VAMPIRE LDIF</title>
874 <para>Dump remote SAM database to local LDIF file or standard output.
875 </para>
876 </refsect2>
878 <refsect2>
879 <title>RPC GETSID</title>
881 <para>Fetch domain SID and store it in the local <filename>secrets.tdb</filename>. </para>
883 </refsect2>
885 <refsect2>
886 <title>ADS LEAVE</title>
888 <para>Make the remote host leave the domain it is part of. </para>
890 </refsect2>
892 <refsect2>
893 <title>ADS STATUS</title>
895 <para>Print out status of machine account of the local machine in ADS.
896 Prints out quite some debug info. Aimed at developers, regular 
897 users should use <command>NET ADS TESTJOIN</command>.</para>
899 </refsect2>
901 <refsect2>
902 <title>ADS PRINTER</title>
904 <refsect3>
905 <title>ADS PRINTER INFO [<replaceable>PRINTER</replaceable>] [<replaceable>SERVER</replaceable>]</title>
907 <para>
908 Lookup info for <replaceable>PRINTER</replaceable> on <replaceable>SERVER</replaceable>. The printer name defaults to "*", the 
909 server name defaults to the local host.</para>
911 </refsect3>
913 <refsect3>
914 <title>ADS PRINTER PUBLISH <replaceable>PRINTER</replaceable></title>
916 <para>Publish specified printer using ADS.</para>
918 </refsect3>
920 <refsect3>
921 <title>ADS PRINTER REMOVE <replaceable>PRINTER</replaceable></title>
923 <para>Remove specified printer from ADS directory.</para>
925 </refsect3>
927 </refsect2>
929 <refsect2>
930 <title>ADS SEARCH <replaceable>EXPRESSION</replaceable> <replaceable>ATTRIBUTES...</replaceable></title>
932 <para>Perform a raw LDAP search on a ADS server and dump the results. The 
933 expression is a standard LDAP search expression, and the 
934 attributes are a list of LDAP fields to show in the results.</para>
936 <para>Example: <userinput>net ads search '(objectCategory=group)' sAMAccountName</userinput>
937 </para>
939 </refsect2>
941 <refsect2>
942 <title>ADS DN <replaceable>DN</replaceable> <replaceable>(attributes)</replaceable></title>
944 <para>
945 Perform a raw LDAP search on a ADS server and dump the results. The 
946 DN standard LDAP DN, and the attributes are a list of LDAP fields 
947 to show in the result. 
948 </para>
950 <para>Example: <userinput>net ads dn 'CN=administrator,CN=Users,DC=my,DC=domain' SAMAccountName</userinput></para>
952 </refsect2>
954 <refsect2>
955 <title>ADS WORKGROUP</title>
957 <para>Print out workgroup name for specified kerberos realm.</para>
959 </refsect2>
961 <refsect2>
962 <title>SAM CREATEBUILTINGROUP &lt;NAME&gt;</title>
964 <para>
965 (Re)Create a BUILTIN group.
966 Only a wellknown set of BUILTIN groups can be created with this command.
967 This is the list of currently recognized group names: Administrators,
968 Users, Guests, Power Users, Account Operators, Server Operators, Print
969 Operators, Backup Operators, Replicator, RAS Servers, Pre-Windows 2000
970 compatible Access.
972 This command requires a running Winbindd with idmap allocation properly
973 configured. The group gid will be allocated out of the winbindd range.
974 </para>
976 </refsect2>
978 <refsect2>
979 <title>SAM CREATELOCALGROUP &lt;NAME&gt;</title>
981 <para>
982 Create a LOCAL group (also known as Alias).
984 This command requires a running Winbindd with idmap allocation properly
985 configured. The group gid will be allocated out of the winbindd range.
986 </para>
988 </refsect2>
990 <refsect2>
991 <title>SAM DELETELOCALGROUP &lt;NAME&gt;</title>
993 <para>
994 Delete an existing LOCAL group (also known as Alias).
996 </para>
998 </refsect2>
1000 <refsect2>
1001 <title>SAM MAPUNIXGROUP &lt;NAME&gt;</title>
1003 <para>
1004 Map an existing Unix group and make it a Domain Group, the domain group
1005 will have the same name.
1006 </para>
1008 </refsect2>
1010 <refsect2>
1011 <title>SAM UNMAPUNIXGROUP &lt;NAME&gt;</title>
1013 <para>
1014 Remove an existing group mapping entry.
1015 </para>
1017 </refsect2>
1019 <refsect2>
1020 <title>SAM ADDMEM &lt;GROUP&gt; &lt;MEMBER&gt;</title>
1022 <para>
1023 Add a member to a Local group. The group can be specified only by name,
1024 the member can be specified by name or SID.
1025 </para>
1027 </refsect2>
1029 <refsect2>
1030 <title>SAM DELMEM  &lt;GROUP&gt; &lt;MEMBER&gt;</title>
1032 <para>
1033 Remove a member from a Local group. The group and the member must be
1034 specified by name.
1035 </para>
1037 </refsect2>
1039 <refsect2>
1040 <title>SAM LISTMEM &lt;GROUP&gt;</title>
1042 <para>
1043 List Local group members. The group must be specified by name.
1044 </para>
1046 </refsect2>
1048 <refsect2>
1049 <title>SAM LIST &lt;users|groups|localgroups|builtin|workstations&gt; [verbose]</title>
1051 <para>
1052 List the specified set of accounts by name. If verbose is specified,
1053 the rid and description is also provided for each account.
1054 </para>
1056 </refsect2>
1058 <refsect2>
1059 <title>SAM RIGHTS LIST</title>
1061 <para>
1062 List all available privileges.
1063 </para>
1065 </refsect2>
1067 <refsect2>
1068 <title>SAM RIGHTS GRANT &lt;NAME&gt; &lt;PRIVILEGE&gt;</title>
1070 <para>
1071 Grant one or more privileges to a user.
1072 </para>
1074 </refsect2>
1076 <refsect2>
1077 <title>SAM RIGHTS REVOKE &lt;NAME&gt; &lt;PRIVILEGE&gt;</title>
1079 <para>
1080 Revoke one or more privileges from a user.
1081 </para>
1083 </refsect2>
1085 <refsect2>
1086 <title>SAM SHOW &lt;NAME&gt;</title>
1088 <para>
1089 Show the full DOMAIN\\NAME the SID and the type for the corresponding
1090 account.
1091 </para>
1093 </refsect2>
1095 <refsect2>
1096 <title>SAM SET HOMEDIR &lt;NAME&gt; &lt;DIRECTORY&gt;</title>
1098 <para>
1099 Set the home directory for a user account.
1100 </para>
1102 </refsect2>
1104 <refsect2>
1105 <title>SAM SET PROFILEPATH &lt;NAME&gt; &lt;PATH&gt;</title>
1107 <para>
1108 Set the profile path for a user account.
1109 </para>
1111 </refsect2>
1113 <refsect2>
1114 <title>SAM SET COMMENT &lt;NAME&gt; &lt;COMMENT&gt;</title>
1116 <para>
1117 Set the comment for a user or group account.
1118 </para>
1120 </refsect2>
1122 <refsect2>
1123 <title>SAM SET FULLNAME &lt;NAME&gt; &lt;FULL NAME&gt;</title>
1125 <para>
1126 Set the full name for a user account.
1127 </para>
1129 </refsect2>
1131 <refsect2>
1132 <title>SAM SET LOGONSCRIPT &lt;NAME&gt; &lt;SCRIPT&gt;</title>
1134 <para>
1135 Set the logon script for a user account.
1136 </para>
1138 </refsect2>
1140 <refsect2>
1141 <title>SAM SET HOMEDRIVE &lt;NAME&gt; &lt;DRIVE&gt;</title>
1143 <para>
1144 Set the home drive for a user account.
1145 </para>
1147 </refsect2>
1149 <refsect2>
1150 <title>SAM SET WORKSTATIONS &lt;NAME&gt; &lt;WORKSTATIONS&gt;</title>
1152 <para>
1153 Set the workstations a user account is allowed to log in from.
1154 </para>
1156 </refsect2>
1158 <refsect2>
1159 <title>SAM SET DISABLE &lt;NAME&gt;</title>
1161 <para>
1162 Set the "disabled" flag for a user account.
1163 </para>
1165 </refsect2>
1167 <refsect2>
1168 <title>SAM SET PWNOTREQ &lt;NAME&gt;</title>
1170 <para>
1171 Set the "password not required" flag for a user account.
1172 </para>
1174 </refsect2>
1176 <refsect2>
1177 <title>SAM SET AUTOLOCK &lt;NAME&gt;</title>
1179 <para>
1180 Set the "autolock" flag for a user account.
1181 </para>
1183 </refsect2>
1185 <refsect2>
1186 <title>SAM SET PWNOEXP &lt;NAME&gt;</title>
1188 <para>
1189 Set the "password do not expire" flag for a user account.
1190 </para>
1192 </refsect2>
1194 <refsect2>
1195 <title>SAM SET PWDMUSTCHANGENOW &lt;NAME&gt; [yes|no]</title>
1197 <para>
1198 Set or unset the "password must change" flag for a user account.
1199 </para>
1201 </refsect2>
1203 <refsect2>
1204 <title>SAM POLICY LIST</title>
1206 <para>
1207 List the available account policies.
1208 </para>
1210 </refsect2>
1212 <refsect2>
1213 <title>SAM POLICY SHOW &lt;account policy&gt;</title>
1215 <para>
1216 Show the account policy value.
1217 </para>
1219 </refsect2>
1221 <refsect2>
1222 <title>SAM POLICY SET &lt;account policy&gt; &lt;value&gt;</title>
1224 <para>
1225 Set a value for the account policy.
1226 Valid values can be: "forever", "never", "off", or a number.
1227 </para>
1229 </refsect2>
1231 <refsect2>
1232 <title>SAM PROVISION</title>
1234 <para>
1235 Only available if ldapsam:editposix is set and winbindd is running.
1236 Properly populates the ldap tree with the basic accounts (Administrator)
1237 and groups (Domain Users, Domain Admins, Domain Guests) on the ldap tree.
1238 </para>
1240 </refsect2>
1242 <refsect2>
1243 <title>IDMAP DUMP &lt;local tdb file name&gt;</title>
1245 <para>
1246 Dumps the mappings contained in the local tdb file specified.
1247 This command is useful to dump only the mappings produced by the idmap_tdb backend.
1248 </para>
1250 </refsect2>
1252 <refsect2>
1253 <title>IDMAP RESTORE [input file]</title>
1255 <para>
1256 Restore the mappings from the specified file or stdin.
1257 </para>
1259 </refsect2>
1261 <refsect2>
1262 <title>IDMAP SECRET &lt;DOMAIN&gt;|ALLOC &lt;secret&gt;</title>
1264 <para>
1265 Store a secret for the specified domain, used primarily for domains
1266 that use idmap_ldap as a backend. In this case the secret is used
1267 as the password for the user DN used to bind to the ldap server.
1268 </para>
1270 </refsect2>
1272 <refsect2>
1273 <title>USERSHARE</title>
1275 <para>Starting with version 3.0.23, a Samba server now supports the ability for
1276 non-root users to add user defined shares to be exported using the "net usershare"
1277 commands.
1278 </para>
1280 <para>
1281 To set this up, first set up your smb.conf by adding to the [global] section:
1283 usershare path = /usr/local/samba/lib/usershares
1285 Next create the directory /usr/local/samba/lib/usershares, change the owner to root and
1286 set the group owner to the UNIX group who should have the ability to create usershares,
1287 for example a group called "serverops".
1289 Set the permissions on /usr/local/samba/lib/usershares to 01770.
1291 (Owner and group all access, no access for others, plus the sticky bit,
1292 which means that a file in that directory can be renamed or deleted only
1293 by the owner of the file).
1295 Finally, tell smbd how many usershares you will allow by adding to the [global]
1296 section of smb.conf a line such as :
1298 usershare max shares = 100.
1300 To allow 100 usershare definitions. Now, members of the UNIX group "serverops"
1301 can create user defined shares on demand using the commands below.
1302 </para>
1304 <para>The usershare commands are:
1306 <simplelist>
1307 <member>net usershare add sharename path [comment] [acl] [guest_ok=[y|n]] - to add or change a user defined share.</member>
1308 <member>net usershare delete sharename - to delete a user defined share.</member>
1309 <member>net usershare info [-l|--long] [wildcard sharename] - to print info about a user defined share.</member>
1310 <member>net usershare list [-l|--long] [wildcard sharename] - to list user defined shares.</member>
1311 </simplelist>
1313 </para>
1315 <refsect3>
1316 <title>USERSHARE ADD <replaceable>sharename</replaceable> <replaceable>path</replaceable> <replaceable>[comment]</replaceable> <replaceable>[acl]</replaceable> <replaceable>[guest_ok=[y|n]]</replaceable></title>
1318 <para>
1319 Add or replace a new user defined share, with name "sharename".
1320 </para>
1322 <para>
1323 "path" specifies the absolute pathname on the system to be exported.
1324 Restrictions may be put on this, see the global smb.conf parameters:
1325 "usershare owner only", "usershare prefix allow list", and
1326 "usershare prefix deny list".
1327 </para>
1329 <para>
1330 The optional "comment" parameter is the comment that will appear
1331 on the share when browsed to by a client.
1332 </para>
1334 <para>The optional "acl" field
1335 specifies which users have read and write access to the entire share.
1336 Note that guest connections are not allowed unless the smb.conf parameter
1337 "usershare allow guests" has been set. The definition of a user
1338 defined share acl is: "user:permission", where user is a valid
1339 username on the system and permission can be "F", "R", or "D".
1340 "F" stands for "full permissions", ie. read and write permissions.
1341 "D" stands for "deny" for a user, ie. prevent this user from accessing
1342 this share.
1343 "R" stands for "read only", ie. only allow read access to this
1344 share (no creation of new files or directories or writing to files).
1345 </para>
1347 <para>
1348 The default if no "acl" is given is "Everyone:R", which means any 
1349 authenticated user has read-only access.
1350 </para>
1352 <para>
1353 The optional "guest_ok" has the same effect as the parameter of the
1354 same name in smb.conf, in that it allows guest access to this user
1355 defined share. This parameter is only allowed if the global parameter
1356 "usershare allow guests" has been set to true in the smb.conf.
1357 </para>
1359 There is no separate command to modify an existing user defined share,
1360 just use the "net usershare add [sharename]" command using the same
1361 sharename as the one you wish to modify and specify the new options
1362 you wish. The Samba smbd daemon notices user defined share modifications
1363 at connect time so will see the change immediately, there is no need
1364 to restart smbd on adding, deleting or changing a user defined share.
1365 </refsect3>
1367 <refsect3>
1368 <title>USERSHARE DELETE <replaceable>sharename</replaceable></title>
1370 <para>
1371 Deletes the user defined share by name. The Samba smbd daemon
1372 immediately notices this change, although it will not disconnect
1373 any users currently connected to the deleted share.
1374 </para>
1376 </refsect3>
1378 <refsect3>
1379 <title>USERSHARE INFO <replaceable>[-l|--long]</replaceable> <replaceable>[wildcard sharename]</replaceable></title>
1381 <para>
1382 Get info on user defined shares owned by the current user matching the given pattern, or all users.
1383 </para>
1385 <para>
1386 net usershare info on its own dumps out info on the user defined shares that were
1387 created by the current user, or restricts them to share names that match the given
1388 wildcard pattern ('*' matches one or more characters, '?' matches only one character).
1389 If the '-l' or '--long' option is also given, it prints out info on user defined
1390 shares created by other users.
1391 </para>
1393 <para>
1394 The information given about a share looks like:
1396 [foobar]
1397 path=/home/jeremy
1398 comment=testme
1399 usershare_acl=Everyone:F
1400 guest_ok=n
1402 And is a list of the current settings of the user defined share that can be
1403 modified by the "net usershare add" command.
1404 </para>
1406 </refsect3>
1408 <refsect3>
1409 <title>USERSHARE LIST <replaceable>[-l|--long]</replaceable> <replaceable>wildcard sharename</replaceable></title>
1411 <para>
1412 List all the user defined shares owned by the current user matching the given pattern, or all users.
1413 </para>
1415 <para>
1416 net usershare list on its own list out the names of the user defined shares that were
1417 created by the current user, or restricts the list to share names that match the given
1418 wildcard pattern ('*' matches one or more characters, '?' matches only one character).
1419 If the '-l' or '--long' option is also given, it includes the names of user defined
1420 shares created by other users.
1421 </para>
1423 </refsect3>
1425 </refsect2>
1427 <refsect2>
1428 <title>CONF</title>
1430 <para>Starting with version 3.2.0, a Samba server can be configured by data
1431 stored in registry. This configuration data can be edited with the new "net
1432 conf" commands.
1433 </para>
1435 <para>
1436 The deployment of this configuration data can be activated in two levels from the
1437 <emphasis>smb.conf</emphasis> file: Share definitions from registry are
1438 activated by setting <parameter>registry shares</parameter> to
1439 <quote>yes</quote> in the [global] section and global configuration options are
1440 activated by setting <smbconfoption name="include">registry</smbconfoption> in
1441 the [global] section for a mixed configuration or by setting
1442 <smbconfoption name="config backend">registry</smbconfoption> in the [global]
1443 section for a registry-only configuration.
1444 See the <citerefentry><refentrytitle>smb.conf</refentrytitle>
1445 <manvolnum>5</manvolnum></citerefentry> manpage for details.
1446 </para>
1448 <para>The conf commands are:
1449 <simplelist>
1450 <member>net conf list - Dump the complete configuration in smb.conf like
1451 format.</member>
1452 <member>net conf import - Import configuration from file in smb.conf
1453 format.</member>
1454 <member>net conf listshares - List the registry shares.</member>
1455 <member>net conf drop - Delete the complete configuration from
1456 registry.</member>
1457 <member>net conf showshare - Show the definition of a registry share.</member>
1458 <member>net conf addshare - Create a new registry share.</member>
1459 <member>net conf delshare - Delete a registry share.</member>
1460 <member>net conf setparm - Store a parameter.</member>
1461 <member>net conf getparm - Retrieve the value of a parameter.</member>
1462 <member>net conf delparm - Delete a parameter.</member>
1463 <member>net conf getincludes - Show the includes of a share definition.</member>
1464 <member>net conf setincludes - Set includes for a share.</member>
1465 <member>net conf delincludes - Delete includes from a share definition.</member>
1466 </simplelist>
1467 </para>
1469 <refsect3>
1470 <title>CONF LIST</title>
1472 <para>
1473 Print the configuration data stored in the registry in a smb.conf-like format to
1474 standard output.
1475 </para>
1476 </refsect3>
1478 <refsect3>
1479 <title>CONF IMPORT <replaceable>[--test|-T]</replaceable> <replaceable>filename</replaceable> <replaceable>[section]</replaceable></title>
1481 <para>
1482 This command imports configuration from a file in smb.conf format.
1483 If a section encountered in the input file is present in registry,
1484 its contents is replaced. Sections of registry configuration that have
1485 no counterpart in the input file are not affected. If you want to delete these,
1486 you will have to use the "net conf drop" or "net conf delshare" commands.
1487 Optionally, a section may be specified to restrict the effect of the
1488 import command to that specific section. A test mode is enabled by specifying
1489 the parameter "-T" on the commandline. In test mode, no changes are made to the
1490 registry, and the resulting configuration is printed to standard output instead.
1491 </para>
1492 </refsect3>
1494 <refsect3>
1495 <title>CONF LISTSHARES</title>
1497 <para>
1498 List the names of the shares defined in registry.
1499 </para>
1500 </refsect3>
1502 <refsect3>
1503 <title>CONF DROP</title>
1505 <para>
1506 Delete the complete configuration data from registry.
1507 </para>
1508 </refsect3>
1510 <refsect3>
1511 <title>CONF SHOWSHARE <replaceable>sharename</replaceable></title>
1513 <para>
1514 Show the definition of the share or section specified. It is valid to specify
1515 "global" as sharename to retrieve the global configuration options from
1516 registry.
1517 </para>
1518 </refsect3>
1520 <refsect3>
1521 <title>CONF ADDSHARE <replaceable>sharename</replaceable> <replaceable>path</replaceable> [<replaceable>writeable={y|N}</replaceable> [<replaceable>guest_ok={y|N}</replaceable> [<replaceable>comment</replaceable>]]] </title>
1523 <para>Create a new share definition in registry.
1524 The sharename and path have to be given. The share name may
1525 <emphasis>not</emphasis> be "global". Optionally, values for the very
1526 common options "writeable", "guest ok" and a "comment" may be specified.
1527 The same result may be obtained by a sequence of "net conf setparm"
1528 commands.
1529 </para>
1530 </refsect3>
1532 <refsect3>
1533 <title>CONF DELSHARE <replaceable>sharename</replaceable></title>
1535 <para>
1536 Delete a share definition from registry.
1537 </para>
1538 </refsect3>
1540 <refsect3>
1541 <title>CONF SETPARM <replaceable>section</replaceable> <replaceable>parameter</replaceable> <replaceable>value</replaceable></title>
1543 <para>
1544 Store a parameter in registry. The section may be global or a sharename.
1545 The section is created if it does not exist yet.
1546 </para>
1547 </refsect3>
1549 <refsect3>
1550 <title>CONF GETPARM <replaceable>section</replaceable> <replaceable>parameter</replaceable></title>
1552 <para>
1553 Show a parameter stored in registry.
1554 </para>
1555 </refsect3>
1557 <refsect3>
1558 <title>CONF DELPARM <replaceable>section</replaceable> <replaceable>parameter</replaceable></title>
1560 <para>
1561 Delete a parameter stored in registry.
1562 </para>
1563 </refsect3>
1565 <refsect3>
1566 <title>CONF GETINCLUDES <replaceable>section</replaceable></title>
1568 <para>
1569 Get the list of includes for the provided section (global or share).
1570 </para>
1572 <para>
1573 Note that due to the nature of the registry database and the nature of include directives,
1574 the includes need special treatment: Parameters are stored in registry by the parameter
1575 name as valuename, so there is only ever one instance of a parameter per share.
1576 Also, a specific order like in a text file is not guaranteed. For all real
1577 parameters, this is perfectly ok, but the include directive is rather a meta
1578 parameter, for which, in the smb.conf text file, the place where it is specified
1579 between the other parameters is very important. This can not be achieved by the
1580 simple registry smbconf data model, so there is one ordered list of includes
1581 per share, and this list is evaluated after all the parameters of the share.
1582 </para>
1584 <para>
1585 Further note that currently, only files can be included from registry
1586 configuration. In the future, there will be the ability to include configuration
1587 data from other registry keys.
1588 </para>
1589 </refsect3>
1591 <refsect3>
1592 <title>CONF SETINCLUDES <replaceable>section</replaceable> [<replaceable>filename</replaceable>]+</title>
1594 <para>
1595 Set the list of includes for the provided section (global or share) to the given
1596 list of one or more filenames. The filenames may contain the usual smb.conf
1597 macros like %I.
1598 </para>
1599 </refsect3>
1601 <refsect3>
1602 <title>CONF DELINCLUDES <replaceable>section</replaceable></title>
1604 <para>
1605 Delete the list of includes from the provided section (global or share).
1606 </para>
1607 </refsect3>
1609 </refsect2>
1611 <refsect2>
1612 <title>EVENTLOG</title>
1614 <para>Starting with version 3.4.0 net can read, dump, import and export native
1615 win32 eventlog files (usually *.evt). evt files are used by the native Windows eventviewer tools.
1616 </para>
1618 <para>
1619 The import and export of evt files can only succeed when <parameter>eventlog list</parameter> is used in
1620 <emphasis>smb.conf</emphasis> file.
1621 See the <citerefentry><refentrytitle>smb.conf</refentrytitle> <manvolnum>5</manvolnum></citerefentry> manpage for details.
1622 </para>
1624 <para>The eventlog commands are:
1625 <simplelist>
1626 <member>net eventlog dump - Dump a eventlog *.evt file on the screen.</member>
1627 <member>net eventlog import - Import a eventlog *.evt into the samba internal
1628 tdb based representation of eventlogs.</member>
1629 <member>net eventlog export - Export the samba internal tdb based representation
1630 of eventlogs into an eventlog *.evt file.</member>
1631 </simplelist>
1632 </para>
1634 <refsect3>
1635 <title>EVENTLOG DUMP <replaceable>filename</replaceable></title>
1637 <para>
1638 Prints a eventlog *.evt file to standard output.
1639 </para>
1640 </refsect3>
1642 <refsect3>
1643 <title>EVENTLOG IMPORT <replaceable>filename</replaceable> <replaceable>eventlog</replaceable></title>
1645 <para>
1646 Imports a eventlog *.evt file defined by <replaceable>filename</replaceable> into the
1647 samba internal tdb representation of eventlog defined by <replaceable>eventlog</replaceable>.
1648 <replaceable>eventlog</replaceable> needs to part of the <parameter>eventlog list</parameter>
1649 defined in smb.conf.
1650 See the <citerefentry><refentrytitle>smb.conf</refentrytitle> <manvolnum>5</manvolnum></citerefentry> manpage for details.
1651 </para>
1653 </refsect3>
1655 <refsect3>
1656 <title>EVENTLOG EXPORT <replaceable>filename</replaceable> <replaceable>eventlog</replaceable></title>
1658 <para>
1659 Exports the samba internal tdb representation of eventlog defined by <replaceable>eventlog</replaceable>
1660 to a eventlog *.evt file defined by <replaceable>filename</replaceable>.
1661 <replaceable>eventlog</replaceable> needs to part of the <parameter>eventlog list</parameter>
1662 defined in smb.conf.
1663 See the <citerefentry><refentrytitle>smb.conf</refentrytitle> <manvolnum>5</manvolnum></citerefentry> manpage for details.
1664 </para>
1666 </refsect3>
1668 </refsect2>
1670 <refsect2>
1671 <title>DOM</title>
1673 <para>Starting with version 3.2.0 Samba has support for remote join and unjoin APIs, both client and server-side. Windows supports remote join capabilities since Windows 2000.
1674 </para>
1675 <para>In order for Samba to be joined or unjoined remotely an account must be used that is either member of the Domain Admins group, a member of the local Administrators group or a user that is granted the SeMachineAccountPrivilege privilege.
1676 </para>
1678 <para>The client side support for remote join is implemented in the net dom commands which are:
1679 <simplelist>
1680 <member>net dom join - Join a remote computer into a domain.</member>
1681 <member>net dom unjoin - Unjoin a remote computer from a domain.</member>
1682 <member>net dom renamecomputer - Renames a remote computer joined to a domain.</member>
1683 </simplelist>
1684 </para>
1686 <refsect3>
1687 <title>DOM JOIN <replaceable>domain=DOMAIN</replaceable> <replaceable>ou=OU</replaceable> <replaceable>account=ACCOUNT</replaceable> <replaceable>password=PASSWORD</replaceable> <replaceable>reboot</replaceable></title>
1689 <para>
1690 Joins a computer into a domain. This command supports the following additional parameters:
1691 </para>
1693 <itemizedlist>
1695 <listitem><para><replaceable>DOMAIN</replaceable> can be a NetBIOS domain name (also known as short domain name) or a DNS domain name for Active Directory Domains. As in Windows, it is also possible to control which Domain Controller to use. This can be achieved by appending the DC name using the \ separator character. Example: MYDOM\MYDC. The <replaceable>DOMAIN</replaceable> parameter cannot be NULL.</para></listitem>
1697 <listitem><para><replaceable>OU</replaceable> can be set to a RFC 1779 LDAP DN, like <emphasis>ou=mymachines,cn=Users,dc=example,dc=com</emphasis> in order to create the machine account in a non-default LDAP containter. This optional parameter is only supported when joining Active Directory Domains.</para></listitem>
1699 <listitem><para><replaceable>ACCOUNT</replaceable> defines a domain account that will be used to join the machine to the domain. This domain account needs to have sufficient privileges to join machines.</para></listitem>
1701 <listitem><para><replaceable>PASSWORD</replaceable> defines the password for the domain account defined with <replaceable>ACCOUNT</replaceable>.</para></listitem>
1703 <listitem><para><replaceable>REBOOT</replaceable> is an optional parameter that can be set to reboot the remote machine after successful join to the domain.</para></listitem>
1705 </itemizedlist>
1707 <para>
1708 Note that you also need to use standard net paramters to connect and authenticate to the remote machine that you want to join. These additional parameters include: -S computer and -U user.
1709 </para>
1710 <para>
1711         Example:
1712         net dom join -S xp -U XP\\administrator%secret domain=MYDOM account=MYDOM\\administrator password=topsecret reboot.
1713 </para>
1714 <para>
1715 This example would connect to a computer named XP as the local administrator using password secret, and join the computer into a domain called MYDOM using the MYDOM domain administrator account and password topsecret. After successful join, the computer would reboot.
1716 </para>
1718 </refsect3>
1720 <refsect3>
1721 <title>DOM UNJOIN <replaceable>account=ACCOUNT</replaceable> <replaceable>password=PASSWORD</replaceable> <replaceable>reboot</replaceable></title>
1723 <para>
1724 Unjoins a computer from a domain. This command supports the following additional parameters:
1725 </para>
1727 <itemizedlist>
1729 <listitem><para><replaceable>ACCOUNT</replaceable> defines a domain account that will be used to unjoin the machine from the domain. This domain account needs to have sufficient privileges to unjoin machines.</para></listitem>
1731 <listitem><para><replaceable>PASSWORD</replaceable> defines the password for the domain account defined with <replaceable>ACCOUNT</replaceable>.</para></listitem>
1733 <listitem><para><replaceable>REBOOT</replaceable> is an optional parameter that can be set to reboot the remote machine after successful unjoin from the domain.</para></listitem>
1735 </itemizedlist>
1737 <para>
1738 Note that you also need to use standard net paramters to connect and authenticate to the remote machine that you want to unjoin. These additional parameters include: -S computer and -U user.
1739 </para>
1740 <para>
1741         Example:
1742         net dom unjoin -S xp -U XP\\administrator%secret account=MYDOM\\administrator password=topsecret reboot.
1743 </para>
1744 <para>
1745 This example would connect to a computer named XP as the local administrator using password secret, and unjoin the computer from the domain using the MYDOM domain administrator account and password topsecret. After successful unjoin, the computer would reboot.
1746 </para>
1748 </refsect3>
1750 <refsect3>
1751 <title>DOM RENAMECOMPUTER <replaceable>newname=NEWNAME</replaceable> <replaceable>account=ACCOUNT</replaceable> <replaceable>password=PASSWORD</replaceable> <replaceable>reboot</replaceable></title>
1753 <para>
1754 Renames a computer that is joined to a domain. This command supports the following additional parameters:
1755 </para>
1757 <itemizedlist>
1759 <listitem><para><replaceable>NEWNAME</replaceable> defines the new name of the machine in the domain.</para></listitem>
1761 <listitem><para><replaceable>ACCOUNT</replaceable> defines a domain account that will be used to rename the machine in the domain. This domain account needs to have sufficient privileges to rename machines.</para></listitem>
1763 <listitem><para><replaceable>PASSWORD</replaceable> defines the password for the domain account defined with <replaceable>ACCOUNT</replaceable>.</para></listitem>
1765 <listitem><para><replaceable>REBOOT</replaceable> is an optional parameter that can be set to reboot the remote machine after successful rename in the domain.</para></listitem>
1767 </itemizedlist>
1769 <para>
1770 Note that you also need to use standard net paramters to connect and authenticate to the remote machine that you want to rename in the domain. These additional parameters include: -S computer and -U user.
1771 </para>
1772 <para>
1773         Example:
1774         net dom renamecomputer -S xp -U XP\\administrator%secret newname=XPNEW account=MYDOM\\administrator password=topsecret reboot.
1775 </para>
1776 <para>
1777 This example would connect to a computer named XP as the local administrator using password secret, and rename the joined computer to XPNEW using the MYDOM domain administrator account and password topsecret. After successful rename, the computer would reboot.
1778 </para>
1780 </refsect3>
1782 </refsect2>
1784 <refsect2>
1785 <title>HELP [COMMAND]</title>
1787 <para>Gives usage information for the specified command.</para>
1789 </refsect2>
1791 </refsect1>
1793 <refsect1>
1794         <title>VERSION</title>
1796         <para>This man page is complete for version 3 of the Samba 
1797         suite.</para>
1798 </refsect1>
1800 <refsect1>
1801         <title>AUTHOR</title>
1802         
1803         <para>The original Samba software and related utilities 
1804         were created by Andrew Tridgell. Samba is now developed
1805         by the Samba Team as an Open Source project similar 
1806         to the way the Linux kernel is developed.</para>
1808         <para>The net manpage was written by Jelmer Vernooij.</para>
1809         
1810 </refsect1>
1812 </refentry>