From 05b2b2cdd4895b6d2a4d345192bfd4fed1e0ec25 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Fri, 1 Jun 2001 11:50:38 +0000 Subject: syncing up with SAMBA_2_2 (This used to be commit 1bc58c21b15fcdb0a504d051f60e20c4e24441e6) --- docs/docbook/projdoc/printer_driver2.sgml | 341 ++++++++++++++++++++++-------- 1 file changed, 247 insertions(+), 94 deletions(-) (limited to 'docs/docbook/projdoc/printer_driver2.sgml') diff --git a/docs/docbook/projdoc/printer_driver2.sgml b/docs/docbook/projdoc/printer_driver2.sgml index 7f0aebc45f..51471ae690 100644 --- a/docs/docbook/projdoc/printer_driver2.sgml +++ b/docs/docbook/projdoc/printer_driver2.sgml @@ -13,7 +13,7 @@ - (20 Apr 2001) + (3 May 2001) Printing Support in Samba 2.2.x @@ -55,17 +55,42 @@ SPOOLSS support includes: information + +There has been some initial confusion about what all this means +and whether or not it is a requirement for printer drivers to be +installed on a Samba host in order to support printing from Windows +clients. A bug existed in Samba 2.2.0 which made Windows NT/2000 clients +require that the Samba server possess a valid driver for the printer. +This is fixed in Samba 2.2.1 and once again, Windows NT/2000 clients +can use the local APW for installing drivers to be used with a Samba +served printer. This is the same behavior exhibited by Windows 9x clients. +As a side note, Samba does not use these drivers in any way to process +spooled files. They are utilized entirely by the clients. + + + +The following MS KB article, may be of some help if you are dealing with +Windows 2000 clients: How to Add Printers with No User +Interaction in Windows 2000 + + + +http://support.microsoft.com/support/kb/articles/Q189/1/05.ASP + + Configuration + +[print$] vs. [printer$] + -WARNING!!! Previous versions of Samba -recommended using a share named [printer$]. This name was taken from the -printer$ service created by Windows 9x clients when a -printer was shared. Windows 9x printer servers always have +Previous versions of Samba recommended using a share named [printer$]. +This name was taken from the printer$ service created by Windows 9x +clients when a printer was shared. Windows 9x printer servers always have a printer$ service which provides read-only access via no password in order to support printer driver downloads. @@ -81,13 +106,13 @@ the client. -These parameters, including printer driver +These parameters, including printer driver file parameter, are being depreciated and should not be used in new installations. For more information on this change, -you should refer to the Migration section -of this document. +you should refer to the Migration section +of this document. - + Creating [print$] @@ -112,18 +137,22 @@ appropriate values for your site): guest ok = yes browseable = yes read only = yes + ; since this share is configured as read only, then we need + ; a 'write list'. Check the file system permissions to make + ; sure this account can copy files to the share. If this + ; is setup to a non-root account, then it should also exist + ; as a 'printer admin' write list = ntadmin The write list is used to allow administrative level user accounts to have write access in order to update files -on the share. See the -smb.conf(5) man page for more information on -configuring file shares. +on the share. See the smb.conf(5) +man page for more information on configuring file shares. -The requirement for -guest ok = yes depends upon how your +The requirement for guest +ok = yes depends upon how your site is configured. If users will be guaranteed to have an account on the Samba host, then this is a non-issue. @@ -165,27 +194,33 @@ for each architecture you wish to support. - ATTENTION! REQUIRED PERMISSIONS +ATTENTION! REQUIRED PERMISSIONS - In order to currently add a new driver to you Samba host, - one of two conditions must hold true: + +In order to currently add a new driver to you Samba host, +one of two conditions must hold true: + - - The account used to connect to the Samba host - must have a uid of 0 (i.e. a root account) + + The account used to connect to the Samba host + must have a uid of 0 (i.e. a root account) - The account used to connect to the Samba host - must be a member of the printer - admin list. - - - Of course, the connected account must still possess access - to add files to the subdirectories beneath [print$]. + The account used to connect to the Samba host + must be a member of the printer + admin list. + + + +Of course, the connected account must still possess access +to add files to the subdirectories beneath [print$]. Remember +that all file shares are set to 'read only' by default. + -Once you have created the required [print$] service and + +Once you have created the required [print$] service and associated subdirectories, simply log onto the Samba server using a root (or printer admin) account from a Windows NT 4.0 client. Navigate to the "Printers" folder @@ -198,9 +233,27 @@ that matches the printer shares defined on your Samba host. Setting Drivers for Existing Printers The initial listing of printers in the Samba host's -Printers folder will have no printer driver assigned to them. -The way assign a driver to a printer is to view the Properties -of the printer and either +Printers folder will have no real printer driver assigned +to them. By default, in Samba 2.2.0 this driver name was set to +NO PRINTER DRIVER AVAILABLE FOR THIS PRINTER. +Later versions changed this to a NULL string to allow the use +tof the local Add Printer Wizard on NT/2000 clients. +Attempting to view the printer properties for a printer +which has this default driver assigned will result in +the error message: + + +Device settings cannot be displayed. The driver +for the specified printer is not installed, only spooler +properties will be displayed. Do you want to install the +driver now? + + + +Click "No" in the error dialog and you will be presented with +the printer properties window. The way assign a driver to a +printer is to either + Use the "New Driver..." button to install @@ -271,7 +324,7 @@ Domain=[NARNIA] OS=[Unix] Server=[Samba 2.2.0-alpha3] description:[POGO\\POGO\hp-print,NO DRIVER AVAILABLE FOR THIS PRINTER,] comment:[] -$ rpcclient pogo -U root%bleaK.er \ +$ rpcclient pogo -U root%secret \ > -c "setdriver hp-print \"HP LaserJet 4000 Series PS\"" Domain=[NARNIA] OS=[Unix] Server=[Samba 2.2.0-alpha3] Successfully set hp-print to driver HP LaserJet 4000 Series PS. @@ -292,7 +345,7 @@ Add Printer Wizard icon. The APW will be show only if The connected user is able to successfully execute an OpenPrinterEx(\\server) with administrative - priviledges (i.e. root or printer admin. + priviledges (i.e. root or printer admin). show @@ -302,8 +355,8 @@ Add Printer Wizard icon. The APW will be show only if In order to be able to use the APW to successfully add a printer to a Samba -server, the addprinter -command must have a defined value. The program +server, the add +printer command must have a defined value. The program hook must successfully add the printer to the system (i.e. /etc/printcap or appropriate files) and smb.conf if necessary. @@ -312,16 +365,16 @@ hook must successfully add the printer to the system (i.e. When using the APW from a client, if the named printer share does not exist, smbd will execute the add printer -program and reparse to the smb.conf +command and reparse to the smb.conf to attempt to locate the new printer share. If the share is still not defined, an error of "Access Denied" is returned to the client. Note that the -add printer program is executed undet the context +add printer program is executed under the context of the connected user, not necessarily a root account. -There is a complementing deleteprinter -command for removing entries from the "Printers..." +There is a complementing delete +printer command for removing entries from the "Printers..." folder. @@ -473,7 +526,7 @@ foreach (supported architecture for a given driver) will reveal that Windows NT always uses the NT driver - name. The is ok as Windows NT always requires that at least + name. This is ok as Windows NT always requires that at least the Windows NT version of the printer driver is present. However, Samba does not have the requirement internally. Therefore, how can you use the NT driver name if is has not @@ -489,67 +542,167 @@ foreach (supported architecture for a given driver) - <anchor id="MIGRATION">Migration to from Samba 2.0.x to - 2.2.x - - Given that printer driver management has changed - (we hope improved :) ) in 2.2.0 over prior releases, - migration from an existing setup to 2.2.0 can follow - several paths. +<anchor id="MIGRATION">Migration to from Samba 2.0.x to 2.2.x + + +Given that printer driver management has changed (we hope improved) in +2.2 over prior releases, migration from an existing setup to 2.2 can +follow several paths. + + + +Windows clients have a tendency to remember things for quite a while. +For example, if a Windows NT client has attached to a Samba 2.0 server, +it will remember the server as a LanMan printer server. Upgrading +the Samba host to 2.2 makes support for MSRPC printing possible, but +the NT client will still remember the previous setting. + + + +In order to give an NT client printing "amesia" (only necessary if you +want to use the newer MSRPC printing functionality in Samba), delete +the registry keys associated with the print server contained in +[HKLM\SYSTEM\CurrentControlSet\Control\Print]. The +spooler service on the client should be stopped prior to doing this: + + + +C:\WINNT\ > net stop spooler + + + +All the normal disclaimers about editing the registry go +here. Be careful, and know what you are doing. + + + +The spooler service should be restarted after you have finished +removing the appropriate registry entries by replacing the +stop command above with start. + + + +Windows 9x clients will continue to use LanMan printing calls +with a 2.2 Samba server so there is no need to perform any of these +modifications on non-NT clients. + - - Achtung! - The following smb.conf parameters are considered to be - depreciated and will be removed soon. Do not use them - in new installations + +Achtung! + + +The following smb.conf parameters are considered to be depreciated and will +be removed soon. Do not use them in new installations + - - printer driver file (G) - + + printer driver file (G) + - printer driver (S) - + printer driver (S) + - printer driver location (S) - - - + printer driver location (S) + + + - Here are the possible scenarios for supporting migration: + +Here are the possible scenarios for supporting migration: + - - If you do not desire the new Windows NT - print driver support, nothing needs to be done. - All existing parameters work the same. - - If you want to take advantage of NT printer - driver support but do not want to migrate the - 9x drivers to the new setup, the leave the existing - printers.def file. When smbd attempts to locate a - 9x driver for the printer in the TDB and fails it - will drop down to using the printers.def (and all - associated parameters). The make_printerdef - tool will also remain for backwards compatibility but will - be moved to the "this tool is the old way of doing it" - pile. - - If you install a Windows 9x driver for a printer - on your Samba host (in the printing TDB), this information will - take precedence and the three old printing parameters - will be ignored (including print driver location). - - If you want to migrate an existing printers.def - file into the new setup, the current only - solution is to use the Windows NT APW to install the NT drivers - and the 9x drivers. This can be scripted using smbclient - and rpcclient. See the - Imprints installation client at http://imprints.sourceforge.net/ - for an example. - - + + If you do not desire the new Windows NT + print driver support, nothing needs to be done. + All existing parameters work the same. + + If you want to take advantage of NT printer + driver support but do not want to migrate the + 9x drivers to the new setup, the leave the existing + printers.def file. When smbd attempts to locate a + 9x driver for the printer in the TDB and fails it + will drop down to using the printers.def (and all + associated parameters). The make_printerdef + tool will also remain for backwards compatibility but will + be moved to the "this tool is the old way of doing it" + pile. + + If you install a Windows 9x driver for a printer + on your Samba host (in the printing TDB), this information will + take precedence and the three old printing parameters + will be ignored (including print driver location). + + If you want to migrate an existing printers.def + file into the new setup, the current only solution is to use the Windows + NT APW to install the NT drivers and the 9x drivers. This can be scripted + using smbclient and rpcclient. See the + Imprints installation client at http://imprints.sourceforge.net/ + for an example. + + + + + -- cgit