First off, thank-you for this wonderful group! This is my first post, but LinuxQuestions.org has been indispensable in getting my file server up and running.
Next, a description of my problem. I have an Intel machine running Ubuntu Server version 18.04.1 LTS, with CUPS 2.2.7 and Samba 4.7.6. The file shares on Samba are working great, no problems there. But I'm having troubles getting the printers to work when they're shared through Samba.
So here's what I've got so far. I have three printers, all of which are connected to the network wirelessly. I was able to install all three into CUPS with no problems, and the Linux machine prints to all with no problems. Sharing those printers through CUPS, my Windows machines can print to all three printers with no problems as well. By the way, the printers are installed in CUPS as Internet Printing Protocol (http) (
http://192.168.0.xxx).
But, when I create printer shares in smb.conf, the shares show up on my Windows machines, I can add them to the Windows machines, but they show persistently offline. Plus, whenever I try to make any changes to those printers on the Windows machines, I am met with the Windows error: "The server print spooler service is not running. Please restart the spooler on the server or restart the server machine." This happens whether I install them by double-clicking the printer share in Windows, or I install them by adding them through Control Panel > Devices and Printers > Add a new printer > The printer that I want isn't listed > Select a shared printer by name.
So, of course, I did lots of restarting the smbd and nmbd services as I was trying to get this to work, and lots of reboots. Made sure that the printer name in smb.conf matched the printer name in CUPS. Lots of restarting the Print Spooler on the Windows machines as well. I purged CUPS and reinstalled, copying over the cupsd.conf.defualt file for a fresh start. I also attempted to change the Samba spool directory to a directory in home, as well as change its permissions to 777, in case it was a permissions problem. Finally, I found a site that mentioned activating Samba's built-in spooler by adding "rpc_daemon:spoolssd = fork" and "rpc_server:spoolss = external" to the [global] part of smb.conf, but that didn't work either. Tried installing the printers as IPP instead, with no change.
Any ideas of what I should try next, or what kind of setting I might have wrong? I'll include the dump of my smb.conf from testparm in case any of you might spot something there.
Thanks in advance for your help!
-----
# Global parameters
[global]
dns proxy = No
log file = /var/log/samba/log.%m
map to guest = Bad User
max log size = 1000
obey pam restrictions = Yes
pam password change = Yes
panic action = /usr/share/samba/panic-action %d
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
passwd program = /usr/bin/passwd %u
server role = standalone server
server string = %h server (Samba, Ubuntu)
syslog = 0
unix password sync = Yes
usershare allow guests = Yes
workgroup = LBCNWORKGROUP
rpc_daemon:spoolssd = fork
rpc_server:spoolss = external
idmap config * : backend = tdb
[printers]
browseable = No
comment = All Printers
force user = jeremy
guest ok = Yes
path = /var/spool/samba/
printable = Yes
read only = No
[print$]
comment = Printer Drivers
guest ok = Yes
path = /var/lib/samba/printers
[LBCN]
force user = jeremy
path = /home/jeremy/LBCN
read only = No
valid users = jeremy pasto
[Backup Drive]
force user = jeremy
path = /media/jeremy/TOSHIBAEXT
read only = No
valid users = jeremy pasto
[Brother Color LaserJet (Office)]
force user = jeremy
path = /var/spool/samba/
printable = Yes
printer name = HL3170CDW
[Brother Color InkJet (Home)]
force user = jeremy
path = /var/spool/samba/
printable = Yes
printer name = MFCJ470DW
[Brother B&W LaserJet (Office)]
force user = jeremy
path = /var/spool/samba/
printable = Yes
printer name = MFC7860DW