From 8f8a9f01909ba29e2b781310baeeaaddc3f15f0d Mon Sep 17 00:00:00 2001 From: "Gerald W. Carter" Date: Tue, 22 Apr 2008 10:09:40 -0500 Subject: Moving docs tree to docs-xml to make room for generated docs in the release tarball. (This used to be commit 9f672c26d63955f613088489c6efbdc08b5b2d14) --- docs-xml/smbdotconf/printing/addportcommand.xml | 26 +++++++ docs-xml/smbdotconf/printing/addprintercommand.xml | 62 +++++++++++++++ docs-xml/smbdotconf/printing/cupsoptions.xml | 35 +++++++++ docs-xml/smbdotconf/printing/cupsserver.xml | 26 +++++++ docs-xml/smbdotconf/printing/defaultdevmode.xml | 38 ++++++++++ .../smbdotconf/printing/deleteprintercommand.xml | 36 +++++++++ docs-xml/smbdotconf/printing/disablespoolss.xml | 23 ++++++ docs-xml/smbdotconf/printing/enumportscommand.xml | 25 ++++++ docs-xml/smbdotconf/printing/forceprintername.xml | 39 ++++++++++ docs-xml/smbdotconf/printing/iprintserver.xml | 19 +++++ docs-xml/smbdotconf/printing/loadprinters.xml | 14 ++++ docs-xml/smbdotconf/printing/lppausecommand.xml | 39 ++++++++++ docs-xml/smbdotconf/printing/lpqcachetime.xml | 29 +++++++ docs-xml/smbdotconf/printing/lpqcommand.xml | 42 +++++++++++ docs-xml/smbdotconf/printing/lpresumecommand.xml | 38 ++++++++++ docs-xml/smbdotconf/printing/lprmcommand.xml | 36 +++++++++ docs-xml/smbdotconf/printing/maxprintjobs.xml | 16 ++++ .../smbdotconf/printing/maxreportedprintjobs.xml | 19 +++++ docs-xml/smbdotconf/printing/os2drivermap.xml | 24 ++++++ docs-xml/smbdotconf/printing/printable.xml | 18 +++++ docs-xml/smbdotconf/printing/printcapcachetime.xml | 21 ++++++ docs-xml/smbdotconf/printing/printcapname.xml | 55 ++++++++++++++ docs-xml/smbdotconf/printing/printcommand.xml | 88 ++++++++++++++++++++++ docs-xml/smbdotconf/printing/printername.xml | 26 +++++++ docs-xml/smbdotconf/printing/printing.xml | 36 +++++++++ docs-xml/smbdotconf/printing/printjobusername.xml | 16 ++++ docs-xml/smbdotconf/printing/queuepausecommand.xml | 28 +++++++ .../smbdotconf/printing/queueresumecommand.xml | 31 ++++++++ .../smbdotconf/printing/showaddprinterwizard.xml | 36 +++++++++ docs-xml/smbdotconf/printing/useclientdriver.xml | 40 ++++++++++ 30 files changed, 981 insertions(+) create mode 100644 docs-xml/smbdotconf/printing/addportcommand.xml create mode 100644 docs-xml/smbdotconf/printing/addprintercommand.xml create mode 100644 docs-xml/smbdotconf/printing/cupsoptions.xml create mode 100644 docs-xml/smbdotconf/printing/cupsserver.xml create mode 100644 docs-xml/smbdotconf/printing/defaultdevmode.xml create mode 100644 docs-xml/smbdotconf/printing/deleteprintercommand.xml create mode 100644 docs-xml/smbdotconf/printing/disablespoolss.xml create mode 100644 docs-xml/smbdotconf/printing/enumportscommand.xml create mode 100644 docs-xml/smbdotconf/printing/forceprintername.xml create mode 100644 docs-xml/smbdotconf/printing/iprintserver.xml create mode 100644 docs-xml/smbdotconf/printing/loadprinters.xml create mode 100644 docs-xml/smbdotconf/printing/lppausecommand.xml create mode 100644 docs-xml/smbdotconf/printing/lpqcachetime.xml create mode 100644 docs-xml/smbdotconf/printing/lpqcommand.xml create mode 100644 docs-xml/smbdotconf/printing/lpresumecommand.xml create mode 100644 docs-xml/smbdotconf/printing/lprmcommand.xml create mode 100644 docs-xml/smbdotconf/printing/maxprintjobs.xml create mode 100644 docs-xml/smbdotconf/printing/maxreportedprintjobs.xml create mode 100644 docs-xml/smbdotconf/printing/os2drivermap.xml create mode 100644 docs-xml/smbdotconf/printing/printable.xml create mode 100644 docs-xml/smbdotconf/printing/printcapcachetime.xml create mode 100644 docs-xml/smbdotconf/printing/printcapname.xml create mode 100644 docs-xml/smbdotconf/printing/printcommand.xml create mode 100644 docs-xml/smbdotconf/printing/printername.xml create mode 100644 docs-xml/smbdotconf/printing/printing.xml create mode 100644 docs-xml/smbdotconf/printing/printjobusername.xml create mode 100644 docs-xml/smbdotconf/printing/queuepausecommand.xml create mode 100644 docs-xml/smbdotconf/printing/queueresumecommand.xml create mode 100644 docs-xml/smbdotconf/printing/showaddprinterwizard.xml create mode 100644 docs-xml/smbdotconf/printing/useclientdriver.xml (limited to 'docs-xml/smbdotconf/printing') diff --git a/docs-xml/smbdotconf/printing/addportcommand.xml b/docs-xml/smbdotconf/printing/addportcommand.xml new file mode 100644 index 0000000000..294ea8e188 --- /dev/null +++ b/docs-xml/smbdotconf/printing/addportcommand.xml @@ -0,0 +1,26 @@ + + + Samba 3.0.23 introduced support for adding printer ports + remotely using the Windows "Add Standard TCP/IP Port Wizard". + This option defines an external program to be executed when + smbd receives a request to add a new Port to the system. + The script is passed two parameters: + + + port name + device URI + + + The deviceURI is in the for of socket://<hostname>[:<portnumber>] + or lpd://<hostname>/<queuename>. + + +enum ports command + + +/etc/samba/scripts/addport.sh + diff --git a/docs-xml/smbdotconf/printing/addprintercommand.xml b/docs-xml/smbdotconf/printing/addprintercommand.xml new file mode 100644 index 0000000000..ed3c5aa3be --- /dev/null +++ b/docs-xml/smbdotconf/printing/addprintercommand.xml @@ -0,0 +1,62 @@ + + + With the introduction of MS-RPC based printing + support for Windows NT/2000 clients in Samba 2.2, The MS Add + Printer Wizard (APW) icon is now also available in the + "Printers..." folder displayed a share listing. The APW + allows for printers to be add remotely to a Samba or Windows + NT/2000 print server. + + For a Samba host this means that the printer must be + physically added to the underlying printing system. The add + printer command defines a script to be run which + will perform the necessary operations for adding the printer + to the print system and to add the appropriate service definition + to the smb.conf file in order that it can be + shared by smbd + 8. + + The addprinter command is + automatically invoked with the following parameter (in + order): + + + printer name + share name + port name + driver name + location + Windows 9x driver location + + + All parameters are filled in from the PRINTER_INFO_2 structure sent + by the Windows NT/2000 client with one exception. The "Windows 9x + driver location" parameter is included for backwards compatibility + only. The remaining fields in the structure are generated from answers + to the APW questions. + + Once the addprinter command has + been executed, smbd will reparse the + smb.conf to determine if the share defined by the APW + exists. If the sharename is still invalid, then smbd + will return an ACCESS_DENIED error to the client. + + + The "add printer command" program can output a single line of text, + which Samba will set as the port the new printer is connected to. + If this line isn't output, Samba won't reload its printer shares. + + + + +deleteprinter command +printing +show add printer wizard + + +/usr/bin/addprinter + diff --git a/docs-xml/smbdotconf/printing/cupsoptions.xml b/docs-xml/smbdotconf/printing/cupsoptions.xml new file mode 100644 index 0000000000..616e273266 --- /dev/null +++ b/docs-xml/smbdotconf/printing/cupsoptions.xml @@ -0,0 +1,35 @@ + + + + This parameter is only applicable if is + set to cups. Its value is a free form string of options + passed directly to the cups library. + + + + You can pass any generic print option known to CUPS (as listed + in the CUPS "Software Users' Manual"). You can also pass any printer + specific option (as listed in "lpoptions -d printername -l") + valid for the target queue. + Multiple parameters should be space-delimited name/value pairs according to + the PAPI text option ABNF specification. Collection values + ("name={a=... b=... c=...}") are stored with the curley brackets intact. + + + + You should set this parameter to raw if your CUPS server + error_log file contains messages such as + "Unsupported format 'application/octet-stream'" when printing from a Windows client + through Samba. It is no longer necessary to enable + system wide raw printing in /etc/cups/mime.{convs,types}. + + + + +"" +"raw media=a4" + diff --git a/docs-xml/smbdotconf/printing/cupsserver.xml b/docs-xml/smbdotconf/printing/cupsserver.xml new file mode 100644 index 0000000000..b31db33eac --- /dev/null +++ b/docs-xml/smbdotconf/printing/cupsserver.xml @@ -0,0 +1,26 @@ + + + + This parameter is only applicable if is set to cups. + + + + If set, this option overrides the ServerName option in the CUPS client.conf. This is + necessary if you have virtual samba servers that connect to different CUPS daemons. + + + Optionally, a port can be specified by separating the server name + and port number with a colon. If no port was specified, + the default port for IPP (631) will be used. + + + + +"" +mycupsserver +mycupsserver:1631 + diff --git a/docs-xml/smbdotconf/printing/defaultdevmode.xml b/docs-xml/smbdotconf/printing/defaultdevmode.xml new file mode 100644 index 0000000000..218ddcb356 --- /dev/null +++ b/docs-xml/smbdotconf/printing/defaultdevmode.xml @@ -0,0 +1,38 @@ + + + This parameter is only applicable to services. + When smbd is serving Printer Drivers to Windows NT/2k/XP clients, each printer on the Samba + server has a Device Mode which defines things such as paper size and + orientation and duplex settings. The device mode can only correctly be + generated by the printer driver itself (which can only be executed on a + Win32 platform). Because smbd is unable to execute the driver code + to generate the device mode, the default behavior is to set this field + to NULL. + + + Most problems with serving printer drivers to Windows NT/2k/XP clients + can be traced to a problem with the generated device mode. Certain drivers + will do things such as crashing the client's Explorer.exe with a NULL devmode. + However, other printer drivers can cause the client's spooler service + (spoolsv.exe) to die if the devmode was not created by the driver itself + (i.e. smbd generates a default devmode). + + + This parameter should be used with care and tested with the printer + driver in question. It is better to leave the device mode to NULL + and let the Windows client set the correct values. Because drivers do not + do this all the time, setting default devmode = yes + will instruct smbd to generate a default one. + + + For more information on Windows NT/2k printing and Device Modes, + see the MSDN documentation. + + + +yes + diff --git a/docs-xml/smbdotconf/printing/deleteprintercommand.xml b/docs-xml/smbdotconf/printing/deleteprintercommand.xml new file mode 100644 index 0000000000..b48ab5700d --- /dev/null +++ b/docs-xml/smbdotconf/printing/deleteprintercommand.xml @@ -0,0 +1,36 @@ + + + With the introduction of MS-RPC based printer + support for Windows NT/2000 clients in Samba 2.2, it is now + possible to delete printer at run time by issuing the + DeletePrinter() RPC call. + + For a Samba host this means that the printer must be + physically deleted from underlying printing system. The + defines a script to be run which + will perform the necessary operations for removing the printer + from the print system and from smb.conf. + + + The is + automatically called with only one parameter: . + + + Once the has + been executed, smbd will reparse the + smb.conf to associated printer no longer exists. + If the sharename is still valid, then smbd + will return an ACCESS_DENIED error to the client. + + +addprinter command +printing +show add printer wizard + + +/usr/bin/removeprinter + diff --git a/docs-xml/smbdotconf/printing/disablespoolss.xml b/docs-xml/smbdotconf/printing/disablespoolss.xml new file mode 100644 index 0000000000..9367eae8b3 --- /dev/null +++ b/docs-xml/smbdotconf/printing/disablespoolss.xml @@ -0,0 +1,23 @@ + + + Enabling this parameter will disable Samba's support + for the SPOOLSS set of MS-RPC's and will yield identical behavior + as Samba 2.0.x. Windows NT/2000 clients will downgrade to using + Lanman style printing commands. Windows 9x/ME will be unaffected by + the parameter. However, this will also disable the ability to upload + printer drivers to a Samba server via the Windows NT Add Printer + Wizard or by using the NT printer properties dialog window. It will + also disable the capability of Windows NT/2000 clients to download + print drivers from the Samba host upon demand. + Be very careful about enabling this parameter. + + + +use client driver + +no + diff --git a/docs-xml/smbdotconf/printing/enumportscommand.xml b/docs-xml/smbdotconf/printing/enumportscommand.xml new file mode 100644 index 0000000000..41db739544 --- /dev/null +++ b/docs-xml/smbdotconf/printing/enumportscommand.xml @@ -0,0 +1,25 @@ + + + The concept of a "port" is fairly foreign + to UNIX hosts. Under Windows NT/2000 print servers, a port + is associated with a port monitor and generally takes the form of + a local port (i.e. LPT1:, COM1:, FILE:) or a remote port + (i.e. LPD Port Monitor, etc...). By default, Samba has only one + port defined--"Samba Printer Port". Under + Windows NT/2000, all printers must have a valid port name. + If you wish to have a list of ports displayed (smbd + does not use a port name for anything) other than + the default "Samba Printer Port", you + can define enumports command to point to + a program which should generate a list of ports, one per line, + to standard output. This listing will then be used in response + to the level 1 and 2 EnumPorts() RPC. + + + +/usr/bin/listports + diff --git a/docs-xml/smbdotconf/printing/forceprintername.xml b/docs-xml/smbdotconf/printing/forceprintername.xml new file mode 100644 index 0000000000..453feedc78 --- /dev/null +++ b/docs-xml/smbdotconf/printing/forceprintername.xml @@ -0,0 +1,39 @@ + + + When printing from Windows NT (or later), + each printer in smb.conf has two + associated names which can be used by the client. The first + is the sharename (or shortname) defined in smb.conf. This + is the only printername available for use by Windows 9x clients. + The second name associated with a printer can be seen when + browsing to the "Printers" (or "Printers and Faxes") folder + on the Samba server. This is referred to simply as the printername + (not to be confused with the printer name option). + + + When assigning a new driver to a printer on a remote + Windows compatible print server such as Samba, the Windows client + will rename the printer to match the driver name just uploaded. + This can result in confusion for users when multiple + printers are bound to the same driver. To prevent Samba from + allowing the printer's printername to differ from the sharename + defined in smb.conf, set force printername = yes. + + + Be aware that enabling this parameter may affect migrating + printers from a Windows server to Samba since Windows has no way to + force the sharename and printername to match. + + It is recommended that this parameter's value not be changed + once the printer is in use by clients as this could cause a user + not be able to delete printer connections from their local Printers + folder. + + + +no + diff --git a/docs-xml/smbdotconf/printing/iprintserver.xml b/docs-xml/smbdotconf/printing/iprintserver.xml new file mode 100644 index 0000000000..81c7ca55a2 --- /dev/null +++ b/docs-xml/smbdotconf/printing/iprintserver.xml @@ -0,0 +1,19 @@ + + + + This parameter is only applicable if is set to iprint. + + + + If set, this option overrides the ServerName option in the CUPS client.conf. This is + necessary if you have virtual samba servers that connect to different CUPS daemons. + + + +"" +MYCUPSSERVER + diff --git a/docs-xml/smbdotconf/printing/loadprinters.xml b/docs-xml/smbdotconf/printing/loadprinters.xml new file mode 100644 index 0000000000..7e40ebee18 --- /dev/null +++ b/docs-xml/smbdotconf/printing/loadprinters.xml @@ -0,0 +1,14 @@ + + + A boolean variable that controls whether all + printers in the printcap will be loaded for browsing by default. + See the section for + more details. + + +yes + diff --git a/docs-xml/smbdotconf/printing/lppausecommand.xml b/docs-xml/smbdotconf/printing/lppausecommand.xml new file mode 100644 index 0000000000..0bb66226f2 --- /dev/null +++ b/docs-xml/smbdotconf/printing/lppausecommand.xml @@ -0,0 +1,39 @@ + + + This parameter specifies the command to be + executed on the server host in order to stop printing or spooling + a specific print job. + + This command should be a program or script which takes + a printer name and job number to pause the print job. One way + of implementing this is by using job priorities, where jobs + having a too low priority won't be sent to the printer. + + If a %p is given then the printer name + is put in its place. A %j is replaced with + the job number (an integer). On HPUX (see printing=hpux + ), if the -p%p option is added + to the lpq command, the job will show up with the correct status, i.e. + if the job priority is lower than the set fence priority it will + have the PAUSED status, whereas if the priority is equal or higher it + will have the SPOOLED or PRINTING status. + + Note that it is good practice to include the absolute path + in the lppause command as the PATH may not be available to the server. + + +printing + +Currently no default value is given to + this string, unless the value of the + parameter is SYSV, in which case the default is : + lp -i %p-%j -H hold or if the value of the + printing parameter is + SOFTQ, then the default is: + qstat -s -j%j -h. +/usr/bin/lpalt %p-%j -p0 + diff --git a/docs-xml/smbdotconf/printing/lpqcachetime.xml b/docs-xml/smbdotconf/printing/lpqcachetime.xml new file mode 100644 index 0000000000..5a64937906 --- /dev/null +++ b/docs-xml/smbdotconf/printing/lpqcachetime.xml @@ -0,0 +1,29 @@ + + + This controls how long lpq info will be cached + for to prevent the lpq command being called too + often. A separate cache is kept for each variation of the + lpq command used by the system, so if you use different + lpq commands for different users then they won't + share cache information. + + The cache files are stored in /tmp/lpq.xxxx + where xxxx is a hash of the lpq command in use. + + The default is 30 seconds, meaning that the cached results + of a previous identical lpq command will be used + if the cached data is less than 30 seconds old. A large value may + be advisable if your lpq command is very slow. + +A value of 0 will disable caching completely. + + +printing + +30 +10 + diff --git a/docs-xml/smbdotconf/printing/lpqcommand.xml b/docs-xml/smbdotconf/printing/lpqcommand.xml new file mode 100644 index 0000000000..8c06b75898 --- /dev/null +++ b/docs-xml/smbdotconf/printing/lpqcommand.xml @@ -0,0 +1,42 @@ + + + This parameter specifies the command to be + executed on the server host in order to obtain lpq + -style printer status information. + + This command should be a program or script which + takes a printer name as its only parameter and outputs printer + status information. + + Currently nine styles of printer status information + are supported; BSD, AIX, LPRNG, PLP, SYSV, HPUX, QNX, CUPS, and SOFTQ. + This covers most UNIX systems. You control which type is expected + using the printing = option. + + Some clients (notably Windows for Workgroups) may not + correctly send the connection number for the printer they are + requesting status information about. To get around this, the + server reports on the first printer service connected to by the + client. This only happens if the connection number sent is invalid. + + If a %p is given then the printer name + is put in its place. Otherwise it is placed at the end of the + command. + + Note that it is good practice to include the absolute path + in the lpq command as the $PATH + may not be available to the server. When compiled with + the CUPS libraries, no lpq command is + needed because smbd will make a library call to obtain the + print queue listing. + + +printing + +/usr/bin/lpq -P%p + + diff --git a/docs-xml/smbdotconf/printing/lpresumecommand.xml b/docs-xml/smbdotconf/printing/lpresumecommand.xml new file mode 100644 index 0000000000..706a999b1f --- /dev/null +++ b/docs-xml/smbdotconf/printing/lpresumecommand.xml @@ -0,0 +1,38 @@ + + + This parameter specifies the command to be + executed on the server host in order to restart or continue + printing or spooling a specific print job. + + This command should be a program or script which takes + a printer name and job number to resume the print job. See + also the parameter. + + If a %p is given then the printer name + is put in its place. A %j is replaced with + the job number (an integer). + + Note that it is good practice to include the absolute path + in the lpresume command as the PATH may not + be available to the server. + + See also the parameter. + + Default: Currently no default value is given + to this string, unless the value of the printing + parameter is SYSV, in which case the default is: + + lp -i %p-%j -H resume + + or if the value of the printing parameter + is SOFTQ, then the default is: + + qstat -s -j%j -r + + +/usr/bin/lpalt %p-%j -p2 + diff --git a/docs-xml/smbdotconf/printing/lprmcommand.xml b/docs-xml/smbdotconf/printing/lprmcommand.xml new file mode 100644 index 0000000000..0b8375f94d --- /dev/null +++ b/docs-xml/smbdotconf/printing/lprmcommand.xml @@ -0,0 +1,36 @@ + + + This parameter specifies the command to be + executed on the server host in order to delete a print job. + + This command should be a program or script which takes + a printer name and job number, and deletes the print job. + + If a %p is given then the printer name + is put in its place. A %j is replaced with + the job number (an integer). + + Note that it is good practice to include the absolute + path in the lprm command as the PATH may not be + available to the server. + + + Examples of use are: + +lprm command = /usr/bin/lprm -P%p %j + +or + +lprm command = /usr/bin/cancel %p-%j + + + + +printing + + determined by printing parameter + diff --git a/docs-xml/smbdotconf/printing/maxprintjobs.xml b/docs-xml/smbdotconf/printing/maxprintjobs.xml new file mode 100644 index 0000000000..51801620e8 --- /dev/null +++ b/docs-xml/smbdotconf/printing/maxprintjobs.xml @@ -0,0 +1,16 @@ + + + This parameter limits the maximum number of + jobs allowable in a Samba printer queue at any given moment. + If this number is exceeded, smbd + 8 will remote "Out of Space" to the client. + + + +1000 +5000 + diff --git a/docs-xml/smbdotconf/printing/maxreportedprintjobs.xml b/docs-xml/smbdotconf/printing/maxreportedprintjobs.xml new file mode 100644 index 0000000000..34a5eb71c1 --- /dev/null +++ b/docs-xml/smbdotconf/printing/maxreportedprintjobs.xml @@ -0,0 +1,19 @@ + + + + This parameter limits the maximum number of jobs displayed in a port monitor for + Samba printer queue at any given moment. If this number is exceeded, the excess + jobs will not be shown. A value of zero means there is no limit on the number of + print jobs reported. + + + +max print jobs + +0 +1000 + diff --git a/docs-xml/smbdotconf/printing/os2drivermap.xml b/docs-xml/smbdotconf/printing/os2drivermap.xml new file mode 100644 index 0000000000..a578d3af44 --- /dev/null +++ b/docs-xml/smbdotconf/printing/os2drivermap.xml @@ -0,0 +1,24 @@ + + + The parameter is used to define the absolute + path to a file containing a mapping of Windows NT printer driver + names to OS/2 printer driver names. The format is: + + <nt driver name> = <os2 driver name>.<device name> + + For example, a valid entry using the HP LaserJet 5 + printer driver would appear as HP LaserJet 5L = LASERJET.HP + LaserJet 5L. + + + The need for the file is due to the printer driver namespace problem described in + the chapter on Classical Printing in the Samba3-HOWTO book. For more + details on OS/2 clients, please refer to chapter on other clients in the Samba3-HOWTO book. + + + + diff --git a/docs-xml/smbdotconf/printing/printable.xml b/docs-xml/smbdotconf/printing/printable.xml new file mode 100644 index 0000000000..73aa533ed3 --- /dev/null +++ b/docs-xml/smbdotconf/printing/printable.xml @@ -0,0 +1,18 @@ + +print ok + + If this parameter is yes, then + clients may open, write to and submit spool files on the directory + specified for the service. + + Note that a printable service will ALWAYS allow writing + to the service path (user privileges permitting) via the spooling + of print data. The parameter controls only non-printing access to + the resource. + +no + diff --git a/docs-xml/smbdotconf/printing/printcapcachetime.xml b/docs-xml/smbdotconf/printing/printcapcachetime.xml new file mode 100644 index 0000000000..7dcd1b62d4 --- /dev/null +++ b/docs-xml/smbdotconf/printing/printcapcachetime.xml @@ -0,0 +1,21 @@ + + + This option specifies the number of seconds before the printing + subsystem is again asked for the known printers. If the value + is greater than 60 the initial waiting time is set to 60 seconds + to allow an earlier first rescan of the printing subsystem. + + + Setting this parameter to 0 disables any rescanning for new + or removed printers after the initial startup. + + + + +750 +600 + diff --git a/docs-xml/smbdotconf/printing/printcapname.xml b/docs-xml/smbdotconf/printing/printcapname.xml new file mode 100644 index 0000000000..90c575f31c --- /dev/null +++ b/docs-xml/smbdotconf/printing/printcapname.xml @@ -0,0 +1,55 @@ + +printcap + + + This parameter may be used to override the compiled-in default printcap name used by the server (usually + /etc/printcap). See the discussion of the [printers] section above for reasons why you might want to do this. + + + + To use the CUPS printing interface set printcap name = cups . This should + be supplemented by an addtional setting cups in the [global] + section. printcap name = cups will use the "dummy" printcap + created by CUPS, as specified in your CUPS configuration file. + + + + On System V systems that use lpstat to + list available printers you can use printcap name = lpstat + to automatically obtain lists of available printers. This + is the default for systems that define SYSV at configure time in + Samba (this includes most System V based systems). If + printcap name is set to lpstat on + these systems then Samba will launch lpstat -v and + attempt to parse the output to obtain a printer list. + + + + A minimal printcap file would look something like this: + +print1|My Printer 1 +print2|My Printer 2 +print3|My Printer 3 +print4|My Printer 4 +print5|My Printer 5 + + where the '|' separates aliases of a printer. The fact that the second alias has a space in + it gives a hint to Samba that it's a comment. + + + + Under AIX the default printcap name is /etc/qconfig. Samba will + assume the file is in AIX qconfig format if the string qconfig appears in the printcap filename. + + + + +/etc/printcap +/etc/myprintcap + diff --git a/docs-xml/smbdotconf/printing/printcommand.xml b/docs-xml/smbdotconf/printing/printcommand.xml new file mode 100644 index 0000000000..461d6de8e3 --- /dev/null +++ b/docs-xml/smbdotconf/printing/printcommand.xml @@ -0,0 +1,88 @@ + + + After a print job has finished spooling to + a service, this command will be used via a system() + call to process the spool file. Typically the command specified will + submit the spool file to the host's printing subsystem, but there + is no requirement that this be the case. The server will not remove + the spool file, so whatever command you specify should remove the + spool file when it has been processed, otherwise you will need to + manually remove old spool files. + + The print command is simply a text string. It will be used + verbatim after macro substitutions have been made: + + %s, %f - the path to the spool + file name + + %p - the appropriate printer + name + + %J - the job + name as transmitted by the client. + + %c - The number of printed pages + of the spooled job (if known). + + %z - the size of the spooled + print job (in bytes) + + The print command MUST contain at least + one occurrence of %s or %f + - the %p is optional. At the time + a job is submitted, if no printer name is supplied the %p + will be silently removed from the printer command. + + If specified in the [global] section, the print command given + will be used for any printable service that does not have its own + print command specified. + + If there is neither a specified print command for a + printable service nor a global print command, spool files will + be created but not processed and (most importantly) not removed. + + Note that printing may fail on some UNIXes from the + nobody account. If this happens then create + an alternative guest account that can print and set the + in the [global] section. + + You can form quite complex print commands by realizing + that they are just passed to a shell. For example the following + will log a print job, print the file, then remove it. Note that + ';' is the usual separator for command in shell scripts. + + print command = echo Printing %s >> + /tmp/print.log; lpr -P %p %s; rm %s + + You may have to vary this command considerably depending + on how you normally print files on your system. The default for + the parameter varies depending on the setting of the + parameter. + + Default: For printing = BSD, AIX, QNX, LPRNG + or PLP : + print command = lpr -r -P%p %s + + For printing = SYSV or HPUX : + print command = lp -c -d%p %s; rm %s + + For printing = SOFTQ : + print command = lp -d%p -s %s; rm %s + + For printing = CUPS : If SAMBA is compiled against + libcups, then cups + uses the CUPS API to + submit jobs, etc. Otherwise it maps to the System V + commands with the -oraw option for printing, i.e. it + uses lp -c -d%p -oraw; rm %s. + With printing = cups, + and if SAMBA is compiled against libcups, any manually + set print command will be ignored. + + +/usr/local/samba/bin/myprintscript %p %s + diff --git a/docs-xml/smbdotconf/printing/printername.xml b/docs-xml/smbdotconf/printing/printername.xml new file mode 100644 index 0000000000..fad127cad1 --- /dev/null +++ b/docs-xml/smbdotconf/printing/printername.xml @@ -0,0 +1,26 @@ + + printer + + + This parameter specifies the name of the printer to which print jobs spooled through a printable service + will be sent. + + + + If specified in the [global] section, the printer name given will be used for any printable service that + does not have its own printer name specified. + + + + The default value of the may be lp on many + systems. + + + +none +laserwriter + diff --git a/docs-xml/smbdotconf/printing/printing.xml b/docs-xml/smbdotconf/printing/printing.xml new file mode 100644 index 0000000000..3be0f42939 --- /dev/null +++ b/docs-xml/smbdotconf/printing/printing.xml @@ -0,0 +1,36 @@ + + + This parameters controls how printer status information is + interpreted on your system. It also affects the default values for + the print command, lpq command, lppause command , lpresume command, and lprm command if specified in the + [global] section. + + Currently nine printing styles are supported. They are + BSD, AIX, + LPRNG, PLP, + SYSV, HPUX, + QNX, SOFTQ, + and CUPS. + + To see what the defaults are for the other print + commands when using the various options use the testparm + 1 program. + + This option can be set on a per printer basis. Please be + aware however, that you must place any of the various printing + commands (e.g. print command, lpq command, etc...) after defining + the value for the printing option since it will + reset the printing commands to default values. + + See also the discussion in the + [printers] section. + + diff --git a/docs-xml/smbdotconf/printing/printjobusername.xml b/docs-xml/smbdotconf/printing/printjobusername.xml new file mode 100644 index 0000000000..8f72fee8c3 --- /dev/null +++ b/docs-xml/smbdotconf/printing/printjobusername.xml @@ -0,0 +1,16 @@ + + + This parameter specifies which user information will be + passed to the printing system. Usually, the username is sent, + but in some cases, e.g. the domain prefix is useful, too. + + +printing + +%D\%U +%U + diff --git a/docs-xml/smbdotconf/printing/queuepausecommand.xml b/docs-xml/smbdotconf/printing/queuepausecommand.xml new file mode 100644 index 0000000000..aee822ea80 --- /dev/null +++ b/docs-xml/smbdotconf/printing/queuepausecommand.xml @@ -0,0 +1,28 @@ + + + This parameter specifies the command to be + executed on the server host in order to pause the printer queue. + + This command should be a program or script which takes + a printer name as its only parameter and stops the printer queue, + such that no longer jobs are submitted to the printer. + + This command is not supported by Windows for Workgroups, + but can be issued from the Printers window under Windows 95 + and NT. + + If a %p is given then the printer name + is put in its place. Otherwise it is placed at the end of the command. + + + Note that it is good practice to include the absolute + path in the command as the PATH may not be available to the + server. + + +disable %p + diff --git a/docs-xml/smbdotconf/printing/queueresumecommand.xml b/docs-xml/smbdotconf/printing/queueresumecommand.xml new file mode 100644 index 0000000000..f6593c2289 --- /dev/null +++ b/docs-xml/smbdotconf/printing/queueresumecommand.xml @@ -0,0 +1,31 @@ + + + This parameter specifies the command to be + executed on the server host in order to resume the printer queue. It + is the command to undo the behavior that is caused by the + previous parameter (). + + This command should be a program or script which takes + a printer name as its only parameter and resumes the printer queue, + such that queued jobs are resubmitted to the printer. + + This command is not supported by Windows for Workgroups, + but can be issued from the Printers window under Windows 95 + and NT. + + If a %p is given then the printer name + is put in its place. Otherwise it is placed at the end of the + command. + + Note that it is good practice to include the absolute + path in the command as the PATH may not be available to the + server. + + + +enable %p + diff --git a/docs-xml/smbdotconf/printing/showaddprinterwizard.xml b/docs-xml/smbdotconf/printing/showaddprinterwizard.xml new file mode 100644 index 0000000000..293cf9d1aa --- /dev/null +++ b/docs-xml/smbdotconf/printing/showaddprinterwizard.xml @@ -0,0 +1,36 @@ + + + With the introduction of MS-RPC based printing support + for Windows NT/2000 client in Samba 2.2, a "Printers..." folder will + appear on Samba hosts in the share listing. Normally this folder will + contain an icon for the MS Add Printer Wizard (APW). However, it is + possible to disable this feature regardless of the level of privilege + of the connected user. + + Under normal circumstances, the Windows NT/2000 client will + open a handle on the printer server with OpenPrinterEx() asking for + Administrator privileges. If the user does not have administrative + access on the print server (i.e is not root or a member of the + printer admin group), the OpenPrinterEx() + call fails and the client makes another open call with a request for + a lower privilege level. This should succeed, however the APW + icon will not be displayed. + + Disabling the show add printer wizard + parameter will always cause the OpenPrinterEx() on the server + to fail. Thus the APW icon will never be displayed. + +This does not prevent the same user from having + administrative privilege on an individual printer. + + +addprinter command +deleteprinter command +printer admin + +yes + diff --git a/docs-xml/smbdotconf/printing/useclientdriver.xml b/docs-xml/smbdotconf/printing/useclientdriver.xml new file mode 100644 index 0000000000..99e8556811 --- /dev/null +++ b/docs-xml/smbdotconf/printing/useclientdriver.xml @@ -0,0 +1,40 @@ + + + This parameter applies only to Windows NT/2000 + clients. It has no effect on Windows 95/98/ME clients. When + serving a printer to Windows NT/2000 clients without first installing + a valid printer driver on the Samba host, the client will be required + to install a local printer driver. From this point on, the client + will treat the print as a local printer and not a network printer + connection. This is much the same behavior that will occur + when disable spoolss = yes. + + + The differentiating factor is that under normal + circumstances, the NT/2000 client will attempt to open the network + printer using MS-RPC. The problem is that because the client + considers the printer to be local, it will attempt to issue the + OpenPrinterEx() call requesting access rights associated with the + logged on user. If the user possesses local administator rights but + not root privilege on the Samba host (often the case), the + OpenPrinterEx() call will fail. The result is that the client will + now display an "Access Denied; Unable to connect" message + in the printer queue window (even though jobs may successfully be + printed). + + If this parameter is enabled for a printer, then any attempt + to open the printer with the PRINTER_ACCESS_ADMINISTER right is mapped + to PRINTER_ACCESS_USE instead. Thus allowing the OpenPrinterEx() + call to succeed. This parameter MUST not be able enabled + on a print share which has valid print driver installed on the Samba + server. + + +disable spoolss + +no + -- cgit