<div><br></div>Thanks, i will add priority and see the results.<div><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On 29 November 2012 17:00, Danny Nicholas <span dir="ltr"><<a href="mailto:danny@debsinc.com" target="_blank">danny@debsinc.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div lang="EN-US" link="blue" vlink="purple"><div><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Priority is a required parameter. In your call file you are telling Asterisk to <u></u><u></u></span></p>
<p class="MsoNormal"></p><div class="im">> Channel: DAHDI/g0/0312xxxxxxx<br>> MaxRetries: 0<br>> RetryTime: 60<br>> Context: asteriskgw_fax<br>> Extension: s<br></div><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Go to context asteriskgw_fax, extension s. Priority tells Asterisk where to start in asteriskgw_fax. Since C would assume 0 and contexts start with 1, priority: 1 tells it to go to line 1. Another use for this would be to tell Asterisk to start further down to skip a wait or something.<u></u><u></u></span><p>
</p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Sample:<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">[asteriskgw_fax]<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Exten => s,1,answer()<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Exten => s,n,wait(5)<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Exten => s,n,playback(sending-fax)<u></u><u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">You could use priority 1 for DAHDI to compensate for PSTN delays and priority 3 for SIP calls.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> <a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-bounces@lists.digium.com</a> [mailto:<a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-bounces@lists.digium.com</a>] <b>On Behalf Of </b>Necati Demir<br>
<b>Sent:</b> Thursday, November 29, 2012 8:50 AM<br><b>To:</b> Asterisk Users Mailing List - Non-Commercial Discussion<br><b>Subject:</b> Re: [asterisk-users] Disappearing Call Files / Two threads dealing with my call files<u></u><u></u></span></p>
<div><div class="h5"><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal"><u></u> <u></u></p></div><p class="MsoNormal">Should I use priority in call files? How the lack of priority causes this problem?<u></u><u></u></p>
<div><p class="MsoNormal" style="margin-bottom:12.0pt"><u></u> <u></u></p><div><p class="MsoNormal">On 29 November 2012 12:48, Matt Riddell (lists) <<a href="mailto:lists@venturevoip.com" target="_blank">lists@venturevoip.com</a>> wrote:<u></u><u></u></p>
<p class="MsoNormal">There's no priority in your call file.<br><br>Sent from my iPhone<u></u><u></u></p><div><div><p class="MsoNormal"><br>On 29/11/2012, at 11:12 PM, Necati Demir <<a href="mailto:ndemir@demir.web.tr" target="_blank">ndemir@demir.web.tr</a>> wrote:<br>
<br>> Hello,<br>><br>> I noticed that when i move a call file to outgoing directory, two asterisk threads are dealing with it.<br>><br>> ]# grep FAX_44731.call /var/log/asterisk/full.2<br>><br>> [Nov 27 09:23:10] WARNING[26842] pbx_spool.c: Unable to set utime on /var/spool/asterisk/outgoing/FAX_44731.call: Operation not permitted<br>
> [Nov 27 09:23:25] VERBOSE[18852] pbx.c: -- Executing [s@asteriskgw_fax:1] System("DAHDI/i1/0312xxxxxxx-b08", "echo "Set: UNIQUEID=1354000990.39861" >> /var/spool/asterisk/outgoing/FAX_44731.call") in new stack<br>
> [Nov 27 09:25:33] VERBOSE[18852] pbx.c: -- Executing [s@asteriskgw_fax:3] System("DAHDI/i1/0312xxxxxxx-b08", "echo "Set: FAXSTATUS=SUCCESS" >> /var/spool/asterisk/outgoing/FAX_44731.call") in new stack<br>
> [Nov 27 09:25:33] WARNING[26842] pbx_spool.c: At least one of app or extension must be specified, along with tech and dest in file /var/spool/asterisk/outgoing/FAX_44731.call<br>> [Nov 27 09:25:33] WARNING[26842] pbx_spool.c: Invalid file contents in /var/spool/asterisk/outgoing/FAX_44731.call, deleting<br>
><br>> As you see there are two thread dealing with my call file. Now let's inspect the thread 18852.<br>><br>> ]# grep "\[18852\]" /var/log/asterisk/full.2<br>> [Nov 27 09:23:10] VERBOSE[18852] pbx_spool.c: -- Attempting call on DAHDI/g0/0312xxxxxxx for s@asteriskgw_fax:1 (Retry 1)<br>
> [Nov 27 09:23:10] DEBUG[18852] sig_pri.c: sig_pri_request 5<br>> [Nov 27 09:23:10] DEBUG[18852] sig_pri.c: CALLER NAME: NUM: 90312xxxxxxx<br>> [Nov 27 09:23:10] VERBOSE[18852] sig_pri.c: -- Requested transfer capability: 0x00 - SPEECH<br>
> [Nov 27 09:23:25] VERBOSE[18852] pbx.c: -- Executing [s@asteriskgw_fax:1] System("DAHDI/i1/0312xxxxxxx-b08", "echo "Set: UNIQUEID=1354000990.39861" >> /var/spool/asterisk/outgoing/FAX_44731.call") in new stack<br>
> [Nov 27 09:23:25] VERBOSE[18852] pbx.c: -- Executing [s@asteriskgw_fax:2] SendFAX("DAHDI/i1/0312xxxxxxx-b08", "/tmp/Qg90Ox5YGF5kYkJu.tif,zdfs") in new stack<br>> [Nov 27 09:23:25] VERBOSE[18852] res_fax.c: -- Channel 'DAHDI/i1/0312xxxxxxx-b08' sending FAX:<br>
> [Nov 27 09:23:25] VERBOSE[18852] res_fax.c: -- /tmp/Qg90Ox5YGF5kYkJu.tif<br>> [Nov 27 09:25:33] VERBOSE[18852] pbx.c: -- Executing [s@asteriskgw_fax:3] System("DAHDI/i1/0312xxxxxxx-b08", "echo "Set: FAXSTATUS=SUCCESS" >> /var/spool/asterisk/outgoing/FAX_44731.call") in new stack<br>
> [Nov 27 09:25:33] VERBOSE[18852] pbx.c: -- Auto fallthrough, channel 'DAHDI/i1/0312xxxxxxx-b08' status is 'UNKNOWN'<br>> [Nov 27 09:25:33] VERBOSE[18852] chan_dahdi.c: -- Hungup 'DAHDI/i1/0312xxxxxxx-b08'<br>
> [Nov 27 09:25:33] NOTICE[18852] pbx_spool.c: Call completed to DAHDI/g0/0312xxxxxxx<br>><br>> It seems that the thread 18852 executes it normally but the thread 26842 deletes my call file. And when I inspected the asterisk log file, i saw that the thread 26842 is deleting all my call files.<br>
><br>> Here is my custom_extensions.conf file:<br>><br>> [asteriskgw_fax]<br>> exten => s,1,System(echo "Set: UNIQUEID=${CDR(uniqueid)}" >> /var/spool/asterisk/outgoing/FAX_${ID}.call)<br>
> exten => s,2,SendFAX(${FAXFILE},zdfs)<br>> exten => s,3,System(echo "Set: FAXSTATUS=${FAXSTATUS}" >> /var/spool/asterisk/outgoing/FAX_${ID}.call)<br>><br>> And here is a sample of call file:<br>
><br>> Channel: DAHDI/g0/0312xxxxxxx<br>> MaxRetries: 0<br>> RetryTime: 60<br>> Context: asteriskgw_fax<br>> Extension: s<br>> Set: FAXFILE=/tmp/8Mg3yihXahZVejDf.tif<br>> Set: ID=44884<br>> Callerid: 90312xxxxxxx<br>
> Archive: Yes<br>><br>><br>><br>> --<br>> Necati DEMİR<br>> --------------------<u></u><u></u></p></div></div><p class="MsoNormal">> --<br>> _____________________________________________________________________<br>
> -- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>> New to Asterisk? Join us for a live introductory webinar every Thurs:<br>> <a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
><br>> asterisk-users mailing list<br>> To UNSUBSCRIBE or update options visit:<br>> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>
<br>--<br>_____________________________________________________________________<br>-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br><br>asterisk-users mailing list<br>To UNSUBSCRIBE or update options visit:<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><u></u><u></u></p>
</div><p class="MsoNormal"><br><br clear="all"><u></u><u></u></p><div><p class="MsoNormal"><u></u> <u></u></p></div><p class="MsoNormal">-- <br>Necati DEMİR<br>--------------------<u></u><u></u></p></div></div></div></div>
</div><br>--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Necati DEMİR<br>
--------------------<br>
</div>