Samba problems with Ubuntu 9.04

I was trying to set up samba with a new Ubuntu 9.04 (“Jaunty Jackalope”) box, and was frustrated when windows failed to connect to the [homes] share I had enabled.

It turns out that even if you comment out all the printer configuration in /etc/samba/smb.conf, smbd will still try to connect to CUPS, and quietly die.

After setting smb.conf to log to syslog, I saw:

smbd[30539]: printing/print_cups.c:cups_connect(103)
smbd[30539]:   Unable to connect to CUPS server localhost:631 - Connection refused

The solution? Add this to the [global] section:

load printers = no

and pick up the new setting by running

/etc/init.d/samba restart