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="samba-tool.8">
6 <refentrytitle>samba-tool</refentrytitle>
7 <manvolnum>8</manvolnum>
8 <refmiscinfo class="source">Samba</refmiscinfo>
9 <refmiscinfo class="manual">System Administration tools</refmiscinfo>
10 <refmiscinfo class="version">4.1</refmiscinfo>
15 <refname>samba-tool</refname>
16 <refpurpose>Main Samba administration tool.
22 <command>samba-tool</command>
23 <arg choice="opt">-h</arg>
24 <arg choice="opt">-W myworkgroup</arg>
25 <arg choice="opt">-U user</arg>
26 <arg choice="opt">-d debuglevel</arg>
27 <arg choice="opt">--v</arg>
32 <title>DESCRIPTION</title>
33 <para>This tool is part of the <citerefentry><refentrytitle>samba</refentrytitle>
34 <manvolnum>7</manvolnum></citerefentry> suite.</para>
38 <title>OPTIONS</title>
43 <term>-h|--help</term>
45 Show this help message and exit
50 <term>--realm=REALM</term>
57 <term>--simple-bind-dn=DN</term>
59 DN to use for a simple bind
64 <term>--password=PASSWORD</term>
71 <term>-U USERNAME|--username=USERNAME</term>
78 <term>-W WORKGROUP|--workgroup=WORKGROUP</term>
85 <term>-N|--no-pass</term>
87 Don't ask for a password
92 <term>-k KERBEROS|--kerberos=KERBEROS</term>
99 <term>--ipaddress=IPADDRESS</term>
101 IP address of the server
105 &popt.common.samba.client;
111 <title>COMMANDS</title>
114 <title>dbcheck</title>
115 <para>Check the local AD database for errors.</para>
119 <title>delegation</title>
120 <para>Manage Delegations.</para>
124 <title>delegation add-service <replaceable>accountname</replaceable> <replaceable>principal</replaceable> [options]</title>
125 <para>Add a service principal as msDS-AllowedToDelegateTo.</para>
129 <title>delegation del-service <replaceable>accountname</replaceable> <replaceable>principal</replaceable> [options]</title>
130 <para>Delete a service principal as msDS-AllowedToDelegateTo.</para>
134 <title>delegation for-any-protocol <replaceable>accountname</replaceable> [(on|off)] [options]</title>
135 <para>Set/unset UF_TRUSTED_TO_AUTHENTICATE_FOR_DELEGATION (S4U2Proxy)
136 for an account.</para>
140 <title>delegation for-any-service <replaceable>accountname</replaceable> [(on|off)] [options]</title>
141 <para>Set/unset UF_TRUSTED_FOR_DELEGATION for an account.</para>
145 <title>delegation show <replaceable>accountname</replaceable> [options] </title>
146 <para>Show the delegation setting of an account.</para>
151 <para>Manage Domain Name Service (DNS).</para>
155 <title>dns add <replaceable>server</replaceable> <replaceable>zone</replaceable> <replaceable>name</replaceable> <replaceable>A|AAAA|PTR|CNAME|NS|MX|SRV|TXT</replaceable> <replaceable>data</replaceable></title>
156 <para>Add a DNS record.</para>
160 <title>dns delete <replaceable>server</replaceable> <replaceable>zone</replaceable> <replaceable>name</replaceable> <replaceable>A|AAAA|PTR|CNAME|NS|MX|SRV|TXT</replaceable> <replaceable>data</replaceable></title>
161 <para>Delete a DNS record.</para>
165 <title>dns query <replaceable>server</replaceable> <replaceable>zone</replaceable> <replaceable>name</replaceable> <replaceable>A|AAAA|PTR|CNAME|NS|MX|SRV|TXT|ALL</replaceable> [options] <replaceable>data</replaceable></title>
166 <para>Query a name.</para>
170 <title>dns roothints <replaceable>server</replaceable> [<replaceable>name</replaceable>] [options]</title>
171 <para>Query root hints.</para>
175 <title>dns serverinfo <replaceable>server</replaceable> [options]</title>
176 <para>Query server information.</para>
180 <title>dns update <replaceable>server</replaceable> <replaceable>zone</replaceable> <replaceable>name</replaceable> <replaceable>A|AAAA|PTR|CNAME|NS|MX|SRV|TXT</replaceable> <replaceable>olddata</replaceable> <replaceable>newdata</replaceable></title>
181 <para>Update a DNS record.</para>
185 <title>dns zonecreate <replaceable>server</replaceable> <replaceable>zone</replaceable> [options]</title>
186 <para>Create a zone.</para>
190 <title>dns zonedelete <replaceable>server</replaceable> <replaceable>zone</replaceable> [options]</title>
191 <para>Delete a zone.</para>
195 <title>dns zoneinfo <replaceable>server</replaceable> <replaceable>zone</replaceable> [options]</title>
196 <para>Query zone information.</para>
200 <title>dns zonelist <replaceable>server</replaceable> [options]</title>
201 <para>List zones.</para>
205 <title>domain</title>
206 <para>Manage Domain.</para>
210 <title>domain classicupgrade [options] <replaceable>classic_smb_conf</replaceable></title>
211 <para>Upgrade from Samba classic (NT4-like) database to Samba AD DC
216 <title>domain dcpromo <replaceable>dnsdomain</replaceable> [DC|RODC] [options]</title>
217 <para>Promote an existing domain member or NT4 PDC to an AD DC.</para>
221 <title>domain demote</title>
222 <para>Demote ourselves from the role of domain controller.</para>
226 <title>domain exportkeytab <replaceable>keytab</replaceable> [options]</title>
227 <para>Dumps Kerberos keys of the domain into a keytab.</para>
231 <title>domain info <replaceable>ip_address</replaceable> [options]</title>
232 <para>Print basic info about a domain and the specified DC.
237 <title>domain join <replaceable>dnsdomain</replaceable> [DC|RODC|MEMBER|SUBDOMAIN] [options]</title>
238 <para>Join a domain as either member or backup domain controller.</para>
242 <title>domain level <replaceable>show|raise</replaceable> <replaceable>options</replaceable> [options]</title>
243 <para>Show/raise domain and forest function levels.</para>
247 <title>domain passwordsettings <replaceable>show|set</replaceable> <replaceable>options</replaceable> [options]</title>
248 <para>Show/set password settings.</para>
252 <title>domain provision</title>
253 <para>Promote an existing domain member or NT4 PDC to an AD DC.</para>
258 <para>Manage Directory Replication Services (DRS).</para>
262 <title>drs bind</title>
263 <para>Show DRS capabilities of a server.</para>
267 <title>drs kcc</title>
268 <para>Trigger knowledge consistency center run.</para>
272 <title>drs options</title>
273 <para>Query or change <replaceable>options</replaceable> for NTDS Settings
274 object of a domain controller.</para>
278 <title>drs replicate <replaceable>destination_DC</replaceable> <replaceable>source_DC</replaceable> <replaceable>NC</replaceable> [options]</title>
279 <para>Replicate a naming context between two DCs.</para>
283 <title>drs showrepl</title>
284 <para>Show replication status.</para>
289 <para>Administer DS ACLs</para>
293 <title>dsacl set</title>
294 <para>Modify access list on a directory object.</para>
299 <para>Manage Flexible Single Master Operations (FSMO).</para>
303 <title>fsmo seize [options]</title>
304 <para>Seize the role.</para>
308 <title>fsmo show</title>
309 <para>Show the roles.</para>
313 <title>fsmo transfer [options]</title>
314 <para>Transfer the role.</para>
319 <para>Manage Group Policy Objects (GPO).</para>
323 <title>gpo create <replaceable>displayname</replaceable> [options]</title>
324 <para>Create an empty GPO.</para>
328 <title>gpo del <replaceable>gpo</replaceable> [options]</title>
329 <para>Delete GPO.</para>
333 <title>gpo dellink <replaceable>container_dn</replaceable> <replaceable>gpo</replaceable> [options]</title>
334 <para>Delete GPO link from a container.</para>
338 <title>gpo fetch <replaceable>gpo</replaceable> [options]</title>
339 <para>Download a GPO.</para>
343 <title>gpo getinheritance <replaceable>container_dn</replaceable> [options]</title>
344 <para>Get inheritance flag for a container.</para>
348 <title>gpo getlink <replaceable>container_dn</replaceable> [options]</title>
349 <para>List GPO Links for a container.</para>
353 <title>gpo list <replaceable>username</replaceable> [options]</title>
354 <para>List GPOs for an account.</para>
358 <title>gpo listall</title>
359 <para>List all GPOs.</para>
363 <title>gpo listcontainers <replaceable>gpo</replaceable> [options]</title>
364 <para>List all linked containers for a GPO.</para>
368 <title>gpo setinheritance <replaceable>container_dn</replaceable> <replaceable>block|inherit</replaceable> [options]</title>
369 <para>Set inheritance flag on a container.</para>
373 <title>gpo setlink <replaceable>container_dn</replaceable> <replaceable>gpo</replaceable> [options]</title>
374 <para>Add or Update a GPO link to a container.</para>
378 <title>gpo show <replaceable>gpo</replaceable> [options]</title>
379 <para>Show information for a GPO.</para>
384 <para>Manage groups.</para>
388 <title>group add <replaceable>groupname</replaceable> [options]</title>
389 <para>Create a new AD group.</para>
393 <title>group addmembers <replaceable>groupname</replaceable> <replaceable>members</replaceable> [options]</title>
394 <para>Add members to an AD group.</para>
398 <title>group delete <replaceable>groupname</replaceable> [options]</title>
399 <para>Delete an AD group.</para>
403 <title>group list</title>
404 <para>List all groups.</para>
408 <title>group listmembers <replaceable>groupname</replaceable> [options]</title>
409 <para>List all members of the specified AD group.</para>
413 <title>group removemembers <replaceable>groupname</replaceable> <replaceable>members</replaceable> [options]</title>
414 <para>Remove members from the specified AD group.</para>
418 <title>ldapcmp <replaceable>URL1</replaceable> <replaceable>URL2</replaceable> <replaceable>domain|configuration|schema|dnsdomain|dnsforest</replaceable> [options] </title>
419 <para>Compare two LDAP databases.</para>
424 <para>Manage NT ACLs.</para>
428 <title>ntacl get <replaceable>file</replaceable> [options]</title>
429 <para>Get ACLs on a file.</para>
433 <title>ntacl set <replaceable>acl</replaceable> <replaceable>file</replaceable> [options]</title>
434 <para>Set ACLs on a file.</para>
438 <title>ntacl sysvolcheck</title>
439 <para>Check sysvol ACLs match defaults (including correct ACLs on GPOs).</para>
443 <title>ntacl sysvolreset</title>
444 <para>Reset sysvol ACLs to defaults (including correct ACLs on GPOs).</para>
449 <para>Manage Read-Only Domain Controller (RODC).</para>
453 <title>rodc preload <replaceable>SID</replaceable>|<replaceable>DN</replaceable>|<replaceable>accountname</replaceable> [options]</title>
454 <para>Preload one account for an RODC.</para>
459 <para>Manage sites.</para>
463 <title>sites create <replaceable>site</replaceable> [options]</title>
464 <para>Create a new site.</para>
468 <title>sites remove <replaceable>site</replaceable> [options]</title>
469 <para>Delete an esxisting site.</para>
474 <para>Manage Service Principal Names (SPN).</para>
478 <title>spn add <replaceable>name</replaceable> <replaceable>user</replaceable> [options]</title>
479 <para>Create a new SPN.</para>
483 <title>spn delete <replaceable>name</replaceable> [<replaceable>user</replaceable>] [options]</title>
484 <para>Delete an existing SPN.</para>
488 <title>spn list <replaceable>user</replaceable> [options]</title>
489 <para>List SPNs of a given user.</para>
493 <title>testparm</title>
494 <para>Check the syntax of the configuration file.</para>
499 <para>Retrieve the time on a server.</para>
504 <para>Manage users.</para>
508 <title>user add <replaceable>username</replaceable> [<replaceable>password</replaceable>]</title>
509 <para>Create a new user. Please note that this subcommand is deprecated
510 and available for compatibility reasons only. Please use
511 <command>samba-tool user create</command> instead.</para>
515 <title>user create <replaceable>username</replaceable> [<replaceable>password</replaceable>]</title>
516 <para>Create a new user in the Active Directory Domain.</para>
520 <title>user delete <replaceable>username</replaceable> [options]</title>
521 <para>Delete an existing user account.</para>
525 <title>user disable <replaceable>username</replaceable></title>
526 <para>Disable an user account.</para>
530 <title>user enable <replaceable>username</replaceable></title>
531 <para>Enable an user account.</para>
535 <title>user list</title>
536 <para>List all users.</para>
540 <title>user password [options]</title>
541 <para>Change password for an user account (the one provided in
542 authentication).</para>
546 <title>user setexpiry <replaceable>username</replaceable> [options]</title>
547 <para>Set the expiration of an user account.</para>
551 <title>user setpassword <replaceable>username</replaceable> [options]</title>
552 <para>Sets or resets the password of an user account.</para>
556 <title>vampire [options] <replaceable>domain</replaceable></title>
557 <para>Join and synchronise a remote AD domain to the local server.
558 Please note that <command>samba-tool vampire</command> is deprecated,
559 please use <command>samba-tool domain join</command> instead.</para>
564 <para>Gives usage information.</para>
570 <title>VERSION</title>
572 <para>This man page is complete for version 4 of the Samba
577 <title>AUTHOR</title>
579 <para>The original Samba software and related utilities
580 were created by Andrew Tridgell. Samba is now developed
581 by the Samba Team as an Open Source project similar
582 to the way the Linux kernel is developed.</para>
584 <para>The samba-tool manpage was written by Karolin Seeger.</para>