From 3f05862051126d92b217eacbc662da63f315d2f0 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sun, 13 Apr 2003 15:45:17 +0000 Subject: Finish documentation on net! (This used to be commit 1e6e90ec67785add4b36b15291e315f38702f74b) --- docs/docbook/manpages/net.8.sgml | 833 +++++++++++++++++++++++++++++---------- 1 file changed, 633 insertions(+), 200 deletions(-) (limited to 'docs/docbook/manpages') diff --git a/docs/docbook/manpages/net.8.sgml b/docs/docbook/manpages/net.8.sgml index 62cee8c1d7..f4f75d0c88 100644 --- a/docs/docbook/manpages/net.8.sgml +++ b/docs/docbook/manpages/net.8.sgml @@ -1,4 +1,40 @@ - + %globalentities; + + + +-F flags + +FIXME. Defaults to 0x21 + +'> + + + +-r + +Reboot after shutdown. + + + + +-f + +Force shutting down all applications. + + + + +-t timeout + +Timeout before system will be shut down. An interactive +user of the system can use this time to cancel the shutdown. + +'> +]> + @@ -10,7 +46,8 @@ net Tool for administration of Samba and remote - CIFS servers. + CIFS servers. + @@ -26,14 +63,7 @@ -n myname -s conffile -S server - -C comment - -M maxusers - -F flags - -j jobid -l - -r - -f - -t timeout -P -D debuglevel @@ -46,7 +76,13 @@ 7 suite. The samba net utility is meant to work just like the net utility - available for windows and DOS. + available for windows and DOS. The first argument should be used + to specify the protocol to use when executing a certain command. + ADS is used for ActiveDirectory, RAP is using for old (Win9x/NT3) + clients and RPC can be used for NT4 and Windows 2000. If this + argument is omitted, net will try to determine it automatically. + Not all commands are available on all protocols. + @@ -54,13 +90,7 @@ OPTIONS - - -h - - Display summary of all available options. - - - + &stdarg.help; -w target-workgroup @@ -88,30 +118,21 @@ -I ip-address IP address of target server to use. You have to - specify either this option or a target workgroup or a target server. + specify either this option or a target workgroup or + a target server. -p port - Port on the target server to connect to. + Port on the target server to connect to (usually 139 or 445). + Defaults to trying 445 first, then 139. - - -n myname - - Sets name of the client. - - - - - -s conffile - - Specify alternative configuration file that should be loaded. - - + &stdarg.netbios.name; + &stdarg.configfile; -S server @@ -121,59 +142,10 @@ - - -C comment - - FIXME - - - - - -M maxusers - - FIXME - - - - - -F flags - - FIXME - - - - - -j jobid - - FIXME - - - -l - FIXME - - - - - -r - - FIXME - - - - - -f - - FIXME - - - - - -t timeout - - FIXME + When listing data, give more information on each item. @@ -184,147 +156,610 @@ - - -D debuglevel - set the debuglevel. Debug level 0 is the lowest - and 100 being the highest. This should be set to 100 if you are - planning on submitting a bug report to the Samba team (see - BUGS.txt). - - + &stdarg.debug; - +COMMANDS + + TIME The NET TIME command allows you to view the time on a remote server or synchronise the time on the local server with the time on the remote server. - - - - - Without any options, the NET TIME command - displays the time on the remote server. - - + +TIME - - SYSTEM - - Displays the time on the remote server in a format ready for /bin/date - - +Without any options, the NET TIME command +displays the time on the remote server. + - - SET - - Tries to set the date and time of the local server to that on - the remote server using /bin/date. - - + - - ZONE - - Displays the timezone in hours from GMT on the remote computer. - - - - + +TIME SYSTEM - - RPC + Displays the time on the remote server in a format ready for /bin/date - The NET RPC command allows you to do various - NT4 operations. + - - - JOIN -U username[%password] [options] - - Join a domain with specified username and password. Password - will be prompted if none is specified. - - + +TIME SET +Tries to set the date and time of the local server to that on +the remote server using /bin/date. - - JOIN [options except -U] - - to join a domain created in server manager - - + - - USER [misc. options] [targets] - - List users - - + +TIME ZONE - - USER DELETE <name> [misc options] - - delete specified user - - +Displays the timezone in hours from GMT on the remote computer. - - USER INFO <name> [misc options] - - list the domain groups of the specified user - - + + - - USER ADD <name> [password] [-F user flags] [misc. options] - - Add specified user - - + +[RPC|ADS] JOIN [OLDSTYLE] [-U username[%password]] [options] - - GROUP [misc options] [targets] - - List user groups - - + +Join a domain with specified username and password. Password +will be prompted if none is specified. If no +user name is specified, a domain created in server manager +can be joined. + - - GROUP DELETE <name> [misc. options] [targets] - - Delete specified group - - +Specify [OLDSTYLE] to join the domain using the old +style of domain joining - you need to create a trust +account in server manager first. + + + +[RPC|ADS] USER - - GROUP ADD <name> [-C comment] - - Create specified group - - + +[RPC|ADS] USER DELETE <replaceable>target</replaceable> - - SHARE [misc. options] [targets] - - enumerates all exported resources (network shares) on target server - - +Delete specified user - - SHARE ADD <name=serverpath> [misc. options] [targets] - - Adds a share from a server (makes the export active) - - + + + +[RPC|ADS] USER LIST + +List all users + + + + +[RPC|ADS] USER INFO <replaceable>target</replaceable> + +List the domain groups of a the specified user. + + + + +[RPC|ADS] USER ADD <replaceable>name</replaceable> [password] [-F user flags] [-C comment] + +Add specified user. + + + + +[RPC|ADS] GROUP + + +[RPC|ADS] GROUP [misc options] [targets] +List user groups. + + + +[RPC|ADS] GROUP DELETE <replaceable>name</replaceable> [misc. options] + +Delete specified group. + + + + +[RPC|ADS] GROUP ADD <replaceable>name</replaceable> [-C comment] + +Create specified group. + + + + + +[RAP|RPC] SHARE + + +[RAP|RPC] SHARE [misc. options] [targets] + +Enumerates all exported resources (network shares) on target server. + + + + +[RAP|RPC] SHARE ADD <replaceable>name=serverpath</replaceable> [-C comment] [-M maxusers] [targets] + +Adds a share from a server (makes the export active). Maxusers +specifies the number of users that can be connected to the +share simultaneously. + + + + +SHARE DELETE <replaceable>sharenam</replaceable> + +Delete specified share. + + + + +[RPC|RAP] FILE + + +[RPC|RAP] FILE + +List all open files on remote server. + + + + +[RPC|RAP] FILE CLOSE <replaceable>fileid</replaceable> + +Close file with specified fileid on +remote server. + + + + +[RPC|RAP] FILE INFO <replaceable>fileid</replaceable> + + +Print information on specified fileid. +Currently listed are: file-id, username, locks, path, permissions. + + + + + +[RAP|RPC] FILE USER + +¬.implemented; + + + + + + +SESSION + + +RAP SESSION + +Without any other options, SESSION enumerates all active SMB/CIFS +sessions on the target server. + + + + +RAP SESSION DELETE|CLOSE <replaceable>CLIENT_NAME</replaceable> + +Close the specified sessions. + + + + +RAP SESSION INFO <replaceable>CLIENT_NAME</replaceable> + +Give a list with all the open files in specified session. + + + + + + +RAP SERVER <replaceable>DOMAIN</replaceable> + +List all servers in specified domain or workgroup. Defaults +to local domain. + + + + +RAP DOMAIN + +Lists all domains and workgroups visible on the +current network. + + + + +RAP PRINTQ + + +RAP PRINTQ LIST <replaceable>QUEUE_NAME</replaceable> + +Lists the specified print queue and print jobs on the server. +If the QUEUE_NAME is omitted, all +queues are listed. + + + + +RAP PRINTQ DELETE <replaceable>JOBID</replaceable> + +Delete job with specified id. + + + + + + +RAP VALIDATE <replaceable>user</replaceable> [<replaceable>password</replaceable>] + + +Validate whether the specified user can log in to the +remote server. If the password is not specified on the commandline, it +will be prompted. + + +¬.implemented; + + + + +RAP GROUPMEMBER + + +RAP GROUPMEMBER LIST <replaceable>GROUP</replaceable> + +List all members of the specified group. + + + + +RAP GROUPMEMBER DELETE <replaceable>GROUP</replaceable> <replaceable>USER</replaceable> + +Delete member from group. + + + + +RAP GROUPMEMBER ADD <replaceable>GROUP</replaceable> <replaceable>USER</replaceable> + +Add member to group. + + + + + + +RAP ADMIN <replaceable>command</replaceable> + +Execute the specified command on +the remote server. Only works with OS/2 servers. + + +¬.implemented; + + + + +RAP SERVICE + + +RAP SERVICE START <replaceable>NAME</replaceable> [arguments...] + +Start the specified service on the remote server. Not implemented yet. + +¬.implemented; + + + + +RAP SERVICE STOP + +Stop the specified service on the remote server. + +¬.implemented; + + + + + + +RAP PASSWORD <replaceable>USER</replaceable> <replaceable>OLDPASS</replaceable> <replaceable>NEWPASS</replaceable> + + +Change password of USER from OLDPASS to NEWPASS. + + + + + +LOOKUP + + +LOOKUP HOST <replaceable>HOSTNAME</replaceable> [<replaceable>TYPE</replaceable>] + + +Lookup the IP address of the given host with the specified type (netbios suffix). +The type defaults to 0x20 (workstation). + + + + + +LOOKUP LDAP [<replaceable>DOMAIN</replaceable> + +Give IP address of LDAP server of specified DOMAIN. Defaults to local domain. + + + + +LOOKUP KDC [<replaceable>REALM</replaceable>] + +Give IP address of KDC for the specified REALM. +Defaults to local realm. + + + + +LOOKUP DC [<replaceable>DOMAIN</replaceable>] + +Give IP's of Domain Controllers for specified +DOMAIN. Defaults to local domain. + + + + +LOOKUP MASTER <replaceable>DOMAIN</replaceable> + +Give IP of master browser for specified DOMAIN +or workgroup. Defaults to local domain. + + + + + + +CACHE + +Interface to samba's internal gencache functions. For debugging +purposes only. + + + + + + +GETLOCALSID [DOMAIN] + +Print the SID of the specified domain, or if the parameter is +omitted, the SID of the domain the local server is in. + + + + +SETLOCALSID S-1-5-21-x-y-z + +Sets domain sid for the local server to the specified SID. + + + + +MAXRID + +Prints out the highest RID currently in use on the local +server (by the active 'passdb backend'). + + + + + +RPC INFO + +Print information about the domain of the remote server, +such as domain name, domain sid and number of users and groups. + + + + + +[RPC|ADS] TESTJOIN + +Check whether participation in a domain is still valid. + + + + +[RPC|ADS] CHANGETRUSTPW + +Force change of domain trust password. + + + + +RPC TRUSTDOM + + +RPC TRUSTDOM ADD <replaceable>DOMAIN</replaceable> + +Add a interdomain trust account for +DOMAIN to the remote server. + + + + + +RPC TRUSTDOM DEL <replaceable>DOMAIM</replaceable> + +Remove interdomain trust account for +DOMAIN from the remote server. + + +¬.implemented; + + + + +RPC TRUSTDOM ESTABLISH <replaceable>DOMAIN</replaceable> + + +Establish a trust relationship to a trusting domain. +Interdomain account must already be created on the remote PDC. + + + + + +RPC TRUSTDOM REVOKE <replaceable>DOMAIN</replaceable> +Abandon relationship to trusted domain + + + + +RPC TRUSTDOM LIST + +List all current interdomain trust relationships. + + + + + + +RPC ABORTSHUTDOWN + +Abort the shutdown of a remote server. + + + + +SHUTDOWN [-t timeout] [-r] [-f] [-C message] + +Shut down the remote server. + + +&net.arg.shutdown; + +-C message +Display the specified message on the screen to +announce the shutdown. + + + + + + +SAMDUMP + +Print out sam database of remote server. You need +to run this on either a BDC. + + + +VAMPIRE + +Export users, aliases and groups from remote server to +local server. Can only be run an a BDC. + + + + + +GETSID + +Fetch domain SID and store it in the local secrets.tdb. + + + + +ADS LEAVE + +Make the remote host leave the domain it is part of. + + + + +ADS STATUS + +Print out status of machine account of the local machine in ADS. +Prints out quite some debug info. Aimed at developers, regular +users should use NET ADS TESTJOIN. + + + + +ADS PRINTER + + +ADS PRINTER INFO [<replaceable>PRINTER</replaceable>] [<replaceable>SERVER</replaceable>] + + +Lookup info for PRINTER on SERVER. The printer name defaults to "*", the +server name defaults to the local host. + + + + +ADS PRINTER PUBLISH <replaceable>PRINTER</replaceable> + +Publish specified printer using ADS. + + + + +ADS PRINTER REMOVE <replaceable>PRINTER</replaceable> + +Remove specified printer from ADS directory. + + + + + + +ADS SEARCH <replaceable>EXPRESSION</replaceable> <replaceable>ATTRIBUTES...</replaceable> + +Perform a raw LDAP search on a ADS server and dump the results. The +expression is a standard LDAP search expression, and the +attributes are a list of LDAP fields to show in the results. + +Example: net ads search '(objectCategory=group)' sAMAccountName + + + + + +ADS DN <replaceable>DN</replaceable> <replaceable>(attributes)</replaceable> + + +Perform a raw LDAP search on a ADS server and dump the results. The +DN standard LDAP DN, and the attributes are a list of LDAP fields +to show in the result. + + +Example: net ads dn 'CN=administrator,CN=Users,DC=my,DC=domain' SAMAccountName + + + + +WORKGROUP + +Print out workgroup name for specified kerberos realm. + + + + + +HELP [COMMAND] + +Gives usage information for the specified command. + + - - SHARE DELETE <sharenam - - - @@ -342,9 +777,7 @@ by the Samba Team as an Open Source project similar to the way the Linux kernel is developed. - The original Samba man pages were written by Karl Auer. - The current set of manpages and documentation is maintained - by the Samba Team in the same fashion as the Samba source code. + The net manpage was written by Jelmer Vernooij. -- cgit