Comment 2 for bug 1019662

Revision history for this message
Brian Candler (b-candler) wrote : Re: foomatic pdf jobs stopped, bash error

Additional info: OSX client shows "/usr/lib/cups/filter/foomatic-rip failed" and "Error: job stopped on server"

On the server, running "strace -s 2048 -v -f -p <pid of cups> 2>log" before submitting the job, I captured the following:

...
[pid 16670] execve("/bin/bash", ["/bin/bash", "-c", "pdftops '78' 'brian' 'test.pdf' '1' ' AP_ColorMatchingMode=AP_ApplicationColorMatching AP_D_InputSlot= nocollate com.apple.print.DocumentTicket.PMSpoolFormat=application/pdf com.apple.print.JobInfo.PMApplicationName=Preview com.apple.print.JobInfo.PMJobName=test.pdf com.apple.print.JobInfo.PMJobOwner=Brian\\ Candler com.apple.print.PageToPaperMappingMediaName=A4 com.apple.print.PageToPaperMappingType..n.=1 com.apple.print.PrinterInfo.PMColorDeviceID..n.=9784 com.apple.print.PrintSettings.PMColorMatchingMode..n.=0 com.apple.print.PrintSettings.PMColorSpaceModel..n.=1 com.apple.print.PrintSettings.PMColorSyncProfileID..n.=1580 com.apple.print.PrintSettings.PMCopies..n.=1 com.apple.print.PrintSettings.PMCopyCollate..b. com.apple.print.PrintSettings.PMDestinationType..n.=1 com.apple.print.PrintSettings.PMFirstPage..n.=1 com.apple.print.PrintSettings.PMLastPage..n.=2147483647 com.apple.print.PrintSettings.PMPageRange..a.0..n.=1 com.apple.print.PrintSettings.PMPageRange..a.1..n.=2147483647 com.apple.print.PrintSett"], ["CUPS_CACHEDIR=/var/cache/cups", "CUPS_DATADIR=/usr/share/cups", "CUPS_DOCROOT=/usr/share/cups/doc-root", "CUPS_FONTPATH=/usr/share/cups/fonts", "CUPS_REQUESTROOT=/var/spool/cups", "CUPS_SERVERBIN=/usr/lib/cups", "CUPS_SERVERROOT=/etc/cups", "CUPS_STATEDIR=/var/run/cups", "HOME=/var/spool/cups/tmp", "PATH=/usr/lib/cups/filter:/usr/bin:/usr/sbin:/bin:/usr/bin", "SERVER_ADMIN=root@zino", "SOFTWARE=CUPS/1.5.3", "TMPDIR=/var/spool/cups/tmp", "USER=root", "CUPS_SERVER=/var/run/cups/cups.sock", "CUPS_ENCRYPTION=IfRequested", "IPP_PORT=631", "CHARSET=utf-8", "LANG=en_US.UTF-8", "PPD=/etc/cups/ppd/HP-LaserJet-1020.ppd", "RIP_MAX_CACHE=128m", "CONTENT_TYPE=application/pdf", "DEVICE_URI=hp:/usb/HP_LaserJet_1020?serial=JL3FLCA", "PRINTER_INFO=Hewlett-Packard HP LaserJet 1020", "PRINTER_LOCATION=zino", "PRINTER=HP-LaserJet-1020", "PRINTER_STATE_REASONS=none", "CUPS_FILETYPE=document", "FINAL_CONTENT_TYPE=printer/HP-LaserJet-1020", "AUTH_INFO_REQUIRED=none", "GS_LIB=/usr/share/cups/fonts"] <unfinished ...>

The length of the string "pdftops '78' ...... com.apple.print.PrintSett" is exactly 1024 bytes, not including the outside double-quotes, so it looks like some fixed-sized internal buffer has been hit on the job properties.

(Aside: quite why a shell is being used here, rather than execve of pdftops directly, is unclear to me)