Bug 10342 - Windows 7 x86/x64 HP Universal Print Driver PCL5/PCL6/PS 5.7.0.16448 (Explorer.exe Crash)
Windows 7 x86/x64 HP Universal Print Driver PCL5/PCL6/PS 5.7.0.16448 (Explore...
Status: RESOLVED FIXED
Product: Samba 3.6
Classification: Unclassified
Component: Printing
3.6.22
All All
: P5 normal
: ---
Assigned To: printing-maintainers
Samba QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-12-23 17:42 UTC by Sean Ryan
Modified: 2014-04-04 20:05 UTC (History)
0 users

See Also:


Attachments
This is a packet capture between the client and the server. (60 bytes, text/plain)
2013-12-30 15:29 UTC, Sean Ryan
no flags Details
Samba Debug logs (57 bytes, text/plain)
2013-12-30 19:54 UTC, Sean Ryan
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sean Ryan 2013-12-23 17:42:10 UTC
I share my network printers via Samba/CUPS,and I use the Point n' Print method to deploy my drivers.  I'm able to upload, download, and print without issue, but I first have to go through 5 repeated steps to get the HP printer (4515X) working correctly.  This issue happens with any HP Model, and with any Samba version from 3.6.3 - 3.6.22 

Here are the x86 drivers (PCL5,PCL6,PS):

http://h20566.www2.hp.com/portal/site/hpsc/template.PAGE/public/psi/swdHome/?sp4ts.oid=3558895&spf_p.tpst=swdMain&spf_p.prp_swdMain=wsrp-navigationalState%3DswEnvOID%253D4062%257CswLang%253D%257Caction%253DlistDriver&javax.portlet.begCacheTok=com.vignette.cachetoken&javax.portlet.endCacheTok=com.vignette.cachetoken

Here are the x64 drivers (PCL5,PCL6,PS): 

http://h20566.www2.hp.com/portal/site/hpsc/template.PAGE/public/psi/swdHome/?sp4ts.oid=3558895&spf_p.tpst=swdMain&spf_p.prp_swdMain=wsrp-navigationalState%3DswEnvOID%253D4063%257CswLang%253D%257Caction%253DlistDriver&javax.portlet.begCacheTok=com.vignette.cachetoken&javax.portlet.endCacheTok=com.vignette.cachetoken

You can do the following to reproduce the bug:

1. Upload the print drivers above using the Point n Print method found here:

https://wiki.samba.org/index.php/Samba_as_a_print_server

2. Double Click on the Shared printer to download the driver(s) via: \\netbiosnameofsambaserver\printersharedname- *You can use any version of Windows 7 (x86/x64) UPD driver (PCL5,PCL6,PS)*

3. Right click on the shared printer you just added to your Windows 7 (x86/x64) client machine and go to the shared Printer Properties. (You can go to the Start Button > Up to the White Box > type in:control printers to view your shared printers)

At this point you'll be prompted with a Window that states Windows Explorer has stopped working with the following error:

Problem signature:
  Problem Event Name:	APPCRASH
  Application Name:	explorer.exe
  Application Version:	6.1.7601.17514
  Application Timestamp:	4ce796f3
  Fault Module Name:	StackHash_4bf7
  Fault Module Version:	6.1.7601.17514
  Fault Module Timestamp:	4ce7b96e
  Exception Code:	c0000374
  Exception Offset:	000c37b7
  OS Version:	6.1.7601.2.1.0.256.48
  Locale ID:	1033
  Additional Information 1:	4bf7
  Additional Information 2:	4bf705bea7df585593172a57b64e2ae7
  Additional Information 3:	eaab
  Additional Information 4:	eaab105c2d1b7b999c3c8ee3ddee4c8e

Read our privacy statement online:
  http://go.microsoft.com/fwlink/?linkid=104288&clcid=0x0409

If the online privacy statement is not available, please read our privacy statement offline:
  C:\Windows\system32\en-US\erofflps.txt

The Printer Properties dialog will fail repeatedly until the 5th time.  Then it works as normal. 

I also have a Canon printer (iR ADV 5235) shared and it works without error using the following drivers(PS3_v21.05_INF.zip 9/19/13) for x86, or x64): 

http://www.usa.canon.com/cusa/office/products/hardware/multifunction_printers_copiers/imageRUNNER_ADVANCE_Series_Models/imagerunner_advance_c5235#DriversAndSoftware


Contents of smb.conf:

