HylaFAX The world's most advanced open source fax server

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [hylafax-users] sendfax sometimes hangs, can't identify protocol?



(Sorry I made some stupid errors, this is my message without the errors)

The server is very busy today, and I already have a new hanging sendfax
process now. I hangs almost an hour now, and I guess it will never
finish anymore:

uucp     26875  0.0  0.1   4152  1664 ?        S    11:42   0:00
/usr/bin/sendfax -m -T 3 -I 300 -n -k now + 3 days -P 128 -f
xxxxxx@xxxxxxxxxxxxx -d 084xxxxxxx 92726.pdf

This is the strace:

strace -p26875
Process 26875 attached - interrupt to quit
read(3,

Under normal circumstances the last line becomes something like

read(3, "200 Job 118161 submitted.\r\n", 1024) = 27
etc...

And here is the strace of the corresponding hfaxd process:

strace -p26876
Process 26876 attached - interrupt to quit
select(5, [0 4], [], [], NULL

Which under normal circumstances becomes something like

select(5, [0 4], [], [], NULL)          = 1 (in [4])
read(4, "S*\0", 2047)                   = 3
read(4, 0xbfb03500, 2047)               = -1 EAGAIN (Resource
temporarily unavailable)
write(1, "200 Job 119050 submitted.\r\n", 27) = 27
fcntl64(0, F_SETFL, O_RDWR|O_NONBLOCK)  = 0
etc...

I also notice that adding faxes to the queue (using sendfax) is always
very slow when the queue is long (7000+ faxes). It becomes so slow that
the queue never becomes bigger than +/- 8000 faxes. At that point adding
faxes to the queue (from my perl loop) goes at the same speed as the
sending of the faxes itself using 60 phone lines. In the past this
problem was even worse, until I set MaxBatchJobs to 1. I don't know why
adding faxes is still slow now when the queue is long. When I do a
strace on those slow processes, they hang for some seconds (or longer)
at the same point as the straces above. Apparently sometimes these slow
processes are not only slow, but hang forever. Slow processes are no
problem, but the faxes should be sent at some point, and not hang forever.

I hope you can help me with this problem. Please let me know if you need
more information.

Best regards,
Mark

Lee Howard wrote:
Can you attach an strace to the hung sendfax?

Lee.


Mark Hunting wrote:


Yes it only happens when the server is very busy sending faxes (and adding faxes to the queue). Under normal circumstances this problem never seems to appear.

Mark

Lee Howard wrote:

I doubt that the "can't identify protocol" means anything significant here.

The question is why has hfaxd communication failed, and why is the communication port still open endlessly.

You say that this only happens when you send a lot of faxes (25,000) all at once?

Lee.


Mark Hunting wrote:


Hi,

I manage a Hylafax server with 60 phone lines (2x ISDN30). It works very well, but sometimes a sendfax process hangs forever. You'll understand I'm looking for a solution to this problem.

The problem only seems to appear when lots of faxes are inserted at the same time. For example sometimes sendfax is called 25000 times from a loop in a Perl script. Once in a while one or two sendfax processes will hang, instead of sending the fax. It hangs for days, untill I kill the sendfax process manually. The hanging processes are not always the ones that are called from within the Perl loop, but the problem only seems to occur when the server is busy perfoming such a loop.

For example I now have this hanging process (from 4 days ago):

uucp 29579 0.0 0.0 5368 1948 ? S May03 0:00 /usr/bin/sendfax -m -T 3 -I 300 -n -k now + 3 days -P 128 -f xxxxxx@xxxxxxxxxxxxxx -d 003323xxxxxxx /var/spool/hylafax/html_files//parsed_mail_body-29509-1.ps

A list of open files gives:
lsof|grep 29579
sendfax 29579 uucp cwd DIR 8,1 0 228042 /home/faxapp/tmp/temp.1178183572.29509.0qCVob12eOakIXT (deleted)
sendfax 29579 uucp rtd DIR 8,1 4096 2 /
sendfax 29579 uucp txt REG 8,7 21276 16847 /usr/bin/sendfax
sendfax 29579 uucp mem REG 0,0 0 [heap] (stat: No such file or directory)
sendfax 29579 uucp mem REG 8,1 34320 114732 /lib/tls/i686/cmov/libnss_nis-2.3.6.so
sendfax 29579 uucp mem REG 8,1 76548 114727 /lib/tls/i686/cmov/libnsl-2.3.6.so
sendfax 29579 uucp mem REG 8,1 30428 114728 /lib/tls/i686/cmov/libnss_compat-2.3.6.so
sendfax 29579 uucp mem REG 8,1 38372 114730 /lib/tls/i686/cmov/libnss_files-2.3.6.so
sendfax 29579 uucp mem REG 8,7 1209120 402847 /usr/lib/locale/locale-archive
sendfax 29579 uucp mem REG 8,7 127488 404846 /usr/lib/libjpeg.so.62.0.0
sendfax 29579 uucp mem REG 8,1 9592 114724 /lib/tls/i686/cmov/libdl-2.3.6.so
sendfax 29579 uucp mem REG 8,1 1241392 114721 /lib/tls/i686/cmov/libc-2.3.6.so
sendfax 29579 uucp mem REG 8,1 41096 97837 /lib/libgcc_s.so.1
sendfax 29579 uucp mem REG 8,1 145136 114725 /lib/tls/i686/cmov/libm-2.3.6.so
sendfax 29579 uucp mem REG 8,7 909044 402640 /usr/lib/libstdc++.so.6.0.8
sendfax 29579 uucp mem REG 8,1 9656 114740 /lib/tls/i686/cmov/libutil-2.3.6.so
sendfax 29579 uucp mem REG 8,1 21868 114723 /lib/tls/i686/cmov/libcrypt-2.3.6.so
sendfax 29579 uucp mem REG 8,7 78500 402404 /usr/lib/libz.so.1.2.3
sendfax 29579 uucp mem REG 8,7 343712 404848 /usr/lib/libtiff.so.4.2.1
sendfax 29579 uucp mem REG 8,1 29700 97815 /lib/libpam.so.0.79
sendfax 29579 uucp mem REG 8,7 462292 404879 /usr/lib/hylafax/libfaxutil.so.4.3.1
sendfax 29579 uucp mem REG 8,1 88164 97730 /lib/ld-2.3.6.so
sendfax 29579 uucp 0r REG 8,8 5443 17641436 /var/spool/qmail/mess/22/17641436
sendfax 29579 uucp 1w FIFO 0,6 10039767 pipe
sendfax 29579 uucp 2w FIFO 0,6 10039603 pipe
sendfax 29579 uucp 3u IPv4 10039771 TCP localhost:44692->localhost:hylafax (ESTABLISHED)
sendfax 29579 uucp 4u sock 0,5 10039613 can't identify protocol
sendfax 29579 uucp 5u IPv4 10039771 TCP localhost:44692->localhost:hylafax (ESTABLISHED)


Can the 'can't identify protocol' line maybe be the problem? And if it is, what can I do about it?

I use HylaFAX 4.3.1, on a Debian 4.0 server (i686, kernel 2.6.18). I'm using two Eicon Diva Server PRI cards, with a brand new beta driver (provided by Eicon). But I also had this problem on another Debian server with a 2.6.17 kernel and an older, officially released, Eicon driver.

Thanks a lot,
Mark




____________________ HylaFAX(tm) Users Mailing List _______________________
To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null
*To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*





____________________ HylaFAX(tm) Users Mailing List _______________________
To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null
*To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*






____________________ HylaFAX(tm) Users Mailing List _______________________
To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null
*To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*




____________________ HylaFAX(tm) Users Mailing List _______________________
 To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null
 *To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*




Project hosted by iFAX Solutions