smbcontrol

   
smbcontrol

The smbcontrol command sends control messages to running smbd or nmbd processes.

Command synopsis

 smbcontrol -i   [options]   

or:

 smbcontrol   [options] process message-type [parameters]   

Options

-i

Runs smbcontrol interactively, executing commands until a blank line or "q" is read. The user must have superuser privileges.

-s filename

Specifies the location of the Samba configuration file.

-d debuglevel

Sets the debugging level for logging. The debug level can be set from to 10.

Whether smbcontrol commands are issued in interactive mode or from the command line, the commands are in the same format. Each command has up to three parts :

process

Specifies the process or group of processes to which to send the message. If process is smbd , all smbd processes will receive the message. If process is nmbd , only the main nmbd process (identified by Samba's nmbd.pid file) receives the message. If process is the numeric PID of a running process on the system, that process will receive the message.

message-type

Specifies the type of message that is sent. For more information, see smbcontrol message types that follows .

parameters

Specifies additional parameters required by some messages.

smbcontrol message types

close-share share_name

Closes the connection to a share or shares. If share_name is specified as an asterisk ( * ), connections to all shares will be closed. To close a single connection, share_name is given as the name of a share, as specified in the Samba configuration file, not including the enclosing brackets. Warning: no message is printed if there is an error in specifying share_name .

debug num

Sets the debugging level. The num parameter specifies the level, which can be from 0 to 10.

debuglevel

Prints the current debugging level.

force-election

Can be used only with nmbd , telling it to force a master browser election.

ping number

Sends number of pings and reports when they receive a reply or timeout. Used for connectivity testing.

profile mode

Controls profiling statistics collection. If mode is on , profile statistics will be collected. If mode is off , collection of statistics is turned off. If mode is specified as count , only counting statistics are collected (and not timing statistics). If mode is flush , the data set is cleared ( initialized ).

profilelevel

Prints the current profiling level.

printer-notify printer_name

Sends a printer notify message to Windows NT/2000/XP for the specified printer. This message can be sent only to smbd . Warning: no message is printed if the printer_name parameter is specified incorrectly.

   


Using Samba
Using Samba: A File and Print Server for Linux, Unix & Mac OS X, 3rd Edition
ISBN: 0596007698
EAN: 2147483647
Year: 2003
Pages: 475

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net