Cannot print to a Windows 7 shared printer

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
kkolarik

Cannot print to a Windows 7 shared printer

Post by kkolarik »

I have a HP ProBook running LinuxMint 18.3, trying to print to a Brother HL-L2300D printer attached to a Windows7 box. I can add the printer via the menu > Admin. > Printers... windows printer via Samba. I am asked to provide username and password, and there it is! But when I attempt to print, I get "Idle - Session setup failed: NT_STATUS_LOGON_FAILURE" in the printer status box. Password Protection is turned OFF on the Win 7 Box, Even if I delete the password on the Windows machine, I'm still prompted by samba for a password. When I try to print, there is no authentication window, I used to be able to print, but I'm not sure what's changed.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
kato181
Level 9
Level 9
Posts: 2564
Joined: Fri Mar 24, 2017 12:33 am
Location: Frederickton NSW

Re: Cannot print to a Windows 7 shared printer

Post by kato181 »

make sure that the printer is shared on windows, if it's not it won't print.
kkolarik

Re: Cannot print to a Windows 7 shared printer

Post by kkolarik »

Printer on the windows box IS shared, password protection is OFF. Printer can be added via menu\Administration\Printers\.... Authentication IS required to see the printer. When I try to print, I get "Session setup failed: NT_STATUS_INVALID_HANDLE".
User avatar
kato181
Level 9
Level 9
Posts: 2564
Joined: Fri Mar 24, 2017 12:33 am
Location: Frederickton NSW

Re: Cannot print to a Windows 7 shared printer

Post by kato181 »

kkolarik wrote: Wed Feb 13, 2019 12:53 am Printer on the windows box IS shared, password protection is OFF. Printer can be added via menu\Administration\Printers\.... Authentication IS required to see the printer. When I try to print, I get "Session setup failed: NT_STATUS_INVALID_HANDLE".
Google say's the above is a samba error.
sudo apt-get install smbclient
Have you created a samba password?
sudo smbpasswd -a kkolarik (your login name..eg. mine is ron) and set it to always remember.

I'm assuming windows is asking you for the login/pword for your mint computer? or is it the other way around?
If mint is asking you for the login/pword of the windows machine then you type your windows login/pword providing you have set one.

This will probably be a weird question to ask..but, have you installed the printer drivers on your mint?
Can you post a copy of your smb.conf, so i can see what or if anything is wrong with it?

In your smb.conf file have you the following inserted in the network section?

[Global]
sever string = (name you gave to your lm)
workgroup = WORKGROUP
client max protocol - SMB3 or NT1 (this has to follow network)
force user = (your user name)
netbios name = (same as server string)
encrypt passwords = yes
guest account = nobody
name resolve order = lmhosts bcast host wins (ensure lmhosts is included)

Before you edit your smb.conf , do this first:
sudo service smbd stop
sudo service nmbd stop
then edit your smb.conf in root
save then type testparm and select dump then you will be able to see if there are any errors.
if it's all clear then do the following:
sudo service start smbd
sudo service start nmbd
Then re-boot and try again

those are my settings, but i use windoz 10 not 7. Would still be the same though i'd imagine.Windoz 10 doesn't use smb1 anymore it uses smb3.
I think win 7 uses smb1 so u will need to insert under network, the following line.. client max protocol = NT1
try that and see what happens.
read this:
https://ubuntuforums.org/showthread.php?t=2306311
kkolarik

Re: Cannot print to a Windows 7 shared printer

Post by kkolarik »

Your post sent me into a new direction... because the instructions you gave me to shut down samba didn't work. NOT THAT your instructions were wrong, I doubt they were... I found out that while scant samba services were installed, samba wasn't. Installing samba resulted in the error messages going away, but the printing did not occur. I think I've got a compound fault here, but you have provided me with the answer to part of it. Thank you!!! I will share what I find next .. I suspect a problem with the driver... anyone with a suggestion of a generic text driver will be of great assistance.
User avatar
kato181
Level 9
Level 9
Posts: 2564
Joined: Fri Mar 24, 2017 12:33 am
Location: Frederickton NSW

Re: Cannot print to a Windows 7 shared printer

Post by kato181 »

kkolarik wrote: Wed Feb 20, 2019 12:39 am Your post sent me into a new direction... because the instructions you gave me to shut down samba didn't work. NOT THAT your instructions were wrong, I doubt they were... I found out that while scant samba services were installed, samba wasn't. Installing samba resulted in the error messages going away, but the printing did not occur. I think I've got a compound fault here, but you have provided me with the answer to part of it. Thank you!!! I will share what I find next .. I suspect a problem with the driver... anyone with a suggestion of a generic text driver will be of great assistance.
I think samba maybe corrupted, try uninstalling and then reinstalling samba..It can be a pain sometimes to install properly.
Try this link for the linux drivers for your printer.
https://support.brother.com/g/b/downloa ... _as&os=128
see if that helps you mate.
deepakdeshp
Level 20
Level 20
Posts: 12334
Joined: Sun Aug 09, 2015 10:00 am

Re: Cannot print to a Windows 7 shared printer

Post by deepakdeshp »

If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
kkolarik

Re: Cannot print to a Windows 7 shared printer

Post by kkolarik »

Samba WAS NOT installed, so I installed it. I also altered the printers.conf in the CUPS directory so Username:Passord@ is between smb:// and the rest of the URI. The error messages do not appear anymore, as if the printing is successful, but no printout. An experiment of installing the printer LOCALLY gives the final nugget of information: The driver is bad. I'm now wondering if there is another driver I could use in place of the non-working driver.
deepakdeshp
Level 20
Level 20
Posts: 12334
Joined: Sun Aug 09, 2015 10:00 am

Re: Cannot print to a Windows 7 shared printer

Post by deepakdeshp »

If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Locked

Return to “Printers & Scanners”