Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Our customer has a Linux server (Redhat), which runs Java web applications. Recently there is a requirement to submit PDF files to printers to be printed out.

The command we are using is cat /path/to/pdf_file | acroread -toPostScript | lp -dprintername. But we are getting the error lp: stdin is empty; so no job has been sent.

Printing a normal file, such as /etc/hosts, using this command lp -dprintername /etc/hosts works, and we can see the printout at the printer. The lp command is not the problem.

The I proceeded to test the other 2 commands cat /path/to/pdf_file | acroread -toPostScript and I saw the output Segmentation fault.

To further troubleshoot this issue, I used the strace command like so cat /pdf_file | strace -f -o /tmp/acroread.$$.trace acroread -toPostScript. From the trace file, I saw these lines before the segmentation fault happened.

stat64("/home/oracle/.adobe", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
16673 stat64("/home/oracle/.adobe/Acrobat", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
16673 stat64("/home/oracle/.adobe/Acrobat/9.0", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
16673 stat64("/home/oracle/.adobe/Acrobat/9.0/Temp", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
16673 open("/home/oracle/.adobe/Acrobat/9.0/Temp/AdobeTempPS7XwXNz", O_RDWR|O_CREAT|O_EXCL, 0600) = 4
16673 close(4)                          = 0
16673 unlink("/home/oracle/.adobe/Acrobat/9.0/Temp/AdobeTempPS7XwXNz") = 0
16673 open("/home/oracle/.adobe/Acrobat/9.0/Temp/AdobeTempPS7XwXNz", O_RDWR|O_CREAT|O_TRUNC, 0666) = 4
16673 getcwd("/var/spool/mail"..., 1024) = 16
16673 open("/home/oracle/.adobe/Acrobat/9.0/Temp/AdobeTempPS7XwXNz", O_RDONLY) = 5
16673 --- SIGSEGV (Segmentation fault) @ 0 (0) ---
16673 +++ killed by SIGSEGV +++
16720 <... waitpid resumed> 0x3, WNOHANG|WCONTINUED|0x7410) = 0

When I did an listing of the /home/oracle/.adobe/Acrobat/9.0/Temp/ directory, all the files are zero byte size.

So, my question is what could have caused the segmentation fault? Is it a bug in this version of Acrobat Reader?

The Acrobat Reader version installed is 9.4.

The RedHat version is Red Hat Enterprise Linux Server release 5.7 (Tikanga). The kernel is Linux SCHPOAPS1 2.6.18-274.el5 #1 SMP Fri Jul 8 17:36:59 EDT x86_64 GNU/Linux.

share|improve this question
    
lp? What old version of Red Hat is this? –  Michael Hampton Aug 12 '13 at 13:52
    
I have updated the question with the redhat and kernel version. –  Alvin Sim Aug 13 '13 at 2:25

2 Answers 2

up vote 0 down vote accepted

We fixed this by removing the current Acrobat Reader (ver 9.4), and installing a higher version one (9.5.5).

share|improve this answer

I think, that it is acroread problem, when it want to open file /home/oracle/.adobe/Acrobat/9.0/Temp/AdobeTempPS7XwXNz twice.

Can you use pdf2ps instead of acroread?

share|improve this answer
    
If there are no other solutions, we might give this a try. Thanks. –  Alvin Sim Aug 13 '13 at 9:24

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.