Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to set up a CUPS print server on a Knoppix system for use by Windows clients in an Active Directory domain. So far, I've had success with printing over IPP. Now I want to explore the possibility of using Samba to access the printers. I've undertaken the following steps to set up the printer:

  • Added the printer to CUPS using the Windows Printer via Samba (Windows) option, giving the URL smb://<user name>@<IP address>/<printer share name>.
  • Set the Samba workgroup to the Windows domain name
  • Added a user of the same name to the system using sudo useradd <user name> --shell /bin/false
  • Set the corresponding windows domain user's password using sudo smbpasswd -a <user name>.
  • Finally, I set the workgroup name in the Samba configuration file to the windows domain name.

Trying to print the test page on the newly set up printer gives me the following error:

Session setup failed:
NT_STATUS_LOGON_FAILURE

These are the relevant settings in my smb.conf:

[global]
workgroup = MY-DOMAIN-NAME
security = share
printcap name = cups
use client driver = yes
[printers]
path = /var/spool/samba
printable = yes
create mask = 0700
use client driver = yes
[print$]
path = /var/lib/samba/printers
guest ok = yes
write list = root some.domainuser
force group = @ntadmin
directory mask = 0775
create mask = 0664

Have I overlooked something or made a mistake with this setup?

share|improve this question

migrated from serverfault.com Jan 24 '13 at 13:02

This question came from our site for professional system and network administrators.

add comment

1 Answer

What version of Windows are you using? On Windows 7 you should be able to right click the printer and go to Printer Properties from there go to ports. Select the port you use and configure it. Under Security Options select the appropriate button. More than likely you'll want to use "Automatically use the Windows logon name and password"

share|improve this answer
    
I've just had a look: There are some ports listed, but none is checked and all are grayed out, meaning I probably can't change their settings. I'm an administrator on my Windows 7 machine. Do I have to have elevated rights for this? –  waldrumpus Mar 14 '13 at 13:31
    
Update: I've just had a look at the printer settings of a printer shared from a Windows machine. In there, I can readily change the port settings, and one of them is checked. –  waldrumpus Mar 14 '13 at 13:33
    
The smb://<user name>@<IP address>/<printer share name> that you are using is for when you're trying to connect CUPS to use a printer that is located on a Windows machine rather than using a Windows client to connect to a printer located on a Samba machine. –  davelupt Mar 16 '13 at 18:20
    
What happens when you go into Windows cmd and type net use * \\ipaddress\printers /u:username ? Given that you've set up a Unix user account of the same name as the Samba user and given the Samba user a password, it should ask you for a password. –  davelupt Mar 16 '13 at 18:22
    
One last thing. What does your smb.conf look like? –  davelupt Mar 16 '13 at 18:25
show 2 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.