Dear all, I have small question in sip.conf I added [service] type=friend ;username;secretqualify=900 host=X.X.X.X dtmfmode = rfc2833 disallow=all ;allow=g729 allow=gsm allow=alaw allow=ulaw and I can proccess incoming call from soft phone only I calling on number that is used in extensions.conf(in example below it is 1) exten => 1,1,Answer; exten => 1,2,Playback(hello-world,skip); exten => 1,3,Hangup; but when I use next construction(As I understand it is used to allow to process any extension dialed by user) exten => s,1,Answer; exten => s,2,Playback(hello-world,skip); exten => s,3,Hangup; Asterisk says call rejected due to no extension. What is wrong? any body can make spot lighter. Thank in advance.
On Wed, Mar 5, 2008 at 10:12 AM, Daniel Suleyman <danikpro at gmail.com> wrote:> but when I use next construction(As I understand it is used to allow > to process any extension dialed by user) > > exten => s,1,Answer; > exten => s,2,Playback(hello-world,skip); > exten => s,3,Hangup;AFAIK, "s" extension is used in analogue PSTN incoming calls, as the call itself doesn't contain the extension (public telephone number) it tries to reach. If want to catch "any" extension dialed by the user you should use something like this: exten => _.,1,Answer; exten => _.,2,Playback(hello-world,skip); exten => _.,3,Hangup; In any case, I cannot understand why you would like to use it. You should define your extensions and use the invalid extension (i) to catch calls sent to any number not detailed in the dialplan. -- Andres Jimenez GPG : http://www.andresin.com/gpg/gandresin at gmail.com.asc
On Wed, Mar 05, 2008 at 02:12:47PM +0400, Daniel Suleyman wrote:> Dear all, I have small question > > in sip.conf I added > > [service] > type=friend > ;username> ;secret> qualify=900 > host=X.X.X.X > dtmfmode = rfc2833 > disallow=all > ;allow=g729 > allow=gsm > allow=alaw > allow=ulaw > > and I can proccess incoming call from soft phone only I calling on > number that is used in extensions.conf(in example below it is 1) > > exten => 1,1,Answer; > exten => 1,2,Playback(hello-world,skip); > exten => 1,3,Hangup; > > but when I use next construction(As I understand it is used to allow > to process any extension dialed by user) > > exten => s,1,Answer; > exten => s,2,Playback(hello-world,skip); > exten => s,3,Hangup; > > Asterisk says call rejected due to no extension.Chances are you got the wrong context. Have you set a context in sip.conf? Or do you use the defualt one? What is the output of: dialplan show default -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir
Even if I have s in defult it is not work. 2008/3/6, Noah Miller <noahisaacmiller at gmail.com>: > Hi - > > > > Thank you all for answers. As I understand s - i and others is device specific. > > I will not need them in my SIP configuration. > > > The "s" extension is not zap-specific. You can use it for any type of > device. It's just the generic extension that a call will go to when > no other matching extensions are present. As Tzafrir pointed out, you > had no "s" extension in the default context, and your sip device was > in the default context. Therefore, you were only able to dial > extensions that you had explicitly declared. > > To access the "s" extension from your sip device, you'd either need to > add your sip device to the context where your "s" extension is, or > include that context in the default context. > > NOTE: Andres' example using "_." will work, too (but you should make > sure you put in at the end of a context if you want to put other > extensions in that context as it will match all calls). > > > > - Noah > > > > > > > > > > 2008/3/5, Andres Jimenez <gandresin at gmail.com>: > > > > > > > On Wed, Mar 5, 2008 at 1:36 PM, Tzafrir Cohen <tzafrir.cohen at xorcom.com> wrote: > > > > > > > This is not needed. If the extension is not found, there is a > > > > fallthrough to 's' (Right? Or is it chan_zap-specific)? > > > > > > I would say it's chan_zap-specific. > > > > > > From http://www.voip-info.org/wiki/index.php?page=Asterisk+config+extensions.conf > > > > > > "For some kinds of connections ? such incoming calls from an outside > > > telephone line ? the user has not dialed an extension. In that case, > > > Asterisk behaves as if the user had dialed a special extension named > > > "s" (for Start). Asterisk will look for an extension "number" s in the > > > definition of the context for that channel for instructions about what > > > it should do to handle the call. " > > > > > > The key factor is that "s" is used when NO EXTENSION has been > > > specified (when the call is not clearly directed to an specific > > > number). As far as I know, that's the way analog lines behave. The > > > line just receives the call, but no information says to which number > > > the call was sent. > > > > > > > > > -- > > > Andres Jimenez > > > > > > GPG : http://www.andresin.com/gpg/gandresin at gmail.com.asc > > > _______________________________________________ > > > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > > > > > 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 -- > > > > 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 -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users >
On Sat, Mar 08, 2008 at 11:45:14AM +0400, Daniel Suleyman wrote:> Even if I have s in defult it is not work.So please provide a trace of that case: core set verbose 3 And see what happens. -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir