Bug 5348 - 3.2.0 unable print from DOS redirector
Summary: 3.2.0 unable print from DOS redirector
Status: ASSIGNED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Printing (show other bugs)
Version: unspecified
Hardware: x86 Linux
: P3 major (vote)
Target Milestone: ---
Assignee: printing-maintainers
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-23 17:55 UTC by Frantisek Hanzlik
Modified: 2021-01-07 20:55 UTC (History)
1 user (show)

See Also:


Attachments
Win98 log level 6, printing from redirector (3.10 KB, text/plain)
2012-06-27 13:25 UTC, maurizio.faccio
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Frantisek Hanzlik 2008-03-23 17:55:06 UTC
Printing from Win(xp) works fine, but if I capture port for DOS apps (via NET USE LPT1 \\server\printer), then following command "TYPE file >LPT1" or print from DOS app to LPT1 port not works - printer not begins printing.

It seems as job is sent to samba, but isn't declared job finish - because in this manner sended job is then printed when
A) I restart samba
B) I restart WinXP
C) I logout from WXP
; restart CUPS has no effect.

Tested with samba-3.2.0pre2 and 3.2.0pre3 (as of 23-Mar-08) on Fedora 9 Beta.

Self-made compiled version samba-2.0.28a works fine under Fedora 9 Beta.

And at epilogue: I must admit I not fully understand mechanism of DOS printing to remote Win printer; I think jobs is finished when
A) apps use some call of sort "print job finish"
B) after elapse some time (timeout) since last byte of job was sent, print job is declared as finished.

There is for me one interest question too:
- is possible from DOS app/DOS batch tell to printing system (in this case probably to WIN redirector?) that job is completed and force it treat?
--- or set job-interchar-timeout as user-defined value (forcing job close and
begin print output on appropriate printing device)
Comment 1 Karolin Seeger 2008-08-20 08:33:13 UTC
Can you reproduce this with 3.2.2?
Comment 2 Frantisek Hanzlik 2009-04-04 09:33:13 UTC
(In reply to comment #1)
> Can you reproduce this with 3.2.2?
> 

I can not, sorry. Although this machine is still working in same SW versions and configuration, it isn't no longer accessible for me.
Comment 3 Karolin Seeger 2009-05-13 04:49:31 UTC
Any ideas on this one?
Comment 4 Guenther Deschner 2009-08-06 10:58:07 UTC
Looking into this one.
Comment 5 Frantisek Hanzlik 2009-08-06 19:50:06 UTC
I have not access to machine with this bug, and I will not in future either, nor I'm able simulate this environment. Then, and because here are much newer samba versions, is IMO best solution close this bug.
Comment 6 maurizio.faccio 2012-06-27 13:25:54 UTC
Created attachment 7672 [details]
Win98 log level 6, printing from redirector
Comment 7 maurizio.faccio 2012-06-27 13:35:51 UTC
(In reply to comment #6)
> Created attachment 7672 [details]

I confirm that this bug exist on  3.5.10-0.109.el5_8 samba version, but as I try only affects Win98 redirector.

XP Dos windows redirections through 
net use lpt1 \\server\printer 

C:\dir > LPT1
Works fine

----
But on windows 98 is not working.
Win98 Dos windows redirections through 

net use lpt1 \\server\printer 
Doing 
C:\dir > LPT1
Gaves an error (i have spanish Win98 version)
"No se ha encontrado la ruta de acceso". Something like "Path not found"

Doing 
C:\dir > \\server\printer 
Works fine 


With samba 3.0.33-0.30.el4 all redirections works fine in both OS.


I attach log of printing from Win98
Comment 8 Björn Jacke 2018-03-27 22:41:14 UTC
this one is interesting:

[2012/06/27 09:48:29.626396,  3] smbd/vfs.c:936(check_reduced_name)
  check_reduce_named: couldn't get realpath for DEV/LPT1 (NT_STATUS_OBJECT_PATH_NOT_FOUND)

I don't have a dos client here to test but a web search gives another interesting hit:

https://green-possum-today.blogspot.de/2013/10/dos-622-printing-to-samba-fails-with.html

it suggests to simply "ln -s . DEV" in the samba spool directory as the DOS client tries to create LPT1 in the "DEV" directory here.

Interesting workaround, why did that work with 3.0.33?

Anybody using DOS printing with recent samba 4.x version?