PE_HEADER_MACHINE_I386 wrong for Xp64 printerdrivers on samba-3.0.21-rc1? Re: XP64 Driver Installation Problem

Hansjörg Maurer Hansjoerg.Maurer at dlr.de
Tue Nov 22 07:17:27 GMT 2005


Hi

sorry, that I reply to my own mail :-)

I now seem to have found the problem,
why the 64 bit XP Postscript printer driver is not working correctly
under samba 3.0.21rc1
(see below).

A level 5 debug shows

  Admin opened file x64/3/pscript5.dll read=Yes write=No (numopen=1)
[2005/11/22 07:39:35, 3] printing/nt_printing.c:get_file_version(1055)
  get_file_version: PE file [x64/3/pscript5.dll] wrong machine = 0x8664
[2005/11/22 07:39:35, 2] smbd/close.c:close_normal_file(279)

in the source code mentiond above  I found
        if (SVAL(buf,PE_HEADER_MACHINE_OFFSET) != PE_HEADER_MACHINE_I386) {
            DEBUG(3,("get_file_version: PE file [%s] wrong machine =
0x%x\n",
                    fname, SVAL(buf,PE_HEADER_MACHINE_OFFSET)));
            /* At this point, we assume the file is in error. It still
could be somthing
             * else besides a PE file, but it unlikely at this point.
             */
            goto error_exit;
        }

which seems to be not correct for 64-bit drivers

I am not familiar with binary files :-)
so my own possibility to solve the problem would be to comment out the
source from above.

But maybe someone could add PE_HEADER_MACHINE_X64 check ore someting else...

I put the driver files under
ftp://ftp.dlr.de/robotic/outgoing/maurer/64-Bit.zip
if someone want to try to solve the problem

Let me know, if you need further information
Greetings from munich

Hansjörg

PS: I have submitted Bug #3275 concerning the problem




Hansjörg Maurer schrieb:

>Hi
>
>I have finally managed to install one 64 bit driver with rpcclient
>command on samba 3.0.21-rc1
>
>I put the files to /var/lib/samba/printers/x64
>and installed them with
>rpcclient  -U Admin -c 'adddriver "Windows x64"
>"PDFprinter:pscript5.dll:PDFprinter.ppd:ps5ui.dll:pscript.hlp:NULL:RAW:pscript.ntf"' 
>localhost
>
>rpcclient -U Admin -c 'enumdrivers 3' localhost
>shows the driver
>
>[Windows x64]
>Printer Driver Info 3:
>        Version: [3]
>        Driver Name: [PDFprinter]
>        Architecture: [Windows x64]
>        Driver Path: [\\\\LOCALHOST\print$\x64\3\pscript5.dll]
>        Datafile: [\\\\LOCALHOST\print$\x64\3\PDFprinter.ppd]
>        Configfile: [\\\\LOCALHOST\print$\x64\3\ps5ui.dll]
>        Helpfile: [\\\\LOCALHOST\print$\x64\3\pscript.hlp]
>
>        Dependentfiles: [\\\\LOCALHOST\print$\x64\3\pscript.ntf]
>
>        Monitorname: []
>        Defaultdatatype: [RAW]
>
> rpcclient -U Admin -c 'setdriver PDFprinter PDFprinter' localhost
>
>works fine to.
>
>But it I want to install a second printer, or this one again, entering
>the same command I get:
>
> rpcclient  -U Admin -c 'adddriver "Windows x64"
>"PDFprinter:pscript5.dll:PDFprinter.ppd:ps5ui.dll:pscript.hlp:NULL:RAW:pscript.ntf"' 
>localhost
>Password:
>result was WERR_UNKNOWN_PRINTER_DRIVER
>
>I am able to remove the printer with
>rpcclient -U Admin -c 'deldriverex PDFprinter "Windows x64"' localhost
>
>and the installation works fine again.
>
>But I am unable to install more then one printers.
>
>If you need some debug information or the 64 bit ps driver files in
>order to test it, let me know.
>
>Greetings
>
>Hansjörg
>
>
>
>
>
>
>
>Gerald (Jerry) Carter schrieb:
>
>  
>
>>Hansjörg Maurer wrote:
>>| Hi
>>|
>>| I am using samba as a windows printserver with cups ,cupsaddsmb and the
>>| microsoft postscript driver.
>>| Now we have the first XP64 workstation in our network, and they are
>>| unable to download the 32 bit
>>| PS-Driver.
>>|
>>| How do I configure samba to serve the 64-bit drivers as well
>>
>>Thi s was fixed in 3.0.20b IIRC.  You need to add an 'x64'
>>subdirectory to [prnit$] and upload the drivers as usual.
>>
>>
>>
>>
>>
>>
>>cheers, jerry
>>    
>>
>
>
>  
>

-- 
_________________________________________________________________

Dr.  Hansjoerg Maurer           | LAN- & System-Manager
                                |
Deutsches Zentrum               | DLR Oberpfaffenhofen
  f. Luft- und Raumfahrt e.V.   |
Institut f. Robotik             |
Postfach 1116                   | Muenchner Strasse 20
82230 Wessling                  | 82234 Wessling
Germany                         |
                                |
Tel: 08153/28-2431              | E-mail: Hansjoerg.Maurer at dlr.de
Fax: 08153/28-1134              | WWW: http://www.robotic.dlr.de/
__________________________________________________________________


There are 10 types of people in this world, 
those who understand binary and those who don't.



More information about the samba-technical mailing list