[global]
  workgroup = DOMAIN
  server string = Samba OpenDJ PDC on %m
  netbios name = domaincontroller-00
  security = user
  encrypt passwords = true

  ########
  # CUPS #
  ########

  printcap name = cups
  printing = cups

  ##########
  # DOMAIN #
  ##########
  domain logons = Yes
  os level = 64
  preferred master = Yes
  domain master = Yes
  local master = Yes
  # avoid home and logon
  logon home =
  logon path =

  ########
  # LDAP #
  ########
  passdb backend = ldapsam:ldap://127.0.0.1:389
  ldap ssl = Off
  invalid users = root
  ldap admin dn = cn=djadmin,dc=acr,dc=lab
  ldap suffix = dc=acr,dc=lab
  ldap group suffix = ou=groups
  ldap user suffix = ou=users
  ldap machine suffix = ou=machines
  ldap passwd sync = Yes

  # scripts ldap
  # by default we add users to group "mydomain"
  add machine script = /usr/sbin/ldapaddmachine '%u' domainmachines
  add user script = /usr/sbin/ldapadduser '%u' domainusers
  add group script = /usr/sbin/ldapaddgroup '%g'
  add user to group script = /usr/sbin/ldapaddusertogroup '%u' '%g'
  delete user script = /usr/sbin/ldapdeleteuser '%u'
  delete group script = /usr/sbin/ldapdeletegroup '%g'
  delete user from group script = /usr/sbin/ldapdeleteuserfromgroup '%u' '%g'
  set primary group script = /usr/sbin/ldapsetprimarygroup '%u' '%g'

  ########
  # ACLS #
  ########
  map acl inherit = yes
  nt acl support = yes

  ########
  # LOGS #
  ########
  debug = 10
  log file = /var/log/samba/log.%m
  max log size = 10000
  panic action = echo %d  | mail -s "an error occured with samba" samba@domain.lab

  ##########
  #  MISC  #
  ##########
  socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
  # message command = /bin/sh -c '/usr/bin/linpopup "%f" "%m" %s; rm %s' &
  
  # logon script located in netlogon share
  logon script = allusers.bat
  # individual logon scripts uncomment
  # logon script = %U.bat
  
  ###############
  # Print Share #
  ###############

  [print$]
  comment = Printer Drivers
  path = /var/lib/samba/printers
  browseable = yes
  guest ok = yes
  read only = no

#  Examples. Be sure to match the name of the printer [NAME] with the cups name
  [HP_4515X]
  comment = cups printer
  printer = HP_4515X
  path = /var/spool/samba
  printable = yes
  guest ok = yes

  [CANON_C5235]
  comment = cups printer
  printer = CANON_C5235
  path = /var/spool/samba
  printable = yes
  guest ok = yes  

  #################
  # Logon Scripts #
  #################

  [netlogon]
    comment = Network Logon Services
    read only = yes
    write list = +domainadmins 
    path = /var/lib/samba/netlogon

  ###############
  # File Shares #
  ###############

  [homes]
    comment = %m Samba shared home folders
    browseable = no
    writeable = yes
    path = /home/%u
    
  [shared]
    comment = common shared folder
    public = yes
    writeable = yes
    path = /opt/smb 

Contents of log.clientmachine after the 5th (successful try):

[2013/12/23 11:57:02.020674,  0] rpc_server/spoolss/srv_spoolss_nt.c:1748(_spoolss_OpenPrinterEx)
  _spoolss_OpenPrinterEx: Cannot open a printer handle for printer \\domaincontroller-00
[2013/12/23 11:57:02.116568,  0] rpc_server/spoolss/srv_spoolss_nt.c:1748(_spoolss_OpenPrinterEx)
  _spoolss_OpenPrinterEx: Cannot open a printer handle for printer \\domaincontroller-00
[2013/12/23 11:57:03.467910,  0] rpc_server/spoolss/srv_spoolss_nt.c:1748(_spoolss_OpenPrinterEx)
  _spoolss_OpenPrinterEx: Cannot open a printer handle for printer \\domaincontroller-00
[2013/12/23 11:57:03.486940,  0] rpc_server/spoolss/srv_spoolss_nt.c:1748(_spoolss_OpenPrinterEx)
  _spoolss_OpenPrinterEx: Cannot open a printer handle for printer \\domaincontroller-00

There are no other logs generated in the process of trying to view the printer properties in the following files:

logs.smbd
log.nmbd
log.IPADDRESSOFCLIENT
Comment 1 Sean Ryan 2013-12-30 15:29:46 UTC
Created attachment 9551 [details]
This is a packet capture between the client and the server.

Server = 192.168.30.10
Client = 192.168.30.51
Shared Printer = HP_4515X

The files "failure1-4" are generated when I right click on the shared printer of "HP_4515X" on my client and go to "Printer Properties" which then causes Windows x86, or Windows x64 client using any driver (PCL5/PCL6/PS) to cause explorer.exe crash 4 times in a row.  After I try to view the "Printer Properties" on the 5th time everything works as normal.  

It seems as though the client does not request the XcvPort Samba Printer Port until the 5th time.
Comment 2 Sean Ryan 2013-12-30 19:54:36 UTC
Created attachment 9552 [details]
Samba Debug logs
Comment 3 Sean Ryan 2014-02-17 16:58:18 UTC
ping!
Comment 4 Sean Ryan 2014-03-04 21:14:23 UTC
(In reply to comment #3)
> ping!

Is anyone actually reading these reports?
Comment 5 Sean Ryan 2014-03-17 20:44:25 UTC
HP updated their PS and PCL6 drivers to the following version:

5.8.0.17508 (31 Jan 2014)

I can now view the "Printer Properties" using either PS, or PCL6 drivers.
Comment 6 Andreas Schneider 2014-04-04 12:25:02 UTC
I can't see why we are responsible for crashes in Windows.

So after updating the Driver it is fixed now?
Comment 7 Sean Ryan 2014-04-04 19:52:19 UTC
(In reply to comment #6)
> I can't see why we are responsible for crashes in Windows.
> 
> So after updating the Driver it is fixed now?

Yes its fixed now.  The printer driver that I used earlier, when used with *samba* as a shared printer caused my windows boxes to crash.  I even replicated the bug. Your bug guidelines state the following "No bug is too trivial to report - small bugs may hide big bugs" Silly me for thinking this might be a good place to post this bug.
Comment 8 Jeremy Allison 2014-04-04 20:05:53 UTC
Sorry for your bad experience. Yes, no bug is too small to not report.

Glad it's working now !

Jeremy.