[Asterisk-Users] SIP and AGI crash...
Hi, I'm trying to use the say-ani agi asterisk-perl script and am experiencing crashes, I am also experienceing problems with the test-agi scripts shipped with asterisk. The clearest demonstration of the problem is that if I dial extension 125 configured as... exten => 125,1,Ringing exten => 125,2,Wait(3) exten => 125,3,Answer exten => 125,4,Wait(2) exten => 125,5,AGI(agi-sayani.agi) exten => 125,6,Hangup I can crash the asterisk server by hanging up during the call, if I leave the call to complete and let * hang up then everything seems fine. Asterisk does not crash if I am running from the console, only if asterisk has been started in the background (it does still crash if I am attached via asterisk -r at the time the call is hung up). Using the agi test script (on extension 126, same config as above) I get the following... *CLI> -- Executing Ringing("SIP/-08135e80", "") in new stack -- Executing Wait("SIP/-08135e80", "3") in new stack -- Executing Answer("SIP/-08135e80", "") in new stack -- Executing Wait("SIP/-08135e80", "2") in new stack -- Executing AGI("SIP/-08135e80", "agi-test2.agi") in new stack -- Launched AGI Script /var/lib/asterisk/agi-bin/agi-test2.agi AGI Environment Dump: -- accountcode = -- callerid = "SNOM Phone 1543" <8552> -- channel = SIP/-08135e80 -- context = sip-gw -- dnid = unknown -- enhanced = 0.0 -- extension = 126 -- language = en -- priority = 5 -- rdnis = unknown -- request = agi-test2.agi -- type = SIP -- uniqueid = 1074011198.0 1. Testing 'sendfile'...PASS (0) 2. Testing 'sendtext'...PASS (0) 3. Testing 'sendimage'...PASS (0) -- Playing 'digits/1' (language 'en') -- Playing 'digits/hundred' (language 'en') -- Playing 'digits/90' (language 'en') -- Playing 'digits/2' (language 'en') -- Playing 'digits/million' (language 'en') -- Playing 'digits/8' (language 'en') -- Playing 'digits/hundred' (language 'en') -- Playing 'digits/30' (language 'en') -- Playing 'digits/7' (language 'en') -- Playing 'digits/thousand' (language 'en') Jan 13 16:26:50 WARNING[1116941120]: chan_sip.c:471 retrans_pkt: Maximum retries exceeded on call [EMAIL PROTECTED] for seqno 102 (Request) == Spawn extension (sip-gw, 126, 5) exited non-zero on 'SIP/-08135e80' -- Executing Hangup("SIP/-08135e80", "") in new stack == Spawn extension (sip-gw, h, 1) exited non-zero on 'SIP/-08135e80' PASS (-1) 5. Testing 'waitdtmf'...FAIL (unexpected result '') 6. Testing 'record'...FAIL (unexpected result '') 6a. Testing 'record' playback...FAIL (unexpected result '') == Complete ====== 7 tests completed, 4 passed, 3 failed == The test seems to stop half way through. I am not entirely sure that these two issues are actually related though as I don't see any of the warning from chan_sip if I hang up during a call to the say-ani script. I don't seem to be getting a core dump, are there any known issues with AGI at the moment? Voicemail, SayUnixTime and everything else is working fine. -- Tristan 'Minty' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] some success with linux 2.6 and wcfxo
Hi, In the mail that got held up in moderation I did mention this, I've had one other user attempt to use my patches and he hit devfs problems too, I personally don't use devfs at all so I haven't hit these issues. On Mon, Dec 08, 2003 at 09:35:17PM -0500, Ray Russell Reese III wrote: > I've attempted to get zaptel to compile with no success. zaptel.c won't > compile because of many references to devfs, which from my understanding > was stipped down to nothing in 2.6 in favor of udev. Following is a > snipit of some of the devfs errors: > > [EMAIL PROTECTED]:~/zaptel# make -C /usr/src/linux SUBDIRS=`pwd` modules 2>&1 > | more > make: Entering directory `/usr/src/linux-2.6.0-test11' > *** Warning: Overriding SUBDIRS on the command line can cause > *** inconsistencies > make[1]: `arch/i386/kernel/asm-offsets.s' is up to date. > CC [M] /root/zaptel/zaptel.o > In file included from /root/zaptel/zaptel.c:79: > /root/zaptel/zaptel.h:1068: error: syntax error before "devfs_handle_t" > /root/zaptel/zaptel.h:1068: warning: no semicolon at end of struct or > union > /root/zaptel/zaptel.h:1069: warning: type defaults to `int' in > declaration of `fhandle_symlink' > /root/zaptel/zaptel.h:1069: warning: data definition has no type or > storage class > /root/zaptel/zaptel.h:1198: error: syntax error before "devfs_handle_t" > /root/zaptel/zaptel.h:1198: warning: no semicolon at end of struct or > union > /root/zaptel/zaptel.h:1207: error: syntax error before '}' token > > I've applied the patch in your earlier post, plus the Makefile. Is there > anything specific I'm missing? Thanks. > > - Russ > > > On Mon, 2003-12-08 at 04:08, Tristan 'Minty' Colgate wrote: > > The original mail with the Makefile and my comments has been held up waiting > > for mdoeration, it's probably a little to big. Here is just the makefile > > without all my previous ranting. > > > > From the normal zaptel source, do a normal build, backup tones.h and the > > makefile, do a make clean, moves tones.h back, then copy this Makefile over the > > top of the old one, you can then use something like... > > > > make -C /usr/src/linux SUBDIRS=`pwd` modules > > > > That should build your .ko files, modules_install doesn't work, it all assumes > > your kernel source is in /usr/src/linux (it should really be using > > /lib/modules/`uname -r`/build, but I haven't tested that). > > > > > > BASEADDR=0xd > > DEFAULTZONE=0 > > CFLAGS+=-DSTANDALONE_ZAPATA > > CFLAGS+=-I/usr/src/linux -I/usr/src/linux/include/asm/mach-default -I. -O4 -g > > -Wall -DBUILDING_TONEZONE #-DTONEZONE_DRIVER > > CFLAGS+=$(shell if uname -m | grep -q ppc; then echo "-fsigned-char"; fi) > > CFLAGS+=-DMODULE -D__KERNEL__ -DEXPORT_SYMTAB -I/usr/src/linux/drivers/net \ > > -Wall -I. -Wstrict-prototypes -fomit-frame-pointer > > -I/usr/src/linux/drivers/net/wan -I /usr/src/linux/include > > -I/usr/src/linux/include/net > > CFLAGS+=-DECHO_CAN_MARK2 > > CFLAGS+=-DTORMENTA_BASE=$(BASEADDR) > > > > CFLAGS+=-DDEFAULT_TONE_ZONE=$(DEFAULTZONE) > > CFLAGS+=-D__SMP__ > > > > obj-m += zaptel.o wcfxo.o wcfxs.o ztdynamic.o ztd-eth.o wct1xxp.o wct4xxp.o > > ztdummy.o > > PRIMARY=wcfxo > > > > ___ > > Asterisk-Users mailing list > > [EMAIL PROTECTED] > > http://lists.digium.com/mailman/listinfo/asterisk-users > > > > ___ > Asterisk-Users mailing list > [EMAIL PROTECTED] > http://lists.digium.com/mailman/listinfo/asterisk-users -- Tristan 'Minty' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] some success with linux 2.6 and wcfxo
The original mail with the Makefile and my comments has been held up waiting for mdoeration, it's probably a little to big. Here is just the makefile without all my previous ranting. >From the normal zaptel source, do a normal build, backup tones.h and the makefile, do a make clean, moves tones.h back, then copy this Makefile over the top of the old one, you can then use something like... make -C /usr/src/linux SUBDIRS=`pwd` modules That should build your .ko files, modules_install doesn't work, it all assumes your kernel source is in /usr/src/linux (it should really be using /lib/modules/`uname -r`/build, but I haven't tested that). BASEADDR=0xd DEFAULTZONE=0 CFLAGS+=-DSTANDALONE_ZAPATA CFLAGS+=-I/usr/src/linux -I/usr/src/linux/include/asm/mach-default -I. -O4 -g -Wall -DBUILDING_TONEZONE #-DTONEZONE_DRIVER CFLAGS+=$(shell if uname -m | grep -q ppc; then echo "-fsigned-char"; fi) CFLAGS+=-DMODULE -D__KERNEL__ -DEXPORT_SYMTAB -I/usr/src/linux/drivers/net \ -Wall -I. -Wstrict-prototypes -fomit-frame-pointer -I/usr/src/linux/drivers/net/wan -I /usr/src/linux/include -I/usr/src/linux/include/net CFLAGS+=-DECHO_CAN_MARK2 CFLAGS+=-DTORMENTA_BASE=$(BASEADDR) CFLAGS+=-DDEFAULT_TONE_ZONE=$(DEFAULTZONE) CFLAGS+=-D__SMP__ obj-m += zaptel.o wcfxo.o wcfxs.o ztdynamic.o ztd-eth.o wct1xxp.o wct4xxp.o ztdummy.o PRIMARY=wcfxo ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] some success with linux 2.6 and wcfxo
It's not really intended to be applied at this stage since it will break 2.4. I am intending to update the bug in digiums database with my findings once I get the chance. On Sun, Dec 07, 2003 at 09:59:16AM -0800, TC wrote: > FYI, > the usual place for patch's is on > bugs.digium.com > and then a little link in an email here to let ppl know about it .. > > This allows a single place where these get reviewed for inclusion in cvs > > > ..nice work > > > > ___ > Asterisk-Users mailing list > [EMAIL PROTECTED] > http://lists.digium.com/mailman/listinfo/asterisk-users -- Tristan 'Minty' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] some success with linux 2.6 and wcfxo
oops, my apologiee for attaching the entire source of the drivers :( Here's a diff Index: wcfxo.c === RCS file: /usr/cvsroot/zaptel/wcfxo.c,v retrieving revision 1.21 diff -a -u -r1.21 wcfxo.c --- wcfxo.c 17 Nov 2003 22:09:40 - 1.21 +++ wcfxo.c 7 Dec 2003 17:04:12 - @@ -387,7 +387,7 @@ static void wcfxo_stop_dma(struct wcfxo *wc); static void wcfxo_restart_dma(struct wcfxo *wc); -static void wcfxo_interrupt(int irq, void *dev_id, struct pt_regs *regs) +irqreturn_t wcfxo_interrupt(int irq, void *dev_id, struct pt_regs *regs) { struct wcfxo *wc = dev_id; unsigned char ints; @@ -402,7 +402,7 @@ if (!ints) - return; + return IRQ_NONE; if (ints & 0x0c) { /* if there is a rx interrupt pending */ #ifdef ENABLE_TASKLETS @@ -425,12 +425,12 @@ printk("FXO PCI Master abort\n"); /* Stop DMA andlet the watchdog start it again */ wcfxo_stop_dma(wc); - return; + return IRQ_HANDLED; } if (ints & 0x20) { printk("PCI Target abort\n"); - return; + return IRQ_HANDLED; } if (1 /* !(wc->report % 0xf) */) { /* Check for BATTERY from register and debounce for 8 ms */ @@ -504,6 +504,7 @@ #endif } + return IRQ_HANDLED; } static int wcfxo_setreg(struct wcfxo *wc, unsigned char reg, unsigned char value) Index: wcfxs.c === RCS file: /usr/cvsroot/zaptel/wcfxs.c,v retrieving revision 1.39 diff -a -u -r1.39 wcfxs.c --- wcfxs.c 23 Nov 2003 23:09:46 - 1.39 +++ wcfxs.c 7 Dec 2003 17:04:14 - @@ -471,7 +471,7 @@ return 0; } -static void wcfxs_interrupt(int irq, void *dev_id, struct pt_regs *regs) +irqreturn_t wcfxs_interrupt(int irq, void *dev_id, struct pt_regs *regs) { struct wcfxs *wc = dev_id; unsigned char ints; @@ -487,12 +487,12 @@ /* Stop DMA, wait for watchdog */ printk("FXS PCI Master abort\n"); wcfxs_stop_dma(wc); - return; + return IRQ_HANDLED; } if (ints & 0x20) { printk("PCI Target abort\n"); - return; + return IRQ_NONE; } for (x=0;x<4;x++) { @@ -535,7 +535,7 @@ wcfxs_transmitprep(wc, ints); } - + return IRQ_HANDLED; } static int wcfxs_proslic_insane(struct wcfxs *wc, int card) @@ -1277,6 +1277,7 @@ outb(0x3f, wc->ioaddr + WC_MASK0); /* No external interrupts */ outb(0x00, wc->ioaddr + WC_MASK1); + } static void wcfxs_restart_dma(struct wcfxs *wc) ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] some success with linux 2.6 and wcfxo
Hi, My apologies for those on the channel who may take offense to this, atleast the ones to whom it was not aimed, but the fact is that after making a simple enquiry on the IRC channel I was in absolute shock... I asked one simple question, are there any known issues with the zaptel modules on 2.6, was given some very sensible advice to upgrade my mod utils, which I did. I asked if anyone had any other ideas, at which point things got pretty abusive. Now the point is that without evening establishing if I was just wasting time hassling developers into fixing my "problems" for me (I've been on the end of enough of that recently to know how annoying it is), I was being excluded from evening helping out. That is rather an odd attitude for advocates of an open source project to express. I've been following asterisk developement for a long time, and playing with it at home. Recently I have been able to deploy it in a commerial VoIP (SIP) services that I have developed for a client. I am consequently therefore exteremely greatful to *, and cosider it not just a duty, but also an honour to be able to give something back. In 6 years of writing and contributing to Free Software project, I have simply never come across the attitude that I met on that channel. And regardless of the rights or wrongs of it, it is the phrase "#asterisk" I am always going to remember for it, not the specific people involved. By all means dismiss me as an arrogant arse, a prima donna, or whatever else you care to think of. I meant nothing more by that statement than good old fashioned sarcasm. On Sat, Dec 06, 2003 at 02:11:52PM -0500, Brian Capouch wrote: > Tristan 'Minty' Colgate wrote: > > > > > I'd like to thank everyone on #asterisk for all the support they gave to > > a > >fellow linux enthusiast... absoutely none. > > > > That was really a nice post until right at the end here. > > I hope you understand that cheap shots like this just make *you* look > like an asshole, and provide plenty of evidence for everyone reading > that we're dealing with a prima donna. > > AFAIK everyone involved in improving asterisk is plenty busy. You did > the right thing--charging forth into the problem space to see what you > could accomplish--but then you spoiled it at the end by whining at the > rest of us for not helping you. > > B. > > ___________ > Asterisk-Users mailing list > [EMAIL PROTECTED] > http://lists.digium.com/mailman/listinfo/asterisk-users -- Tristan 'Minty' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
[Asterisk-Users] some success with linux 2.6 and wcfxo
Hi , I picked up a x100p the other day and thaught I'd havea go at getting the driver going for linux 2.6, things have gone pretty, two basic problems. 1. makefiles, with 2.6 you can't get away with using the old makefile to build the kernel modules, they will build but you'll get an error along the lines of "no module found in object". This is due to not using the new 2.6 kbuild stuff. I have a working makefile for building the modules now, it's mostly just a case of setting up an obj-m target with all the modules in and building with... make -C /usr/src/linux SUBDIRS=`pwd` modules A few of the modules (the torisa and tor2 ones come to mind), don;t build at all. The others will build but... 2. Interrupt return values now need to be given, if you convert the interrupt handlers to return irqreturn_t, and return IRQ_HANDLED or IRQ_NONE as appropriate (I mostly just guessed here as to whether the driver had done anything useful, not terribly accurate, but it got things going). Without this you get reports of spurious interrupt return values and all other kinds of nasty stuff happens. 3. The module useage stuff is deprecated so currently the modules get marked as unsafe for unloading, this isn't a problem in basic functionality terms though. So building zaptel.ko and wcfxo.ko then insmod'ing those and ztcfg and everthing seems to be up and running, don't know how stable it is really but I can make inbound and outbound calls, all the signalling and alarams stuff seems to be picked up. I'd like to thank everyone on #asterisk for all the support they gave to a fellow linux enthusiast... absoutely none. -- Tristan 'Still Running 2.6, so there :P' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [Asterisk-Users] SIP Context from domain?
Yep, I did a checkout after posting that and noticed the SIPDOMAIN var, it is pretty much ideal for my needs (just pass [EMAIL PROTECTED] to the voicemail app I hope. My only concern is in using the CVS code, but in this case I think it is worth it, I'm using a fairly minimal set of functionatlity from *, I'm just using it for voicemail and PSTN from a SER proxy. On Tue, Nov 18, 2003 at 02:56:32PM -0500, John Todd wrote: > At 8:00 PM +0000 11/18/03, Tristan 'Minty' Colgate wrote: > >From: "Tristan 'Minty' Colgate" <[EMAIL PROTECTED]> > >To: [EMAIL PROTECTED] > >Subject: [Asterisk-Users] SIP Context from domain? > >Reply-To: [EMAIL PROTECTED] > >Date: Tue, 18 Nov 2003 20:00:55 + > > > >Hi, > > > > Is it possible to pick the context of a call from chan_sip based on the > >domain of the To: header of the INVUTE? I've had a quick look throught he > >code > >and can't see anything, I want to use the voicemail virtual hosting with > >chan_sip. Can the sip domain be picked out with a global in > >extensions.conf? > >This woud also solve my problem. > > > > If not is there any specifc reason/restriction that I am missing? If it > > is > >not already supported and there aren't any specific objections then I don't > >mind putting together a patch for it. > > > > I'm working with the last stable release and haven;t checked out CVS yet. > > > >-- > >Tristan 'Minty' Colgate > ><[EMAIL PROTECTED]> | ICQ #154577755 > >--- > > "I don't mean to sound bitter, cold, or cruel, but > > I am, so that's how it comes out" > > - Bill Hicks > > > With some appropriate thought, and a basic understanding of how > Asterisk handles call routing, this recent CVS note should point you > in the right direction. > > JT > > > > >From: [EMAIL PROTECTED] > >To: [EMAIL PROTECTED] > >Subject: [Asterisk-cvs] asterisk README.variables,1.9,1.10 > >Date: Wed, 12 Nov 2003 17:28:02 -0600 (CST) > > > >Update of /usr/cvsroot/asterisk > >In directory mongoose.digium.com:/tmp/cvs-serv6345 > > > >Modified Files: > > README.variables > >Log Message: > >Improve documentation of ${SIPDOMAIN} > > > > > >Index: README.variables > >=== > >RCS file: /usr/cvsroot/asterisk/README.variables,v > >retrieving revision 1.9 > >retrieving revision 1.10 > >diff -u -d -r1.9 -r1.10 > >--- README.variables 11 Nov 2003 20:46:41 - 1.9 > >+++ README.variables 12 Nov 2003 23:54:16 - 1.10 > >@@ -44,7 +44,7 @@ > > ${DNID} Dialed Number Identifier > > ${RDNIS}Redirected Dial Number ID Service > > ${HANGUPCAUSE} Hangup cause on last PRI hangup > >-${SIPDOMAIN}SIP domain (if appropriate) > >+${SIPDOMAIN}SIP destination domain of an inbound call (if appropriate) > > > > There are two reference modes - reference by value and reference by name. > > To refer to a variable with its name (as an argument to a function that > > > >___ > >Asterisk-Cvs mailing list > >[EMAIL PROTECTED] > >http://lists.digium.com/mailman/listinfo/asterisk-cvs > > ___ > Asterisk-Users mailing list > [EMAIL PROTECTED] > http://lists.digium.com/mailman/listinfo/asterisk-users -- Tristan 'Minty' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users
[Asterisk-Users] SIP Context from domain?
Hi, Is it possible to pick the context of a call from chan_sip based on the domain of the To: header of the INVUTE? I've had a quick look throught he code and can't see anything, I want to use the voicemail virtual hosting with chan_sip. Can the sip domain be picked out with a global in extensions.conf? This woud also solve my problem. If not is there any specifc reason/restriction that I am missing? If it is not already supported and there aren't any specific objections then I don't mind putting together a patch for it. I'm working with the last stable release and haven;t checked out CVS yet. -- Tristan 'Minty' Colgate <[EMAIL PROTECTED]> | ICQ #154577755 --- "I don't mean to sound bitter, cold, or cruel, but I am, so that's how it comes out" - Bill Hicks ___ Asterisk-Users mailing list [EMAIL PROTECTED] http://lists.digium.com/mailman/listinfo/asterisk-users