Re: [asterisk-users] Follow-me to my answering machine :-(
On 29/04/10 2:00 PM, Bryan Jacobs wrote: > This is fine, except that it imposes a delay on connecting my call. If > I were to do steps 1&2 simultaneously, then my cell phone being off > would stop the phones in step #1 from working. If you play a message telling someone that you are being located, surely they'd prefer this delay than to not get hold of you? If you can't dial DTMF in your car, then there's really no other option - unless of course you can hum two tones at the same time :) I'd just call the sip phones etc, then play a message saying "Please hold while you are transferred to my cell number". -- Cheers, Matt Riddell Managing Director ___ http://www.venturevoip.com/news.php (Daily Asterisk News) http://www.venturevoip.com/exchange.php (Full ITSP Solution) http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer) -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] Issue with (pattern) matching extension
Here's a segment of my dialplan, I'm working on the freenum/ISN functionality: same => n,Set(isnresult=${ENUMLOOKUP(${EXTEN},sip,,1,freenum.org)}) same => n,GotoIf($["${isnresult}" != ""]?:fn-CONGESTION,1) ; set up our outgoing call state same => n,Set(SIPFROMUSER=${CALLERID(num)}) same => n,GotoIf($["${GLOBAL(FREENUMDOMAIN)}" == ""]?dial:) same => n,Set(SIPFROMDOMAIN=${GLOBAL(FREENUMDOMAIN)}) same => n(dial),Dial(SIP/${isnresult},40) same => n,Goto(fn-${DIALSTATUS},1) exten => fn-BUSY,1,Busy() exten => _fn-.,1,NoOp(ISN: ${DIALSTATUS}) same => n,Congestion() and the logging: == ast_get_enum(num='555*9', tech='sip', suffix='freenum.org', options='', record=1 == ENUM options(): pos=1, options='2' == ISN ENUM: left=555, middle='9.' == ast_get_enum() profiling: FAIL, 5.5.5.9.freenum.org, 21 ms -- Executing [555*99...@outbound-freenum2:5] Set("SIP/guest_1-0010", "isnresult=") in new stack -- Executing [555*99...@outbound-freenum2:6] GotoIf("SIP/guest_1-0010", "0?:fn-CONGESTION,1") in new stack -- Goto (outbound-freenum2,fn-CONGESTION,1) [Apr 28 16:55:22] WARNING[5987]: pbx.c:4358 __ast_pbx_run: Channel 'SIP/guest_1-0010' sent into invalid extension 'fn-CONGESTION' in context 'outbound-freenum2', but no invalid handler pbx*CLI> Note that the string "fn-CONGESTION" isn't matching the extension pattern: exten => _fn-.,1,NoOp(ISN: ${DIALSTATUS}) and I'm not sure why. Anyone want to venture how to go about figuring out how? -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] No change in payload. (SDP)
re-posting the question. --- use case: when some one in my pbx calls 100.200, I have translations well defined, Media also (media via asterisk) --Works. when some one calls bob, or for any names I am adding Domain and call is been sent to the other party -- Works, no media... For the cases when it is talking to the external work, I want Astersik not to do anything with the SDP/payload. I want it to send as it is to the external proxy. How can I achieve this? so that the SDP/payload will not be modified for users talking to the external world. I want media for those external devices to come Directly to the users in my pbx. (with out going t asterisk) 2) also related question is can I have the xml payload in the originator and call is routed via PBX to the Target. The xml payload also must be carried to the target. is it possible This will really help me as I was held up with this :( -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Follow-me to my answering machine :-(
Matt, What I think you're suggesting is: 1. followme(SIP phones, etc) - WAIT X SECONDS 2. if (!answered) { call(Cellphone) } This is fine, except that it imposes a delay on connecting my call. If I were to do steps 1&2 simultaneously, then my cell phone being off would stop the phones in step #1 from working. I can't "just call the car" - the car is my cell phone DID with a bluetooth kit. Bryan Jacobs On Thu, 29 Apr 2010 13:29:32 +1200 Matt Riddell wrote: > On 23/04/10 10:31 AM, Bryan Jacobs wrote: > > Don, > > > > No, I'm not trying to say there's a problem with generating the > > tones. The issue is that my phone is still holstered, connected to > > the car via Bluetooth. I have steering-wheel buttons for receiving > > calls and hanging up, but I don't have a safe way to press buttons. > > Why not just use followme for everything but the car, and if that > fails, send the call to the car normally? > signature.asc Description: PGP signature -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] Duplicated DTMF with bridged IAX channels maybe?
Hi, I have a duplicated DTMF issue with, it appears, bridged IAX channels. I have the following setup: PRI IAX <>* PSTN <--->* Dialplan I've configured a number on the dialplan server to make and outbound call to the pstn. This call then comes back into the dialplan server to SayDigits(). I'm seeing that a few of my digits are being duplicated every so often. I've attached an IAX trace from the PSTN server to this message where you can see the duplication (digits 9 & 3). The digits entered were 258963. Thank you. -- James [Apr 28 18:43:42] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 005 ISeqno: 004 Type: DTMF_B Subclass: 2 [Apr 28 18:43:42] VERBOSE[2806] logger.c:Timestamp: 14504ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:42] VERBOSE[2799] logger.c: Rx-Frame Retry[ No] -- OSeqno: 005 ISeqno: 004 Type: DTMF_B Subclass: 2 [Apr 28 18:43:42] VERBOSE[2799] logger.c:Timestamp: 14504ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] -- [Apr 28 18:43:42] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 008 ISeqno: 007 Type: DTMF_B Subclass: 2 [Apr 28 18:43:42] VERBOSE[2806] logger.c:Timestamp: 13363ms SCall: 09503 DCall: 09749 [208.90.184.3:4569] -- [Apr 28 18:43:42] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 006 ISeqno: 004 Type: DTMF_E Subclass: 2 [Apr 28 18:43:42] VERBOSE[2806] logger.c:Timestamp: 14828ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:42] VERBOSE[2799] logger.c: Rx-Frame Retry[ No] -- OSeqno: 006 ISeqno: 004 Type: DTMF_E Subclass: 2 [Apr 28 18:43:42] VERBOSE[2799] logger.c:Timestamp: 14828ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] -- [Apr 28 18:43:42] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 009 ISeqno: 007 Type: DTMF_E Subclass: 2 [Apr 28 18:43:42] VERBOSE[2806] logger.c:Timestamp: 13700ms SCall: 09503 DCall: 09749 [208.90.184.3:4569] -- [Apr 28 18:43:43] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 007 ISeqno: 004 Type: DTMF_B Subclass: 5 [Apr 28 18:43:43] VERBOSE[2806] logger.c:Timestamp: 15263ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:43] VERBOSE[2797] logger.c: Rx-Frame Retry[ No] -- OSeqno: 007 ISeqno: 004 Type: DTMF_B Subclass: 5 [Apr 28 18:43:43] VERBOSE[2797] logger.c:Timestamp: 15263ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] -- [Apr 28 18:43:43] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 010 ISeqno: 007 Type: DTMF_B Subclass: 5 [Apr 28 18:43:43] VERBOSE[2806] logger.c:Timestamp: 14103ms SCall: 09503 DCall: 09749 [208.90.184.3:4569] -- [Apr 28 18:43:43] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 008 ISeqno: 004 Type: DTMF_E Subclass: 5 [Apr 28 18:43:43] VERBOSE[2806] logger.c:Timestamp: 15613ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:43] VERBOSE[2798] logger.c: Rx-Frame Retry[ No] -- OSeqno: 008 ISeqno: 004 Type: DTMF_E Subclass: 5 [Apr 28 18:43:43] VERBOSE[2798] logger.c:Timestamp: 15613ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] -- [Apr 28 18:43:43] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 011 ISeqno: 007 Type: DTMF_E Subclass: 5 [Apr 28 18:43:43] VERBOSE[2806] logger.c:Timestamp: 14460ms SCall: 09503 DCall: 09749 [208.90.184.3:4569] -- [Apr 28 18:43:43] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 009 ISeqno: 004 Type: DTMF_B Subclass: 8 [Apr 28 18:43:43] VERBOSE[2806] logger.c:Timestamp: 15983ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:43] VERBOSE[2799] logger.c: Rx-Frame Retry[ No] -- OSeqno: 009 ISeqno: 004 Type: DTMF_B Subclass: 8 [Apr 28 18:43:43] VERBOSE[2799] logger.c:Timestamp: 15983ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] -- [Apr 28 18:43:43] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 012 ISeqno: 007 Type: DTMF_B Subclass: 8 [Apr 28 18:43:43] VERBOSE[2806] logger.c:Timestamp: 14823ms SCall: 09503 DCall: 09749 [208.90.184.3:4569] -- [Apr 28 18:43:44] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 010 ISeqno: 004 Type: DTMF_E Subclass: 8 [Apr 28 18:43:44] VERBOSE[2806] logger.c:Timestamp: 16351ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:44] VERBOSE[2804] logger.c: Rx-Frame Retry[ No] -- OSeqno: 010 ISeqno: 004 Type: DTMF_E Subclass: 8 [Apr 28 18:43:44] VERBOSE[2804] logger.c:Timestamp: 16351ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] -- [Apr 28 18:43:44] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 013 ISeqno: 007 Type: DTMF_E Subclass: 8 [Apr 28 18:43:44] VERBOSE[2806] logger.c:Timestamp: 15200ms SCall: 09503 DCall: 09749 [208.90.184.3:4569] -- [Apr 28 18:43:44] VERBOSE[2806] logger.c: Tx-Frame Retry[000] -- OSeqno: 011 ISeqno: 004 Type: DTMF_B Subclass: 9 [Apr 28 18:43:44] VERBOSE[2806] logger.c:Timestamp: 16763ms SCall: 12052 DCall: 04642 [208.90.184.4:4569] [Apr 28 18:43:44] VERBOSE[2801] logger.c: Rx-Frame Retry[ No] -- OSeqno: 011 ISeqno: 004 Type: DTMF_B S
Re: [asterisk-users] Installing For AsteirskAddon
On 27/04/10 7:33 PM, 675842709 wrote: > when i install asterisk addon ,i got error here > chan_ooh323.c:1934: error: dereferencing pointer to incomplete type > chan_ooh323.c:1935: error: dereferencing pointer to incomplete type > chan_ooh323.c:1937: error: dereferencing pointer to incomplete type > chan_ooh323.c:1938: error: dereferencing pointer to incomplete type > chan_ooh323.c:1940: error: dereferencing pointer to incomplete type > chan_ooh323.c:1943: error: dereferencing pointer to incomplete type Do you need OpenH.323? If not, run make menuconfig and disable it -- Cheers, Matt Riddell Managing Director ___ http://www.venturevoip.com/news.php (Daily Asterisk News) http://www.venturevoip.com/exchange.php (Full ITSP Solution) http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer) -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] RTP over TCP
On 25/04/10 7:00 AM, bruce bruce wrote: > Adobe Air and Adobe FMS are good examples of VoIP working flawlessly > over TCP. We are actually developing a flash phone which needs only TCP > to transmit both signal and audio. Ok, let's look at that (UDP vs TCP for realtime stream). Let's call the sender A and the received B. UDP === A sends packet 1 to B. Arrives ok. No problem A sends packet 2 to B. Doesn't arrive. No problem (dropped packet) A sends packet 3 to B. Doesn't arrive. No problem (dropped packet) A sends packet 4 to B. Arrives ok. No problem TCP === A sends packet 1 to B. Arrives ok. No problem A sends packet 2 to B. Doesn't arrive. TCP starts retransmit A sends packet 3 to B. Doesn't arrive. TCP starts retransmit A sends packet 2 to B. Arrives but is now 20ms too late (dropped packet) A sends packet 4 to B. Arrives ok. No problem A sends packet 3 to B. Arrives but is now 20ms too late (dropped packet) So, in the worst state of the network (when packets aren't getting though), TCP is sending even more data than is required for the actual conversation. And it's doing this at a time when the network is struggling. If we assume that there is a jitter buffer on B which is throwing away packets which are out of order then it's going to somewhat improve the situation. If it's not then it's going to be a disaster! Most of the flash based conferencing solutions (voice/video) I've used have all had the same problem (increasing delay and over utilisation of bandwidth). The reason people are using TCP for this is because flash doesn't allow you to do it with UDP. However, IIRC Adobe is working on a UDP based protocol for exchanging real time data and this should resolve the situation. If there is a great multiplexing video conferencing app which uses flash (or similar) that you can recommend, I'd love to know about it! Moral of the story: UDP is designed for realtime traffic or data where timing is more important than accuracy TCP is designed for important data (i.e. where accuracy is more important than timing) -- Cheers, Matt Riddell Managing Director ___ http://www.venturevoip.com/news.php (Daily Asterisk News) http://www.venturevoip.com/exchange.php (Full ITSP Solution) http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer) -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Follow-me to my answering machine :-(
On 23/04/10 10:31 AM, Bryan Jacobs wrote: > Don, > > No, I'm not trying to say there's a problem with generating the tones. > The issue is that my phone is still holstered, connected to the car via > Bluetooth. I have steering-wheel buttons for receiving calls and > hanging up, but I don't have a safe way to press buttons. Why not just use followme for everything but the car, and if that fails, send the call to the car normally? -- Cheers, Matt Riddell Managing Director ___ http://www.venturevoip.com/news.php (Daily Asterisk News) http://www.venturevoip.com/exchange.php (Full ITSP Solution) http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer) -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] BN8S0, dahdi, wcb4xxp
Am Mittwoch, 28. April 2010 16:21:44 schrieben Sie: > On Wed, Apr 28, 2010 at 03:56:04PM +0200, Claire Sinn wrote: > > Am Mittwoch, 28. April 2010 09:58:14 schrieb Tzafrir Cohen: > > > On Wed, Apr 28, 2010 at 07:12:57AM +0200, Claire Sinn wrote: > > > > Hi, > > > > > > > > a few month ago, I tried to install zaptel for my Beronet BN8S0 pci > > > > card... I gave up and took hfcmulti/lcr. Now dahdi (2.2.1.1) seems to > > > > support the card and I'm very interested to get it to work. > > > > But how to get rid of these annoying qozap driver? > > > > > > > > bishop dahdi # lspci -v -nn -s 01:00.0 > > > > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN > > > > network Controller [HFC-8S] [1397:16b8] (rev 01) > > > > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > > > > Flags: medium devsel, IRQ 21 > > > > I/O ports at 9480 [size=8] > > > > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > > > > Capabilities: [40] Power Management version 2 > > > > Kernel modules: wcb4xxp, hfcmulti > > > > > > > > bishop dahdi # modprobe wcb4xxp > > > > bishop dahdi # lspci -v -nn -s 01:00.0 > > > > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN > > > > network Controller [HFC-8S] [1397:16b8] (rev 01) > > > > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > > > > Flags: medium devsel, IRQ 21 > > > > I/O ports at 9480 [size=8] > > > > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > > > > Capabilities: [40] Power Management version 2 > > > > Kernel driver in use: wcb4xxp > > > > Kernel modules: wcb4xxp, hfcmulti > > > > > > > > bishop dahdi # dahdi_hardware -v > > > > driver should be 'qozap' but is actually 'wcb4xxp' > > > > pci::01:00.0 qozap+ 1397:16b8 Junghanns OctoBRI ISDN > > > > card > > > > > > Seems like the list of devices in Dahdi::Hardware::PCI is not > > > up-to-date. > > > > I tried to ignore the output of dahdi_hardware, but it seems to be more > > than a cosmetic problem. The half of the ports are jumpered for TE mode > > (port 1,2,7 and 8) and they work fine. The remaining ports are jumpered > > for NT use and produce a RED alarm. > > > > bishop asterisk # grep wcb4xxp /var/log/kern.log |tail -n 14 > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: probe called for > > b4xx... Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: PCI INT A -> > > GSI 21 (level, low) -> IRQ 21 > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Identified BeroNet > > BN8S0 (controller rev 1) at 00019480, IRQ 21 > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: NOTE: hardware echo > > cancellation has been disabled > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 1: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 2: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 3: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 4: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 5: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 6: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 7: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 8: TE mode > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Did not do the > > highestorder stuff > > Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: new card sync > > source: port 3 > > > > Can I force wcb4xxp to configure some ports in NT mode? > > Clairef > > I suspect this should be easy to fix. Any chance you can try it with the > SVN version? > > Try test: > > svn checkout http://svn.digium.com/svn/dahdi/linux/trunk dahdi-linux > cd dahdi-linux > make # but don't install > > The following must be run as root: > > # Unload existing drivers (you may also want to stop asterisk first: > /etc/init.d/dahdi stop > # load local drivers: > modprobe crc-ccitt # just in case it's not yet loaded > insmod ./drivers/dahdi/dahdi.ko > insmod ./drivers/dahdi/wcb4xxp/wcb4xxp.ko > > I suspect this won't fix the issue, but it will shorten the test cycle. > Mission accomplished. crc-ccitt is compiled into the kernel, but not as a module. bishop dahdi-linux # dahdi_hardware -v driver should be 'qozap' but is actually 'wcb4xxp' pci::01:00.0 qozap+ 1397:16b8 Junghanns OctoBRI ISDN card Where is the difference? C.e -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Strange Error -- ASterisk 1.6
Danny Nicholas wrote: We've been here, done this; This is a 1.6 NEW and Specific message to tell you that Asterisk can't start it's canary-monitor thread and that under certain conditions, you might be about to lock up. Look through the earlier posts in April. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Seann Clark Sent: Wednesday, April 28, 2010 2:30 PM To: asterisk-users@lists.digium.com Subject: [asterisk-users] Strange Error -- ASterisk 1.6 All, I just noticed this in my logs, and am rather lost as to what module it pertains to. I would assume pseudo-realtime priority for the process, but I am looking for a little confirmation from the group: [Apr 28 12:28:36] WARNING[20773] asterisk.c: The canary is no more. He has ceased to be! He's expired and gone to meet his maker! He's a stiff! Bereft of life, he rests in peace. His metabolic processes are now history! He's off the twig! He's kicked the bucket. He's shuffled off his mortal coil, run down the curtain, and joined the bleeding choir invisible!! THIS is an EX-CANARY. (Reducing priority) Thanks, Seann Danny, Thanks for that response, it gave me just enough to confirm my idea. I can't find the stuff in the earlier threads (yet) but as i have a lot to shuffle through, and see what else I can find from it. Once again, thank you. Regards, Seann smime.p7s Description: S/MIME Cryptographic Signature -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] Strange Error -- ASterisk 1.6
All, I just noticed this in my logs, and am rather lost as to what module it pertains to. I would assume pseudo-realtime priority for the process, but I am looking for a little confirmation from the group: [Apr 28 12:28:36] WARNING[20773] asterisk.c: The canary is no more. He has ceased to be! He's expired and gone to meet his maker! He's a stiff! Bereft of life, he rests in peace. His metabolic processes are now history! He's off the twig! He's kicked the bucket. He's shuffled off his mortal coil, run down the curtain, and joined the bleeding choir invisible!! THIS is an EX-CANARY. (Reducing priority) Thanks, Seann smime.p7s Description: S/MIME Cryptographic Signature -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Strange Error -- ASterisk 1.6
We've been here, done this; This is a 1.6 NEW and Specific message to tell you that Asterisk can't start it's canary-monitor thread and that under certain conditions, you might be about to lock up. Look through the earlier posts in April. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Seann Clark Sent: Wednesday, April 28, 2010 2:30 PM To: asterisk-users@lists.digium.com Subject: [asterisk-users] Strange Error -- ASterisk 1.6 All, I just noticed this in my logs, and am rather lost as to what module it pertains to. I would assume pseudo-realtime priority for the process, but I am looking for a little confirmation from the group: [Apr 28 12:28:36] WARNING[20773] asterisk.c: The canary is no more. He has ceased to be! He's expired and gone to meet his maker! He's a stiff! Bereft of life, he rests in peace. His metabolic processes are now history! He's off the twig! He's kicked the bucket. He's shuffled off his mortal coil, run down the curtain, and joined the bleeding choir invisible!! THIS is an EX-CANARY. (Reducing priority) Thanks, Seann -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dial plan question.
On Tue, Apr 27, 2010 at 8:48 PM, Aditya Kumar wrote: > Hi All, > > pl help me with this basic question. > > I have a users (soft clients) with usernames having Alphabetics. > I want to use Asterisk as my server. > > How should I have the dial plans as there are no numbers involved . > so How can I make the configuration to work ( with numbers I can get this > done using extensions.conf) > > my expected result is : > al...@pbx.com should be able to call b...@pbx.com > where pbx.com is astersik. > > Can you pl let me know how I can achieve this? > > You would need to setup each user in sip.conf like so: [alice] type=friend context=alpha-names fromuser=alice secret=password domain=pbx.com [bob] type=friend context=alpha-names fromuser=bob secret=password domain=pbx.com etc etc.. Then in your extensions.conf, you would setup: [alpha-names] ; Dial by name exten => alice,1,Verbose(Calling alice) exten => alice,n,Dial(SIP/alice,20) exten => alice,n,Hangup() exten => bob,1,Verbose(Calling bob) exten => bob,n,Dial(SIP/bob,20) exten => bob,n,Hangup() etc etc. You could also use pattern matching in your extensions.conf like this: [alpha-names] ;Dial by name, pattern matching exten => _.,1,Verbose(Calling ${EXTEN}) exten => _.,n,Dial(SIP/${EXTEN},20) exten => _.,n,Hangup() except that's going to catch everything, including the built-in 'h', 'i', and 't' extensions (you can look these up on voip-info.org for more info on those). Configure each of your softphone clients with the usernames you defined in your sip.conf (i.e the softphone on Alice's computer would have a username of alice, password of password, and domain of pbx.com, using the asterisk server as your registrar / proxy server address, same with Bob's softphone). Your softphone has to allow alpha dialing from contacts though. You haven't mentioned which softphone you're using, if you do that we may be able to give you specifics for that softphone as well. -- Thanks, --Warren Selby http://www.selbytech.com -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dial plan question.
Thanks a lot Jim and Ryan. It worked with changing the order as you suggested. -- Few more questions on Dial plan: use case: when some one in my pbx calls 100.200, I have translations well defined, Media also (media via asterisk) --Works. when some one calls bob, or for any names I am adding Domain and call is been sent to the other party -- Works, no media... For the cases when it is talking to the external work, I want Astersik not to do anything with the SDP/payload. I want it to send as it is to the external proxy. How can I achieve this? so that the SDP/payload will not be modified for users talking to the external world. I want media for those external devices to come Directly to the users in my pbx. Do you mean you want exten => bob,1,Dial(SIP/ext-sip/${EXTEN},20) You want to call out via sip user ext-sip to that system's extension bob? -- Jim Dickenson mailto:dicken...@cfmc.com CfMC http://www.cfmc.com/ -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dial plan question.
Try: exten => bob,1,Dial(SIP/ext-sip/${EXTEN},20) ? -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dial plan question.
Do you mean you want exten => bob,1,Dial(SIP/ext-sip/${EXTEN},20) You want to call out via sip user ext-sip to that system's extension bob? -- Jim Dickenson mailto:dicken...@cfmc.com CfMC http://www.cfmc.com/ On Apr 28, 2010, at 10:50 AM, Aditya Kumar wrote: > Thanks Steve, I corrected spelling that but still having issue :-) > > Issue: > when some one calls bob, I want asterisk to add @DOMAIN and make the call. > but it is not working . > -- > Config files: > sip.conf > [ext-sip] > type=friend > context=phones > qualify=yes > host=external.proxy.com > > extensions.conf > exten => bob,1,Dial(SIP/${ext...@ext-sip,20) > > the call is not working, > log says: > chan_sip.c:5344 create_addr:no such host: ext-sip > app_dail.c:1745 unable to create channel of type 'SIP' (cause 20-unknown) > > > can u please correct me what I am missing > From: Steve Howes > To: Asterisk Users Mailing List - Non-Commercial Discussion > > Sent: Wed, April 28, 2010 12:57:54 AM > Subject: Re: [asterisk-users] Dial plan question. > > > On 28 Apr 2010, at 06:53, Aditya Kumar wrote: > > > exten => bob,1,Dial(SIP/${exte...@ext-sip,20) > > > Where did you define EXTERN? > > S > > -- > _ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > > -- > _ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dial plan question.
Thanks Steve, I corrected spelling that but still having issue :-) Issue: when some one calls bob, I want asterisk to add @DOMAIN and make the call. but it is not working . -- Config files: sip.conf [ext-sip] type=friend context=phones qualify=yes host=external.proxy.com extensions.conf exten => bob,1,Dial(SIP/${ext...@ext-sip,20) the call is not working, log says: chan_sip.c:5344 create_addr:no such host: ext-sip app_dail.c:1745 unable to create channel of type 'SIP' (cause 20-unknown) can u please correct me what I am missing From: Steve Howes To: Asterisk Users Mailing List - Non-Commercial Discussion Sent: Wed, April 28, 2010 12:57:54 AM Subject: Re: [asterisk-users] Dial plan question. On 28 Apr 2010, at 06:53, Aditya Kumar wrote: > exten => bob,1,Dial(SIP/${exte...@ext-sip,20) Where did you define EXTERN? S -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] simple dialplan question
It seems to me that you're doing this the "hard way". How about this: [context] exten => _.,1,Set(GROUP()=1) exten => _.,n,Goto(${EXTEN},1) exten => sipprovider.nocredit,1,NoOp(No credit left) If I'm wrong (happens every once in a while), Google Asterisk 302 redirect. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Vieri Sent: Wednesday, April 28, 2010 12:14 PM To: asterisk-users@lists.digium.com Subject: [asterisk-users] simple dialplan question Sorry for the simple question. I'm trying to match "sipprovider.nocredit" but the following doesn't execute NoOp (it runs "context" but not "context-custom"). What am I doing wrong? [context] include => context-custom exten => _.,1,Set(GROUP()=1) exten => _.,n,Goto(destcontext,${EXTEN},1) [context-custom] exten => sipprovider.nocredit,1,NoOp(No credit left) Thanks Vieri -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] sip jitter buffer
Hi, Does enabling a jitter buffer in sip.conf make sense if the call is pure SIP? -- I think it should help on the Asterisk receiving side in case of unreliable bandwidth. Vieri -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
On Apr 28, 2010, at 1:12 PM, Steve Edwards wrote: > On Wed, 28 Apr 2010, Fred Posner wrote: > >> Did I miss where the code was posted? > > Yes. In my mail reader it is Gareth's second post. > Thanks. Wish I hadn't looked now. --fred http://qxork.com -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] simple dialplan question
Sorry for the simple question. I'm trying to match "sipprovider.nocredit" but the following doesn't execute NoOp (it runs "context" but not "context-custom"). What am I doing wrong? [context] include => context-custom exten => _.,1,Set(GROUP()=1) exten => _.,n,Goto(destcontext,${EXTEN},1) [context-custom] exten => sipprovider.nocredit,1,NoOp(No credit left) Thanks Vieri -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
On Wed, 28 Apr 2010, Fred Posner wrote: > Did I miss where the code was posted? Yes. In my mail reader it is Gareth's second post. -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
On Apr 28, 2010, at 1:00 PM, Gareth Blades wrote: > Steve Edwards wrote: >>> Steve Edwards wrote: How do you reconcile your assumption that the Perl module is reading STDIN and your statement that your AGI "quits before asterisk has finished sending the information about the current call via STDIN." >> >> On Wed, 28 Apr 2010, Gareth Blades wrote: >> >>> Only that if I put a 3 second pause in the script at the end then I get >>> no errors. If I put in a 1 second pause I get errors about half way >>> through asterisk sending the input. >> >> The fact that you have to introduce a pause means that you are doing >> something wrong. It may just mean that Asterisk has finished writing the >> cruft to the created process's STDIN instead of being interrupted in the >> middle, but whatever you are doing is still wrong. >> >> There is an outside chance that you have discovered a bug in Asterisk, but >> considering nobody else has experienced this behavior implies the bug is >> in your code. >> >> Why are you so resistant to this? What evidence do you have that your code >> is correct? >> > > I am not resistant to it. I didnt write the code and I an not that > familiar with perl. > > It just seemed strange that the debug output from the mode-start script > run appeared instantly on the screen but for the other AGI code > executions I could see the debug output scroll up slowly. Did I miss where the code was posted? ---fred http://qxork.com -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Steve Edwards wrote: >> Steve Edwards wrote: >>> How do you reconcile your assumption that the Perl module is reading >>> STDIN and your statement that your AGI "quits before asterisk has >>> finished sending the information about the current call via STDIN." > > On Wed, 28 Apr 2010, Gareth Blades wrote: > >> Only that if I put a 3 second pause in the script at the end then I get >> no errors. If I put in a 1 second pause I get errors about half way >> through asterisk sending the input. > > The fact that you have to introduce a pause means that you are doing > something wrong. It may just mean that Asterisk has finished writing the > cruft to the created process's STDIN instead of being interrupted in the > middle, but whatever you are doing is still wrong. > > There is an outside chance that you have discovered a bug in Asterisk, but > considering nobody else has experienced this behavior implies the bug is > in your code. > > Why are you so resistant to this? What evidence do you have that your code > is correct? > I am not resistant to it. I didnt write the code and I an not that familiar with perl. It just seemed strange that the debug output from the mode-start script run appeared instantly on the screen but for the other AGI code executions I could see the debug output scroll up slowly. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
> Steve Edwards wrote: >> >> How do you reconcile your assumption that the Perl module is reading >> STDIN and your statement that your AGI "quits before asterisk has >> finished sending the information about the current call via STDIN." On Wed, 28 Apr 2010, Gareth Blades wrote: > Only that if I put a 3 second pause in the script at the end then I get > no errors. If I put in a 1 second pause I get errors about half way > through asterisk sending the input. The fact that you have to introduce a pause means that you are doing something wrong. It may just mean that Asterisk has finished writing the cruft to the created process's STDIN instead of being interrupted in the middle, but whatever you are doing is still wrong. There is an outside chance that you have discovered a bug in Asterisk, but considering nobody else has experienced this behavior implies the bug is in your code. Why are you so resistant to this? What evidence do you have that your code is correct? -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Steve Edwards wrote: >>> On Wed, 28 Apr 2010, Gareth Blades wrote: > The script does not issue any commands. The same script is called at all 3 stages but with different parameters on the command line to indicate the call status. Works fine before the call is answered but during and at the end of the call it quits before asterisk has finished sending the information about the current call via STDIN. > >> Steve Edwards wrote: > >>> Asterisk sends the "AGI environment" to the AGI via STDIN. If you don't >>> read it, you are violating the protocol. > > On Wed, 28 Apr 2010, Gareth Blades wrote: > >> We are reading in the STDIN (assume its part of the asterisk perl >> module). If I add a 3 second pause to the end of the perl code then it >> works fine. But if this is the case then for a system with a high call >> volume this significantly increases the number of running AGI programs >> which is not good for system load. > > How do you reconcile your assumption that the Perl module is reading STDIN > and your statement that your AGI "quits before asterisk has finished > sending the information about the current call via STDIN." > Only that if I put a 3 second pause in the script at the end then I get no errors. If I put in a 1 second pause I get errors about half way through asterisk sending the input. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
On Wed, 28 Apr 2010, Ryan Bullock wrote: > Looking at the Asterisk::AGI docs, maybe try calling ReadParse() early > in the script to read in anything from stdin? > > (From the docs) > # pull AGI variables into %input > %input = $AGI->ReadParse(); "early" == "before (any interaction with Asterisk || exit)" -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] dialplan
Hi: Thanks for your answer. i tried your suggestion (exten => _..,1,Noop) but it didnt work ,i think (_..) is wrong formula to mean that number contains those coz asterisk didnt matched the call with extension , is there any other formula? i will write down wht i want to exactly to do : a call come from outside when it came with a number contains like (009615552) it will give him congestion ,and if it came up with number doesnt have those it will pass to another extension ,this is sample about wht i want exactly but i wrote it in simple way coz i dont know other than this to try . exten => _..,1,Congestion exten => _00.,1,Dial,Dahdi/1/${EXTEN} --- On Wed, 4/28/10, Jim Dickenson wrote: From: Jim Dickenson Subject: Re: [asterisk-users] dialplan To: "Asterisk Users Mailing List - Non-Commercial Discussion" Date: Wednesday, April 28, 2010, 1:10 PM Are talking about something like exten => _..,1,Noop(Have in this extension) There is also this function that can be used to look for sub strings inside a string. core show function REGEX -= Info about function 'REGEX' =- [Syntax] REGEX("" ) [Synopsis] Regular Expression [Description] Returns 1 if data matches regular expression, or 0 otherwise. Please note that the space following the double quotes separating the regex from the data is optional and if present, is skipped. If a space is desired at the beginning of the data, then put two spaces there; the second will not be skipped. -- Jim Dickenson mailto:dicken...@cfmc.com CfMC http://www.cfmc.com/ On Apr 28, 2010, at 5:49 AM, wassim darwich wrote: Hi guys: i need to set an extension in my dialplan in which it divert calls if the extension contain specific series ,For example : I need to divert calls which contain to specific extension (contain ,not start or end with), as i know i should set Gotoif command but i dont know what to set after that,Any help will be appreciated. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -Inline Attachment Follows- -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
>> On Wed, 28 Apr 2010, Gareth Blades wrote: >>> The script does not issue any commands. The same script is called at >>> all 3 stages but with different parameters on the command line to >>> indicate the call status. Works fine before the call is answered but >>> during and at the end of the call it quits before asterisk has >>> finished sending the information about the current call via STDIN. > Steve Edwards wrote: >> Asterisk sends the "AGI environment" to the AGI via STDIN. If you don't >> read it, you are violating the protocol. On Wed, 28 Apr 2010, Gareth Blades wrote: > We are reading in the STDIN (assume its part of the asterisk perl > module). If I add a 3 second pause to the end of the perl code then it > works fine. But if this is the case then for a system with a high call > volume this significantly increases the number of running AGI programs > which is not good for system load. How do you reconcile your assumption that the Perl module is reading STDIN and your statement that your AGI "quits before asterisk has finished sending the information about the current call via STDIN." -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Gateway E1 <=> Asterisk ?
- "Luis Morales" wrote: > Redfone it's good! > > Redfone makes a nice gateway(they also have very good support), although it is TDMoE. The OP specifically mentioned they want a gateway which provides SIP connectivity. --Tim -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
FWIW, I would take your STDERR references and give them another handle, since you're not really trying to produce a CLI/Console output. The symptoms you have described in this thread are 100% compliant with "AGI protocol violation (their term not mine)" - the last suggest I would give you is to do an implicit AGI usage like this: my $agi; my %input; $agi = new Asterisk::AGI; %input = $agi->ReadParse(); -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades Sent: Wednesday, April 28, 2010 10:50 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script Danny Nicholas wrote: > Darn, that should have worked. The "improvement" from 1.4.22 to 1.4.23+ > basically requires that every "print STDOUT" line be followed by a > to make util.c not choke when doing commands/setting variables. I wonder > how this "rewrite" would work? > sub set_variable >{ > my ($self, %vars) = @_; > while (my($var,$val) = each %vars) >{ > if (!defined($val)) >{ warn "AGI->set_variable: not setting '$var' because value > was undef\n"; next; } > print STDOUT "SET VARIABLE $var \"$val\" \r\n"; > ; >} >} > I dont think that routine is the issue. Its only called when setting the variables and that is only done before the call is dialed and in that case the script generates no errors :- -- Executing [08454632...@service_nts_nextgen_v2:1] AGI("Zap/5-1", "service_nts_nextgen|mode=start|") in new stack -- Launched AGI Script /var/lib/asterisk/agi-bin/service_nts_nextgen AGI Tx >> agi_request: service_nts_nextgen AGI Tx >> agi_channel: Zap/5-1 AGI Tx >> agi_language: en AGI Tx >> agi_type: Zap AGI Tx >> agi_uniqueid: 1272469456.5 AGI Tx >> agi_callerid: 1276459900 AGI Tx >> agi_calleridname: unknown AGI Tx >> agi_callingpres: 1 AGI Tx >> agi_callingani2: 0 AGI Tx >> agi_callington: 33 AGI Tx >> agi_callingtns: 0 AGI Tx >> agi_dnid: 08454632504 AGI Tx >> agi_rdnis: unknown AGI Tx >> agi_context: service_nts_nextgen_v2 AGI Tx >> agi_extension: 08454632504 AGI Tx >> agi_priority: 1 AGI Tx >> agi_enhanced: 0.0 AGI Tx >> agi_accountcode: AGI Tx >> > AGI Rx << SET VARIABLE __item_count "0" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __custid "13361" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __dniascli "0" AGI Tx >> 200 result=1 AGI Rx << GET VARIABLE __cliorig AGI Tx >> 200 result=0 AGI Rx << VERBOSE "Route To Number: 447584255419" 1 service_nts_nextgen|mode=start|: Route To Number: 447584255419 AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_number_1 "07584255419" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_type_1 "number" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_type_id_1 "1" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_channel_1 "Zap/g1" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __numcarriers_1 "2" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_carrier_1_2 "PSTN:DEFAULT" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_number_1_2 "07584255419" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_channel_1_2 "Zap/g1" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_carrier_1_1 "SIP:MAGRATHEA" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_number_1_1 "07584255...@magrathea" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_channel_1_1 "SIP" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __item_count "1" AGI Tx >> 200 result=1 -- AGI Script service_nts_nextgen completed, returning 0 The problem is with where the mode is answered or completed when I get errors like this :- -- Executing [...@macro-service-nts-nextgenv2-register-answer:3] AGI("SIP/magrathea-0002", "service_nts_nextgen|mode=answered|1272469456.5|1272469457.6|07584255419|1|| SIP:MAGRATHEA|params=") in new stack -- Launched AGI Script /var/lib/asterisk/agi-bin/service_nts_nextgen AGI Tx >> agi_request: service_nts_nextgen AGI Tx >> agi_channel: SIP/magrathea-0002 AGI Tx >> agi_language: en AGI Tx >> agi_type: SIP AGI Tx >> agi_uniqueid: 1272469457.6 AGI Tx >> agi_callerid: 08454632504 AGI Tx >> agi_calleridname: unknown AGI Tx >> agi_callingpres: 0 AGI Tx >> agi_callingani2: 0 AGI Tx >> agi_callington: 33 AGI Tx >> agi_callingtns: 0 AGI Tx >> agi_dnid: unknown [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_rdnis: unknown [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_context: macro-service-nts-nextgenv2-register-answer [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_extension: s [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned erro
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Looking at the Asterisk::AGI docs, maybe try calling ReadParse() early in the script to read in anything from stdin? (From the docs) # pull AGI variables into %input %input = $AGI->ReadParse(); -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] asterisk core dumps after cdr database writes using odbc
Both of our production asterisk servers are dumping core when making writes to our cdr tables. Here is a backtrace of the problems we are having: #0 0x00447b1f in tdserror (tds_ctx=0x1, tds=0xb7938c90, msgno=20004, errnum=9) at util.c:347 347 if (tds_ctx && tds_ctx->err_handler) { (gdb) bt #0 0x00447b1f in tdserror (tds_ctx=0x1, tds=0xb7938c90, msgno=20004, errnum=9) at util.c:347 #1 0x0045c6d6 in goodread (tds=0xb7938c90, buf=0x2abb220 "¹\033F", buflen=8) at net.c:501 #2 0x0045c765 in tds_read_packet (tds=0xb7938c90) at net.c:567 #3 0x004496bf in tds_get_byte (tds=0xb7938c90) at read.c:76 #4 0x0044619f in tds_process_tokens (tds=0xb7938c90, result_type=0x2abb360, done_flags=0x2abb364, flag=26900) at token.c:509 #5 0x00432e7d in odbc_process_tokens (stmt=0xa3f3658, flag=26900) at odbc.c:3268 #6 0x0043736c in _SQLExecute (stmt=0xa3f3658) at odbc.c:3118 #7 0x00439561 in SQLExecDirect (hstmt=0xa3f3658, szSqlStr=0x2abb640 "INSERT INTO cdr (calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid,userfield) VALUES ({ts '2010-04-28 10:01:26'},?,?,?,?,?,?"..., cbSqlStr=-3) at odbc.c:3227 #8 0x00fa4263 in SQLExecDirect (statement_handle=0xa400250, statement_text=0x2abb640 "INSERT INTO cdr (calldate,clid,src,dst,dcontext,channel,dstchannel,lastapp,lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid,userfield) VALUES ({ts '2010-04-28 10:01:26'},?,?,?,?,?,?"..., text_length=-3) at SQLExecDirect.c:417 #9 0x009e5397 in execute_cb (obj=0xa2bc0c0, data=0xa4a7c88) at cdr_odbc.c:115 #10 0x003accf8 in ast_odbc_direct_execute (obj=0xa2bc0c0, exec_cb=0x9e4e00 , data=0xa4a7c88) at res_odbc.c:574 #11 0x009e55f1 in odbc_log (cdr=0xa4a7c88) at cdr_odbc.c:137 #12 0x0808db8a in post_cdr (cdr=0xa4a7c88) at cdr.c:1055 #13 0x0808e36e in ast_cdr_detach (cdr=0xa4a7c88) at cdr.c:1251 #14 0x080c042b in ast_bridge_call (chan=0xa52e8d0, peer=0xb79047a8, config=0x2abe1c0) at features.c:2849 #15 0x026285d9 in try_calling (qe=0x2abe6f0, options=Variable "options" is not available. ) at app_queue.c:4269 #16 0x0262d4a0 in queue_exec (chan=0xa52e8d0, data=0x2ac0a20) at app_queue.c:5204 #17 0x080f3c47 in pbx_exec (c=0xa52e8d0, app=0xb7c6b088, data=0x2ac0a20) at /usr/local/src/asterisk162/asterisk-1.6.2.0/include/asterisk/strings.h:64 #18 0x0810118f in pbx_extension_helper (c=0xa52e8d0, con=0x0, context=0xa52eb40 "macro-queue-call", exten=0xa52eb90 "s", priority=12, label=0x0, callerid=0xa2d2db8 "00", action=E_SPAWN, found=0x2ac2e0c, combined_find_spawn=1) at pbx.c:3708 #19 0x08101788 in ast_spawn_extension (c=0x1, context=0x472614 "$N", exten=0x472614 "$N", priority=4662804, callerid=0x472614 "$N", found=0x472614, combined_find_spawn=4662804) at pbx.c:4167 #20 0x00965387 in _macro_exec (chan=0xa52e8d0, data=0x2ac5f70, exclusive=0) at app_macro.c:398 #21 0x080f3c47 in pbx_exec (c=0xa52e8d0, app=0xb7c55740, data=0x2ac5f70) at /usr/local/src/asterisk162/asterisk-1.6.2.0/include/asterisk/strings.h:64 #22 0x0810118f in pbx_extension_helper (c=0xa52e8d0, con=0x0, context=0xa52eb40 "macro-queue-call", exten=0xa52eb90 "s", priority=3, label=0x0, callerid=0xa2d2db8 "00", action=E_SPAWN, found=0x2ac824c, combined_find_spawn=1) at pbx.c:3708 #23 0x0810850c in __ast_pbx_run (c=0xa52e8d0, args=0x0) at pbx.c:4167 #24 0x0810ae20 in pbx_thread (data=0xa52e8d0) at pbx.c:4544 #25 0x0814afd5 in dummy_start (data=0x472614) at utils.c:968 #26 0x007a43cc in start_thread () from /lib/tls/libpthread.so.0 #27 0x0061c1ae in clone () from /lib/tls/libc.so.6 Any help is appreciated. thanks -nathan -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Gateway E1 <=> Asterisk ?
Redfone it's good! On Wed, Apr 28, 2010 at 10:07 AM, Olivier CALVANO wrote: > Hi > > i want change my asterisk server. Actually, Asterisk work's on a IBM > Server with a internal digium E1 card. > For High availability, i don't want now use "internal E1" card. > In my new asterisk systems, i have two server and two E1 not in the same site. > > I am search a hardware gateway, if possible in 1U Rack with 2/4 or 8 > E1 capacity with echo cancellation. > I want that this "gateway" connect in trunk sip to my asterisk. > > Anyone have idea of good products for this ? > Redfone ? but no SIP i thnk's, only in MAC/Ethernet > Patton ? Not in rack > other ? > > > thanks for your help > Olivier > > -- > _ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users > -- - Luis Morales Consultor de Tecnologia Cel: +(58)412-2352745 - "Empieza por hacer lo necesario, luego lo que es posible... y de pronto estarás haciendo lo imposible" Leonardo Da'Vinci - -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Danny Nicholas wrote: > Darn, that should have worked. The "improvement" from 1.4.22 to 1.4.23+ > basically requires that every "print STDOUT" line be followed by a > to make util.c not choke when doing commands/setting variables. I wonder > how this "rewrite" would work? > sub set_variable >{ > my ($self, %vars) = @_; > while (my($var,$val) = each %vars) >{ > if (!defined($val)) >{ warn "AGI->set_variable: not setting '$var' because value > was undef\n"; next; } > print STDOUT "SET VARIABLE $var \"$val\" \r\n"; > ; >} >} > I dont think that routine is the issue. Its only called when setting the variables and that is only done before the call is dialed and in that case the script generates no errors :- -- Executing [08454632...@service_nts_nextgen_v2:1] AGI("Zap/5-1", "service_nts_nextgen|mode=start|") in new stack -- Launched AGI Script /var/lib/asterisk/agi-bin/service_nts_nextgen AGI Tx >> agi_request: service_nts_nextgen AGI Tx >> agi_channel: Zap/5-1 AGI Tx >> agi_language: en AGI Tx >> agi_type: Zap AGI Tx >> agi_uniqueid: 1272469456.5 AGI Tx >> agi_callerid: 1276459900 AGI Tx >> agi_calleridname: unknown AGI Tx >> agi_callingpres: 1 AGI Tx >> agi_callingani2: 0 AGI Tx >> agi_callington: 33 AGI Tx >> agi_callingtns: 0 AGI Tx >> agi_dnid: 08454632504 AGI Tx >> agi_rdnis: unknown AGI Tx >> agi_context: service_nts_nextgen_v2 AGI Tx >> agi_extension: 08454632504 AGI Tx >> agi_priority: 1 AGI Tx >> agi_enhanced: 0.0 AGI Tx >> agi_accountcode: AGI Tx >> > AGI Rx << SET VARIABLE __item_count "0" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __custid "13361" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __dniascli "0" AGI Tx >> 200 result=1 AGI Rx << GET VARIABLE __cliorig AGI Tx >> 200 result=0 AGI Rx << VERBOSE "Route To Number: 447584255419" 1 service_nts_nextgen|mode=start|: Route To Number: 447584255419 AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_number_1 "07584255419" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_type_1 "number" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_type_id_1 "1" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_channel_1 "Zap/g1" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __numcarriers_1 "2" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_carrier_1_2 "PSTN:DEFAULT" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_number_1_2 "07584255419" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_channel_1_2 "Zap/g1" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_carrier_1_1 "SIP:MAGRATHEA" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_number_1_1 "07584255...@magrathea" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __destination_channel_1_1 "SIP" AGI Tx >> 200 result=1 AGI Rx << SET VARIABLE __item_count "1" AGI Tx >> 200 result=1 -- AGI Script service_nts_nextgen completed, returning 0 The problem is with where the mode is answered or completed when I get errors like this :- -- Executing [...@macro-service-nts-nextgenv2-register-answer:3] AGI("SIP/magrathea-0002", "service_nts_nextgen|mode=answered|1272469456.5|1272469457.6|07584255419|1||SIP:MAGRATHEA|params=") in new stack -- Launched AGI Script /var/lib/asterisk/agi-bin/service_nts_nextgen AGI Tx >> agi_request: service_nts_nextgen AGI Tx >> agi_channel: SIP/magrathea-0002 AGI Tx >> agi_language: en AGI Tx >> agi_type: SIP AGI Tx >> agi_uniqueid: 1272469457.6 AGI Tx >> agi_callerid: 08454632504 AGI Tx >> agi_calleridname: unknown AGI Tx >> agi_callingpres: 0 AGI Tx >> agi_callingani2: 0 AGI Tx >> agi_callington: 33 AGI Tx >> agi_callingtns: 0 AGI Tx >> agi_dnid: unknown [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_rdnis: unknown [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_context: macro-service-nts-nextgenv2-register-answer [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_extension: s [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_priority: 3 [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_enhanced: 0.0 [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> agi_accountcode: [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe AGI Tx >> [Apr 28 16:44:34] ERROR[23465]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe -- AGI Script service_nts_nextgen completed, returning 0 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a l
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
On Apr 28, 2010, at 11:30 AM, Steve Edwards wrote: > On Wed, 28 Apr 2010, Gareth Blades wrote: > >> The script does not issue any commands. The same script is called at all >> 3 stages but with different parameters on the command line to indicate >> the call status. Works fine before the call is answered but during and >> at the end of the call it quits before asterisk has finished sending the >> information about the current call via STDIN. > > As others have said -- you are violating the protocol. > > Asterisk sends the "AGI environment" to the AGI via STDIN. If you don't > read it, you are violating the protocol. > > For a AGI that is called repeatedly, maybe you should consider > implementing it in a compiled language. > > You can execute XXX AGIs written in C in the time it takes to load the > Perl interpreter and parse your script. > > -- Of course this will turn into a religious war ;) Bottom line, if you like perl, use perl. Even though C is faster, there are benefits to using a language you know as well as implementing it for other reasons. I end up using perl 99% of the time just for simple ability with MySQL stored procedures or connecting ease with MSSQL databases. That being said... Try starting your script with something such as: $|=1; while() { chomp; last unless length($_); } (of course you can add whatever you want in there to pull the variables... For setting multiple asterisk variables, I like using a sub: sub setvariable { my ($variable, $value) = @_; print STDOUT "SET VARIABLE $variable \"$value\" \n"; while() { m/200 result=1/ && last; } return; } then just call it with something like: &setvariable("MAILBOX", $mailbox); --fred http://qxork.com -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Steve Edwards wrote: > On Wed, 28 Apr 2010, Gareth Blades wrote: > >> The script does not issue any commands. The same script is called at all >> 3 stages but with different parameters on the command line to indicate >> the call status. Works fine before the call is answered but during and >> at the end of the call it quits before asterisk has finished sending the >> information about the current call via STDIN. > > As others have said -- you are violating the protocol. > > Asterisk sends the "AGI environment" to the AGI via STDIN. If you don't > read it, you are violating the protocol. > > For a AGI that is called repeatedly, maybe you should consider > implementing it in a compiled language. > > You can execute XXX AGIs written in C in the time it takes to load the > Perl interpreter and parse your script. > We are reading in the STDIN (assume its part of the asterisk perl module). If I add a 3 second pause to the end of the perl code then it works fine. But if this is the case then for a system with a high call volume this significantly increases the number of running AGI programs which is not good for system load. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
On Wed, 28 Apr 2010, Gareth Blades wrote: > The script does not issue any commands. The same script is called at all > 3 stages but with different parameters on the command line to indicate > the call status. Works fine before the call is answered but during and > at the end of the call it quits before asterisk has finished sending the > information about the current call via STDIN. As others have said -- you are violating the protocol. Asterisk sends the "AGI environment" to the AGI via STDIN. If you don't read it, you are violating the protocol. For a AGI that is called repeatedly, maybe you should consider implementing it in a compiled language. You can execute XXX AGIs written in C in the time it takes to load the Perl interpreter and parse your script. -- Thanks in advance, - Steve Edwards sedwa...@sedwards.com Voice: +1-760-468-3867 PST Newline Fax: +1-760-731-3000 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Darn, that should have worked. The "improvement" from 1.4.22 to 1.4.23+ basically requires that every "print STDOUT" line be followed by a to make util.c not choke when doing commands/setting variables. I wonder how this "rewrite" would work? sub set_variable { my ($self, %vars) = @_; while (my($var,$val) = each %vars) { if (!defined($val)) { warn "AGI->set_variable: not setting '$var' because value was undef\n"; next; } print STDOUT "SET VARIABLE $var \"$val\" \r\n"; ; } } -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades Sent: Wednesday, April 28, 2010 10:05 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script You mean as in :- ? sub set_variable { my ($self, %vars) = @_; while (my($var,$val) = each %vars) { if (!defined($val)) { warn "AGI->set_variable: not setting '$var' because value was undef\n"; next; } #warn "AGI->set_variable('$var','$val')\n"; $self->SUPER::set_variable($var, $val); ; } } It didnt work. The AGI script hung the dialplan before attempting to dial Thanks Danny Nicholas wrote: > Just a hunch - add ; after line 15 and give it a whirl. > > -Original Message- > From: asterisk-users-boun...@lists.digium.com > [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades > Sent: Wednesday, April 28, 2010 9:47 AM > To: Asterisk Users Mailing List - Non-Commercial Discussion > Subject: Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI > script > > Danny Nicholas wrote: >> Can you post the script? >> > > Yes private stuff is in a separate file. $mode=start works fine but > answered and completed cause the problem. > I dont know if it is a problem with teh AGI script or just the newer > asterisk reporting it as an error. It doesnt effect functionality but > just gives a lot of console output and logging which is undesireable. > > Thanks > Gareth > > > > #!/usr/bin/perl -I /var/lib/asterisk/agi-bin/includes > > package Asterisk::AGIwrap; > use strict; > use base 'Asterisk::AGI'; > > sub set_variable >{ > my ($self, %vars) = @_; > while (my($var,$val) = each %vars) >{ > if (!defined($val)) >{ warn "AGI->set_variable: not setting '$var' because value > was undef\n"; next; } > #warn "AGI->set_variable('$var','$val')\n"; > $self->SUPER::set_variable($var, $val); >} >} > > package main; > use strict; > > our $application = "service_nts_nextgen"; > our $subagent = "AGI - $application"; > open(OLD_STDERR,">&STDERR") or die "Failed to save STDERR"; > open(STDERR,">>/var/log/agi_$application.err") or die "Failed to > redirect STDERR"; > > my $settings = require '/var/lib/asterisk/agi-bin/skycom_gw_settings.pl'; > our $gatewayID = $settings->{'gatewayID'}; > my ($dbname, $dbhost, $dbport, $dbuser, $dbpass) = > @{%{$settings->{'db'}}}{'name','host','port','user','pass'}; > > my $db; > > eval >{ > use DBI; > $db = DBI->connect("DBI:mysql:$dbname:$dbhost:$dbport", $dbuser, > $dbpass, $settings->{'dbopt'}) || die "Cannot connect to database: > $DBI::errstr"; > > our $AGI = new Asterisk::AGIwrap; > > print STDERR scalar localtime, " RUNNING:$0 ", (map {"\"$_\" "} > @ARGV), "\n"; > our $mode = $ARGV[0]; > my %ARG = (); > if ($mode =~ /mode=(.*)/) >{ > $ARG{'mode'} = $mode = $1; > foreach my $arg (@ARGV) >{ > $arg =~ /^(\w+)=(.*)$/ || next; > $ARG{$1} = $arg = $2; >} >} > > our $not_recognised = 0; > my $func; > > if ($mode eq "start") >{ > $func = require > '/var/lib/asterisk/agi-bin/service_nts_nextgen-start.pl'; > &$func('db'=>$db, 'AGI'=>$AGI, 'settings'=>$settings); >} > > elsif ($mode eq "answered") >{ > my $uniqueID = $ARGV[1]; > my $uniqueIDB = $ARGV[2]; > my $destination = $ARGV[3]; > my $destination_type = $ARGV[4]; > my $destination_args = $ARGV[5]; > my $destination_carrier = $ARGV[6]; > $destination =~ s/^00//; # International > $destination =~ s/^0([1-9]+)/44$1/; # UK > my $args = { > #'destination_type_id' => '"'.$destination_type.'"', > 'answer_time' => 'NOW()', > 'answer_epoch' => 'UNIX_TIMESTAMP()', > 'uniqueIDB' => '"'.$uniqueIDB.'"', > 'ddi' => '"'.$destination.'"', > 'carriernameID' => carriernameID($destination_carrier) > }; > if ($destination_type) >{ $args->{'destination_type_id'} = '"'.$destination_type.'"'; }
Re: [asterisk-users] Gateway E1 <=> Asterisk ?
On Wed, Apr 28, 2010 at 7:58 AM, Tim Nelson wrote: > - "Olivier CALVANO" wrote: >> Hi >> >> i want change my asterisk server. Actually, Asterisk work's on a IBM >> Server with a internal digium E1 card. >> For High availability, i don't want now use "internal E1" card. >> In my new asterisk systems, i have two server and two E1 not in the >> same site. >> >> I am search a hardware gateway, if possible in 1U Rack with 2/4 or 8 >> E1 capacity with echo cancellation. >> I want that this "gateway" connect in trunk sip to my asterisk. >> >> Anyone have idea of good products for this ? >> Redfone ? but no SIP i thnk's, only in MAC/Ethernet >> Patton ? Not in rack >> other ? > > Audiocodes Mediant gateways are top notch. Their Mediant-1000 supports up to > 4 interfaces (T1/E1/J1). +1 for AudioCodes Median 1000. The AudioCodes Median 2000 supports up to 16 T1/E1s if you need more than 4. -Jonathan -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Gateway E1 <=> Asterisk ?
- "Olivier CALVANO" wrote: > Hi > > i want change my asterisk server. Actually, Asterisk work's on a IBM > Server with a internal digium E1 card. > For High availability, i don't want now use "internal E1" card. > In my new asterisk systems, i have two server and two E1 not in the > same site. > > I am search a hardware gateway, if possible in 1U Rack with 2/4 or 8 > E1 capacity with echo cancellation. > I want that this "gateway" connect in trunk sip to my asterisk. > > Anyone have idea of good products for this ? > Redfone ? but no SIP i thnk's, only in MAC/Ethernet > Patton ? Not in rack > other ? Audiocodes Mediant gateways are top notch. Their Mediant-1000 supports up to 4 interfaces (T1/E1/J1). --Tim -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
You mean as in :- ? sub set_variable { my ($self, %vars) = @_; while (my($var,$val) = each %vars) { if (!defined($val)) { warn "AGI->set_variable: not setting '$var' because value was undef\n"; next; } #warn "AGI->set_variable('$var','$val')\n"; $self->SUPER::set_variable($var, $val); ; } } It didnt work. The AGI script hung the dialplan before attempting to dial Thanks Danny Nicholas wrote: > Just a hunch - add ; after line 15 and give it a whirl. > > -Original Message- > From: asterisk-users-boun...@lists.digium.com > [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades > Sent: Wednesday, April 28, 2010 9:47 AM > To: Asterisk Users Mailing List - Non-Commercial Discussion > Subject: Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI > script > > Danny Nicholas wrote: >> Can you post the script? >> > > Yes private stuff is in a separate file. $mode=start works fine but > answered and completed cause the problem. > I dont know if it is a problem with teh AGI script or just the newer > asterisk reporting it as an error. It doesnt effect functionality but > just gives a lot of console output and logging which is undesireable. > > Thanks > Gareth > > > > #!/usr/bin/perl -I /var/lib/asterisk/agi-bin/includes > > package Asterisk::AGIwrap; > use strict; > use base 'Asterisk::AGI'; > > sub set_variable >{ > my ($self, %vars) = @_; > while (my($var,$val) = each %vars) >{ > if (!defined($val)) >{ warn "AGI->set_variable: not setting '$var' because value > was undef\n"; next; } > #warn "AGI->set_variable('$var','$val')\n"; > $self->SUPER::set_variable($var, $val); >} >} > > package main; > use strict; > > our $application = "service_nts_nextgen"; > our $subagent = "AGI - $application"; > open(OLD_STDERR,">&STDERR") or die "Failed to save STDERR"; > open(STDERR,">>/var/log/agi_$application.err") or die "Failed to > redirect STDERR"; > > my $settings = require '/var/lib/asterisk/agi-bin/skycom_gw_settings.pl'; > our $gatewayID = $settings->{'gatewayID'}; > my ($dbname, $dbhost, $dbport, $dbuser, $dbpass) = > @{%{$settings->{'db'}}}{'name','host','port','user','pass'}; > > my $db; > > eval >{ > use DBI; > $db = DBI->connect("DBI:mysql:$dbname:$dbhost:$dbport", $dbuser, > $dbpass, $settings->{'dbopt'}) || die "Cannot connect to database: > $DBI::errstr"; > > our $AGI = new Asterisk::AGIwrap; > > print STDERR scalar localtime, " RUNNING:$0 ", (map {"\"$_\" "} > @ARGV), "\n"; > our $mode = $ARGV[0]; > my %ARG = (); > if ($mode =~ /mode=(.*)/) >{ > $ARG{'mode'} = $mode = $1; > foreach my $arg (@ARGV) >{ > $arg =~ /^(\w+)=(.*)$/ || next; > $ARG{$1} = $arg = $2; >} >} > > our $not_recognised = 0; > my $func; > > if ($mode eq "start") >{ > $func = require > '/var/lib/asterisk/agi-bin/service_nts_nextgen-start.pl'; > &$func('db'=>$db, 'AGI'=>$AGI, 'settings'=>$settings); >} > > elsif ($mode eq "answered") >{ > my $uniqueID = $ARGV[1]; > my $uniqueIDB = $ARGV[2]; > my $destination = $ARGV[3]; > my $destination_type = $ARGV[4]; > my $destination_args = $ARGV[5]; > my $destination_carrier = $ARGV[6]; > $destination =~ s/^00//; # International > $destination =~ s/^0([1-9]+)/44$1/; # UK > my $args = { > #'destination_type_id' => '"'.$destination_type.'"', > 'answer_time' => 'NOW()', > 'answer_epoch' => 'UNIX_TIMESTAMP()', > 'uniqueIDB' => '"'.$uniqueIDB.'"', > 'ddi' => '"'.$destination.'"', > 'carriernameID' => carriernameID($destination_carrier) > }; > if ($destination_type) >{ $args->{'destination_type_id'} = '"'.$destination_type.'"'; } > if ($destination_args ne '') { $args->{'destination_args'} = > '"'.$destination_args.'"'; } > if (defined($ARG{'params'})) >{ $args->{'extra_params'} = > $db->quote(urlstr_to_miniserial($ARG{'params'})); } > &updateCDR($uniqueID,$args,$db); >} > > elsif ($mode eq "completed") >{ > my $uniqueID = $ARGV[1]; > my $status = $ARGV[2]; > my $failedpredial = $ARGV[4]; > if ($uniqueID eq "") { $uniqueID = $ARGV[3]; } > if ($status eq "" && $failedpredial ne "1") { $status = "FAILED"; } > my $destination_type = ($ARGV[6] =~ /^\d+$/ ? $ARGV[6] : 0); > my $dest_arg = $ARGV[7]; > my $connect_epoch = $ARGV[8] || 0; > > my $args = { > 'end_time' => 'NOW()', > 'end_epoch' => 'UNIX_TIMESTAMP()', >
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Just a hunch - add ; after line 15 and give it a whirl. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades Sent: Wednesday, April 28, 2010 9:47 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script Danny Nicholas wrote: > Can you post the script? > Yes private stuff is in a separate file. $mode=start works fine but answered and completed cause the problem. I dont know if it is a problem with teh AGI script or just the newer asterisk reporting it as an error. It doesnt effect functionality but just gives a lot of console output and logging which is undesireable. Thanks Gareth #!/usr/bin/perl -I /var/lib/asterisk/agi-bin/includes package Asterisk::AGIwrap; use strict; use base 'Asterisk::AGI'; sub set_variable { my ($self, %vars) = @_; while (my($var,$val) = each %vars) { if (!defined($val)) { warn "AGI->set_variable: not setting '$var' because value was undef\n"; next; } #warn "AGI->set_variable('$var','$val')\n"; $self->SUPER::set_variable($var, $val); } } package main; use strict; our $application = "service_nts_nextgen"; our $subagent = "AGI - $application"; open(OLD_STDERR,">&STDERR") or die "Failed to save STDERR"; open(STDERR,">>/var/log/agi_$application.err") or die "Failed to redirect STDERR"; my $settings = require '/var/lib/asterisk/agi-bin/skycom_gw_settings.pl'; our $gatewayID = $settings->{'gatewayID'}; my ($dbname, $dbhost, $dbport, $dbuser, $dbpass) = @{%{$settings->{'db'}}}{'name','host','port','user','pass'}; my $db; eval { use DBI; $db = DBI->connect("DBI:mysql:$dbname:$dbhost:$dbport", $dbuser, $dbpass, $settings->{'dbopt'}) || die "Cannot connect to database: $DBI::errstr"; our $AGI = new Asterisk::AGIwrap; print STDERR scalar localtime, " RUNNING:$0 ", (map {"\"$_\" "} @ARGV), "\n"; our $mode = $ARGV[0]; my %ARG = (); if ($mode =~ /mode=(.*)/) { $ARG{'mode'} = $mode = $1; foreach my $arg (@ARGV) { $arg =~ /^(\w+)=(.*)$/ || next; $ARG{$1} = $arg = $2; } } our $not_recognised = 0; my $func; if ($mode eq "start") { $func = require '/var/lib/asterisk/agi-bin/service_nts_nextgen-start.pl'; &$func('db'=>$db, 'AGI'=>$AGI, 'settings'=>$settings); } elsif ($mode eq "answered") { my $uniqueID = $ARGV[1]; my $uniqueIDB = $ARGV[2]; my $destination = $ARGV[3]; my $destination_type = $ARGV[4]; my $destination_args = $ARGV[5]; my $destination_carrier = $ARGV[6]; $destination =~ s/^00//; # International $destination =~ s/^0([1-9]+)/44$1/; # UK my $args = { #'destination_type_id' => '"'.$destination_type.'"', 'answer_time' => 'NOW()', 'answer_epoch' => 'UNIX_TIMESTAMP()', 'uniqueIDB' => '"'.$uniqueIDB.'"', 'ddi' => '"'.$destination.'"', 'carriernameID' => carriernameID($destination_carrier) }; if ($destination_type) { $args->{'destination_type_id'} = '"'.$destination_type.'"'; } if ($destination_args ne '') { $args->{'destination_args'} = '"'.$destination_args.'"'; } if (defined($ARG{'params'})) { $args->{'extra_params'} = $db->quote(urlstr_to_miniserial($ARG{'params'})); } &updateCDR($uniqueID,$args,$db); } elsif ($mode eq "completed") { my $uniqueID = $ARGV[1]; my $status = $ARGV[2]; my $failedpredial = $ARGV[4]; if ($uniqueID eq "") { $uniqueID = $ARGV[3]; } if ($status eq "" && $failedpredial ne "1") { $status = "FAILED"; } my $destination_type = ($ARGV[6] =~ /^\d+$/ ? $ARGV[6] : 0); my $dest_arg = $ARGV[7]; my $connect_epoch = $ARGV[8] || 0; my $args = { 'end_time' => 'NOW()', 'end_epoch' => 'UNIX_TIMESTAMP()', 'duration' => '(UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(start_time))', 'carriernameID' => carriernameID($ARGV[5]), 'connect_epoch'=>$connect_epoch, ($destination_type ? ('destination_type_id'=>$destination_type) : ()), }; if (defined($ARG{'params'})) { $args->{'extra_params'} = $db->quote(urlstr_to_miniserial($ARG{'params'})); } if ($status eq "VOICEMAIL") { $args->{'destination_type_id'} = 3; $status = "ANSWER"; } if ($status eq "ANNOUNCEMENT") { $args->{'destination_type_id'} = 6; $status = "ANSWER"; } if ($destination_ty
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Danny Nicholas wrote: > Can you post the script? > Yes private stuff is in a separate file. $mode=start works fine but answered and completed cause the problem. I dont know if it is a problem with teh AGI script or just the newer asterisk reporting it as an error. It doesnt effect functionality but just gives a lot of console output and logging which is undesireable. Thanks Gareth #!/usr/bin/perl -I /var/lib/asterisk/agi-bin/includes package Asterisk::AGIwrap; use strict; use base 'Asterisk::AGI'; sub set_variable { my ($self, %vars) = @_; while (my($var,$val) = each %vars) { if (!defined($val)) { warn "AGI->set_variable: not setting '$var' because value was undef\n"; next; } #warn "AGI->set_variable('$var','$val')\n"; $self->SUPER::set_variable($var, $val); } } package main; use strict; our $application = "service_nts_nextgen"; our $subagent = "AGI - $application"; open(OLD_STDERR,">&STDERR") or die "Failed to save STDERR"; open(STDERR,">>/var/log/agi_$application.err") or die "Failed to redirect STDERR"; my $settings = require '/var/lib/asterisk/agi-bin/skycom_gw_settings.pl'; our $gatewayID = $settings->{'gatewayID'}; my ($dbname, $dbhost, $dbport, $dbuser, $dbpass) = @{%{$settings->{'db'}}}{'name','host','port','user','pass'}; my $db; eval { use DBI; $db = DBI->connect("DBI:mysql:$dbname:$dbhost:$dbport", $dbuser, $dbpass, $settings->{'dbopt'}) || die "Cannot connect to database: $DBI::errstr"; our $AGI = new Asterisk::AGIwrap; print STDERR scalar localtime, " RUNNING:$0 ", (map {"\"$_\" "} @ARGV), "\n"; our $mode = $ARGV[0]; my %ARG = (); if ($mode =~ /mode=(.*)/) { $ARG{'mode'} = $mode = $1; foreach my $arg (@ARGV) { $arg =~ /^(\w+)=(.*)$/ || next; $ARG{$1} = $arg = $2; } } our $not_recognised = 0; my $func; if ($mode eq "start") { $func = require '/var/lib/asterisk/agi-bin/service_nts_nextgen-start.pl'; &$func('db'=>$db, 'AGI'=>$AGI, 'settings'=>$settings); } elsif ($mode eq "answered") { my $uniqueID = $ARGV[1]; my $uniqueIDB = $ARGV[2]; my $destination = $ARGV[3]; my $destination_type = $ARGV[4]; my $destination_args = $ARGV[5]; my $destination_carrier = $ARGV[6]; $destination =~ s/^00//; # International $destination =~ s/^0([1-9]+)/44$1/; # UK my $args = { #'destination_type_id' => '"'.$destination_type.'"', 'answer_time' => 'NOW()', 'answer_epoch' => 'UNIX_TIMESTAMP()', 'uniqueIDB' => '"'.$uniqueIDB.'"', 'ddi' => '"'.$destination.'"', 'carriernameID' => carriernameID($destination_carrier) }; if ($destination_type) { $args->{'destination_type_id'} = '"'.$destination_type.'"'; } if ($destination_args ne '') { $args->{'destination_args'} = '"'.$destination_args.'"'; } if (defined($ARG{'params'})) { $args->{'extra_params'} = $db->quote(urlstr_to_miniserial($ARG{'params'})); } &updateCDR($uniqueID,$args,$db); } elsif ($mode eq "completed") { my $uniqueID = $ARGV[1]; my $status = $ARGV[2]; my $failedpredial = $ARGV[4]; if ($uniqueID eq "") { $uniqueID = $ARGV[3]; } if ($status eq "" && $failedpredial ne "1") { $status = "FAILED"; } my $destination_type = ($ARGV[6] =~ /^\d+$/ ? $ARGV[6] : 0); my $dest_arg = $ARGV[7]; my $connect_epoch = $ARGV[8] || 0; my $args = { 'end_time' => 'NOW()', 'end_epoch' => 'UNIX_TIMESTAMP()', 'duration' => '(UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(start_time))', 'carriernameID' => carriernameID($ARGV[5]), 'connect_epoch'=>$connect_epoch, ($destination_type ? ('destination_type_id'=>$destination_type) : ()), }; if (defined($ARG{'params'})) { $args->{'extra_params'} = $db->quote(urlstr_to_miniserial($ARG{'params'})); } if ($status eq "VOICEMAIL") { $args->{'destination_type_id'} = 3; $status = "ANSWER"; } if ($status eq "ANNOUNCEMENT") { $args->{'destination_type_id'} = 6; $status = "ANSWER"; } if ($destination_type == 1) { if ($dest_arg =~ /^\d+$/) { if ($dest_arg =~ /^00/) { $dest_arg =~ s/^00//; } elsif ($dest_arg =~ /^0[1-9]/) { $dest_arg =~ s/^0/44/; } $args->{'ddi'} = $db->quote($dest_arg); } } elsif ($destination_type > 1)
[asterisk-users] Gateway E1 <=> Asterisk ?
Hi i want change my asterisk server. Actually, Asterisk work's on a IBM Server with a internal digium E1 card. For High availability, i don't want now use "internal E1" card. In my new asterisk systems, i have two server and two E1 not in the same site. I am search a hardware gateway, if possible in 1U Rack with 2/4 or 8 E1 capacity with echo cancellation. I want that this "gateway" connect in trunk sip to my asterisk. Anyone have idea of good products for this ? Redfone ? but no SIP i thnk's, only in MAC/Ethernet Patton ? Not in rack other ? thanks for your help Olivier -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Can you post the script? -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades Sent: Wednesday, April 28, 2010 9:00 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script Philipp von Klitzing wrote: > Hi! > >> Why is asterisk so slow in sending the call info via STDIn in these cases? >> Is there any way this can be fixed? > > Your AGI script is faulty: In at least one place you have missed to READ > the output right after you have issued a command. So go check your script > ("agi debug" might help a little with this). > > Others would say: Your script violates the AGI protocol. The script performs call logging to a database. Similar to the built in CDR but it updates at the start and answering of a call aswell so the database can be used to show current call status. The script does not issue any commands. The same script is called at all 3 stages but with different parameters on the command line to indicate the call status. Works fine before the call is answered but during and at the end of the call it quits before asterisk has finished sending the information about the current call via STDIN. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Philipp von Klitzing wrote: > Hi! > >> Why is asterisk so slow in sending the call info via STDIn in these cases? >> Is there any way this can be fixed? > > Your AGI script is faulty: In at least one place you have missed to READ > the output right after you have issued a command. So go check your script > ("agi debug" might help a little with this). > > Others would say: Your script violates the AGI protocol. The script performs call logging to a database. Similar to the built in CDR but it updates at the start and answering of a call aswell so the database can be used to show current call status. The script does not issue any commands. The same script is called at all 3 stages but with different parameters on the command line to indicate the call status. Works fine before the call is answered but during and at the end of the call it quits before asterisk has finished sending the information about the current call via STDIN. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Danny Nicholas wrote: > Check out this snippet from "Tilghman Lesher" (one of the true Asterisk > Guru's) > http://www.mail-archive.com/asterisk-users@lists.digium.com/msg220482.html > Thanks but that appears related to AMI not AGI. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] BN8S0, dahdi, wcb4xxp
Am Mittwoch, 28. April 2010 09:58:14 schrieb Tzafrir Cohen: > On Wed, Apr 28, 2010 at 07:12:57AM +0200, Claire Sinn wrote: > > Hi, > > > > a few month ago, I tried to install zaptel for my Beronet BN8S0 pci > > card... I gave up and took hfcmulti/lcr. Now dahdi (2.2.1.1) seems to > > support the card and I'm very interested to get it to work. > > But how to get rid of these annoying qozap driver? > > > > bishop dahdi # lspci -v -nn -s 01:00.0 > > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network > > Controller [HFC-8S] [1397:16b8] (rev 01) > > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > > Flags: medium devsel, IRQ 21 > > I/O ports at 9480 [size=8] > > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > > Capabilities: [40] Power Management version 2 > > Kernel modules: wcb4xxp, hfcmulti > > > > bishop dahdi # modprobe wcb4xxp > > bishop dahdi # lspci -v -nn -s 01:00.0 > > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network > > Controller [HFC-8S] [1397:16b8] (rev 01) > > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > > Flags: medium devsel, IRQ 21 > > I/O ports at 9480 [size=8] > > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > > Capabilities: [40] Power Management version 2 > > Kernel driver in use: wcb4xxp > > Kernel modules: wcb4xxp, hfcmulti > > > > bishop dahdi # dahdi_hardware -v > > driver should be 'qozap' but is actually 'wcb4xxp' > > pci::01:00.0 qozap+ 1397:16b8 Junghanns OctoBRI ISDN card > > Seems like the list of devices in Dahdi::Hardware::PCI is not > up-to-date. > I tried to ignore the output of dahdi_hardware, but it seems to be more than a cosmetic problem. The half of the ports are jumpered for TE mode (port 1,2,7 and 8) and they work fine. The remaining ports are jumpered for NT use and produce a RED alarm. bishop asterisk # grep wcb4xxp /var/log/kern.log |tail -n 14 Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: probe called for b4xx... Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: PCI INT A -> GSI 21 (level, low) -> IRQ 21 Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Identified BeroNet BN8S0 (controller rev 1) at 00019480, IRQ 21 Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: NOTE: hardware echo cancellation has been disabled Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 1: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 2: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 3: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 4: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 5: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 6: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 7: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Port 8: TE mode Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: Did not do the highestorder stuff Apr 28 07:03:28 bishop kernel: wcb4xxp :01:00.0: new card sync source: port 3 Can I force wcb4xxp to configure some ports in NT mode? Clairef -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] command-line dialplan "compiler"
Hello listers, Still plodding along in the 1.4 tree, though I've started to dabble in 1.6 land. Today's adventure involves a 2600 line dialplan. My friend Google only points me to an antique java script and a bunch of GUI dialplan creators. What is out there that will point out dialplan errors/problems besides just watching the CLI output and trying to figure out with line out of 90 that my ast_yyerror actually occurred in? Regards, Danny Nicholas -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Check out this snippet from "Tilghman Lesher" (one of the true Asterisk Guru's) http://www.mail-archive.com/asterisk-users@lists.digium.com/msg220482.html It's a "NAG" (my term) introduced in the jump from 1.4.22 to 1.4.23 and carried out through the rest of the 1.4 tree. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades Sent: Wednesday, April 28, 2010 3:51 AM To: Asterisk Mailing List Subject: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script I have upgraded Asterisk from 1.4.22 to 1.4.30 and I have noticed I am getting a lot of errors like this on the console :- ERROR[23912]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe I have tracked it down to a perl AGI script which performs our own CDR recording. It is called before the start of the call, once answered and again when the call is hungup. It works fine when called before dialing and the AGI debugging shows asterisk sending the STDIN to the script very fast. When called after answering and at the end of the call asterisk is much slower sending the STDIN and I can see the debug scrolling up the screen and this is what is causing the error as the AGI script finished and exits before all the STDIN is sent. Even if I add a pause at the end of the script for 1 second it only gets half way through sending the STDIN. Why is asterisk so slow in sending the call info via STDIn in these cases? Is there any way this can be fixed? Thanks -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Hi! > Why is asterisk so slow in sending the call info via STDIn in these cases? > Is there any way this can be fixed? Your AGI script is faulty: In at least one place you have missed to READ the output right after you have issued a command. So go check your script ("agi debug" might help a little with this). Others would say: Your script violates the AGI protocol. Philipp -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] dialplan
GotoIf($["${CALLERID}":".*333.*"]?your_extension) (untested) Something like that (fix variable name to suitable). Check Asterisk regular expressions. http://www.voip-info.org/wiki/view/Asterisk+Expressions#Regularexpressions On Wed, Apr 28, 2010 at 3:49 PM, wassim darwich wrote: > > Hi guys: > i need to set an extension in my dialplan in which it divert calls if the extension contain specific series ,For example : > I need to divert calls which contain to specific extension (contain ,not start or end with), as i know i should set Gotoif command but i dont know what to set after that,Any help will be appreciated. > > -- > _ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] BN8S0, dahdi, wcb4xxp
Am Mittwoch, 28. April 2010 09:58:14 schrieb Tzafrir Cohen: > On Wed, Apr 28, 2010 at 07:12:57AM +0200, Claire Sinn wrote: > > Hi, > > > > a few month ago, I tried to install zaptel for my Beronet BN8S0 pci > > card... I gave up and took hfcmulti/lcr. Now dahdi (2.2.1.1) seems to > > support the card and I'm very interested to get it to work. > > But how to get rid of these annoying qozap driver? > > > > bishop dahdi # lspci -v -nn -s 01:00.0 > > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network > > Controller [HFC-8S] [1397:16b8] (rev 01) > > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > > Flags: medium devsel, IRQ 21 > > I/O ports at 9480 [size=8] > > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > > Capabilities: [40] Power Management version 2 > > Kernel modules: wcb4xxp, hfcmulti > > > > bishop dahdi # modprobe wcb4xxp > > bishop dahdi # lspci -v -nn -s 01:00.0 > > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network > > Controller [HFC-8S] [1397:16b8] (rev 01) > > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > > Flags: medium devsel, IRQ 21 > > I/O ports at 9480 [size=8] > > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > > Capabilities: [40] Power Management version 2 > > Kernel driver in use: wcb4xxp > > Kernel modules: wcb4xxp, hfcmulti > > > > bishop dahdi # dahdi_hardware -v > > driver should be 'qozap' but is actually 'wcb4xxp' > > pci::01:00.0 qozap+ 1397:16b8 Junghanns OctoBRI ISDN card > > Seems like the list of devices in Dahdi::Hardware::PCI is not > up-to-date. > Sorry, what does that mean and how can I fix it temporarily? Claire -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
Two suggestions - 1. Make sure your AGI has the proper syntax/handling - just because it "works" doesn't mean that it will be happy in the more "restrictive" environment of a dialplan call. 2. If you are 100% certain that #1 has been addressed, change utils.c line 968 from ast_log(LOG_ERROR, "write() returned error: %s\n", strerror(errno)); to ast_log(LOG_WARNING, "write() returned error: %s\n", strerror(errno)); and do a new make;make install. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Gareth Blades Sent: Wednesday, April 28, 2010 3:51 AM To: Asterisk Mailing List Subject: [asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script I have upgraded Asterisk from 1.4.22 to 1.4.30 and I have noticed I am getting a lot of errors like this on the console :- ERROR[23912]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe I have tracked it down to a perl AGI script which performs our own CDR recording. It is called before the start of the call, once answered and again when the call is hungup. It works fine when called before dialing and the AGI debugging shows asterisk sending the STDIN to the script very fast. When called after answering and at the end of the call asterisk is much slower sending the STDIN and I can see the debug scrolling up the screen and this is what is causing the error as the AGI script finished and exits before all the STDIN is sent. Even if I add a pause at the end of the script for 1 second it only gets half way through sending the STDIN. Why is asterisk so slow in sending the call info via STDIn in these cases? Is there any way this can be fixed? Thanks -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] Execute Macro when queue is answered
Hello list, using asterisk 1.4.25.1 and realtime queues. I would like to use the parameter 'membermacro' so I've added a field in my mysql-table queues, but this is not working. Anyone knows how I can execute a macro when the queue is answered by a queuemember ?? Also the command queue() does not have this option... Kind regards, Jonas. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] dialplan
Are talking about something like exten => _..,1,Noop(Have in this extension) There is also this function that can be used to look for sub strings inside a string. core show function REGEX -= Info about function 'REGEX' =- [Syntax] REGEX("" ) [Synopsis] Regular Expression [Description] Returns 1 if data matches regular expression, or 0 otherwise. Please note that the space following the double quotes separating the regex from the data is optional and if present, is skipped. If a space is desired at the beginning of the data, then put two spaces there; the second will not be skipped. -- Jim Dickenson mailto:dicken...@cfmc.com CfMC http://www.cfmc.com/ On Apr 28, 2010, at 5:49 AM, wassim darwich wrote: > Hi guys: > i need to set an extension in my dialplan in which it divert calls if the > extension contain specific series ,For example : > I need to divert calls which contain to specific extension (contain > ,not start or end with), as i know i should set Gotoif command but i dont > know what to set after that,Any help will be appreciated. > > -- > _ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] dialplan
Hi guys: i need to set an extension in my dialplan in which it divert calls if the extension contain specific series ,For example : I need to divert calls which contain to specific extension (contain ,not start or end with), as i know i should set Gotoif command but i dont know what to set after that,Any help will be appreciated. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] Asterisk 1.4.30 is slow sending STDIN to AGI script
I have upgraded Asterisk from 1.4.22 to 1.4.30 and I have noticed I am getting a lot of errors like this on the console :- ERROR[23912]: utils.c:968 ast_carefulwrite: write() returned error: Broken pipe I have tracked it down to a perl AGI script which performs our own CDR recording. It is called before the start of the call, once answered and again when the call is hungup. It works fine when called before dialing and the AGI debugging shows asterisk sending the STDIN to the script very fast. When called after answering and at the end of the call asterisk is much slower sending the STDIN and I can see the debug scrolling up the screen and this is what is causing the error as the AGI script finished and exits before all the STDIN is sent. Even if I add a pause at the end of the script for 1 second it only gets half way through sending the STDIN. Why is asterisk so slow in sending the call info via STDIn in these cases? Is there any way this can be fixed? Thanks -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] BN8S0, dahdi, wcb4xxp
On Wed, Apr 28, 2010 at 07:12:57AM +0200, Claire Sinn wrote: > Hi, > > a few month ago, I tried to install zaptel for my Beronet BN8S0 pci card... I > gave up and took hfcmulti/lcr. Now dahdi (2.2.1.1) seems to support the card > and I'm very interested to get it to work. > But how to get rid of these annoying qozap driver? > > bishop dahdi # lspci -v -nn -s 01:00.0 > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network > Controller [HFC-8S] [1397:16b8] (rev 01) > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > Flags: medium devsel, IRQ 21 > I/O ports at 9480 [size=8] > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > Capabilities: [40] Power Management version 2 > Kernel modules: wcb4xxp, hfcmulti > > bishop dahdi # modprobe wcb4xxp > bishop dahdi # lspci -v -nn -s 01:00.0 > 01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network > Controller [HFC-8S] [1397:16b8] (rev 01) > Subsystem: Cologne Chip Designs GmbH Device [1397:b562] > Flags: medium devsel, IRQ 21 > I/O ports at 9480 [size=8] > Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K] > Capabilities: [40] Power Management version 2 > Kernel driver in use: wcb4xxp > Kernel modules: wcb4xxp, hfcmulti > > bishop dahdi # dahdi_hardware -v > driver should be 'qozap' but is actually 'wcb4xxp' > pci::01:00.0 qozap+ 1397:16b8 Junghanns OctoBRI ISDN card Seems like the list of devices in Dahdi::Hardware::PCI is not up-to-date. -- Tzafrir Cohen icq#16849755 jabber:tzafrir.co...@xorcom.com +972-50-7952406 mailto:tzafrir.co...@xorcom.com http://www.xorcom.com iax:gu...@local.xorcom.com/tzafrir -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Dial plan question.
On 28 Apr 2010, at 06:53, Aditya Kumar wrote: > exten => bob,1,Dial(SIP/${exte...@ext-sip,20) Where did you define EXTERN? S -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs: http://www.asterisk.org/hello asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users