Mac: samba printing instructions
Update 2016-02-17
While troubleshooting the latest situation, I discovered that 'On hold (Authentication required)' is a generic error message. In this case, it meant that the smb url string’s print server name did not have a dns lookup, i.e. the name was incorrect for samba. Strangely, both names gave the same ip address in a host lookup!
Update 2015-07-16
Summary: The old and new syntax both work. It is unclear as to why they did not work before. Therefore, just use the procedure described in detail below. If that does not work, use the same procedure but through the CUPS' web interface, http:127.0.0.1:631.
Details: In order to eliminate any ambiguity (which ended up causing more), I rebuilt my Mavericks' test image and used the procedure below on UW’s wireless network:
-
I was expecting the usual printing error message, 'On hold (Authentication required)'
-
instead, the print job worked!
Update 2015-07-14
As of June 2015, the syntax, outlined below, no longer works. It may be caused by network security changes on the wireless network and mac os x 10.9. Either way, the old syntax of 'smb://username:password@pcname/printername,' http://apple.stackexchange.com/questions/20363/cant-print-on-os-x-lion-via-shared-printer-connected-to-windows-vista-fix, is again valid.
Goal
To allow non-Engineering managed macs, students and some staff, to print to faculty Active Director (ad) printers.
Situation
Prior to Lion, in the advanced settings of Print & Scan, you could select Windows printing with a samba url string, i.e. smb://username:password@WORKGROUPNAME/printServerName/printQueueName, and the user could print without being prompted for authentication.
Solution
As of Lion, Apple implemented their own version of samba printing, using the Windows spoolss option in the Advanced Print & Scan. This method requires a change in the samba url string command syntax. Thanks to Guillermo Fuentes from Arts Computing who pointed out this change to me. The syntax seems to be smb://printServerName.workGroupName.httpHostName/printQueueName.
The instructions are almost exactly the same as for Lion and Mountain Lion except that the syntax for the authentication dialog box has changed (Yet another modified syntax). The detailed instructions below has a specific example for an Engineering Computing printer.
I will use the fictional user Stu Dent, who’s Nexus user id is s3dent.
You will need access to an administrator-privileged account to complete this configuration.
Under the Apple menu, select System Preferences. Then under the Hardware row, open the Printers & Scanners preferences panel. Click the Plus (+) and select Add Other Printer or Scanner… to add a printer. If the Advanced tab icon is there, click on it and skip the next paragraph.
To add the Advanced tab icon:
-
Hold down the Control key and click on the Add Printer top window bar.
-
In the top pull-down menu, select Customize toolbar (at the bottom of the list).
-
Click and hold the Advanced icon and drag it to the Add Printer top window bar.
-
Click the Done button.
Once in the Advanced tab:
-
For the Type, select Windows printer via spoolss
-
In the URL text box, copy and paste the following text for the selected printer:
-
for example, smb://eng-serve.nexus.uwaterloo.ca/eng_engcomp
-
-
Type a meaningful printer name in the space provided, i.e. Office printer.
-
For a driver, select something similar to HP Laserjet 4050. Note that your selection depends on the drivers available on your Mac. If you do not see anything similar to the suggested driver, you may also be able to download a suitable driver from the printer vendor, or just use a suitable generic driver, i.e. HP Universal Printing PCL 5.
-
i.e. <br /> <img src="%ATTACHURLPATH%/addPrinter.jpg" alt="Samba print setup dialog" width='518' height='433' />
-
Finally, click the Add button. You will be prompted to select any Installable Options. Select what you want and click Continue.
-
You are now ready to print. You will be prompted for your user ID and password each time you send a print job.
-
If you get an "Authentication error" at first, this is because your Mac is using your local credentials to print to the Nexus server. What you have to do next is:
-
open the print queue by going to the printer icon on the dock
-
select the print job and click Resume
-
an authentication window will appear; be sure to type your AD fully qualified domain when you enter your name, in our case, it is 'nexus.uwaterloo.ca':
-
Name: yourADDomain\yourUserID, i.e. nexus.uwaterloo.ca\s3dent
-
Password: yourPassword
-
-
your print job should print fine.
-
-
Note: Be prepared to be charged for print jobs sent to publicly accessible printers. Most of these use the XAS accounting system.
— MarlonAGriffith - 23 Apr 2014