Re: [asterisk-users] One server, multiple companies
Sorry for the late follow-up to this... it was on my to-do list for over a month... Sigh. I've submitted a configuration bug and for this: http://bugs.digium.com/view.php?id=11969 The hope being that if the examples provided in the configs/ directory work better out of the box for real-world applications (like virtual hosting), then more people will benefit... thus bringing world peace and ending global warming. If you want to encourage the bug marshals to approve these changes and get them into the source tree, I won't discourage you. Oh, and for the record: in my sip context for peering with my PSTN carrier, I do a Goto the appropriate context (acme-incoming,s,1 etc) based on the DID / DNIS coming in from the carrier... something akin to what Jerry is doing below, but slightly more complicated (some companies have a single shared outside number, others have individual DID's per extension, etc). -Philip Jerry Jones wrote: [incoming] exten = 2125551211,1,GoTo(companyA,1) exten = 2125551212,1,GoTo(companyB,1) exten = 2125551213,1,GoTo(companyC,1) [companyA] exten = 2000,1,Dial() [companyB] exten = 2000,1,Dial() [companyC] exten = 2000,1,Dial() On Dec 13, 2007, at 5:53 PM, Diego Andrés Asenjo González wrote: -- Mensaje reenviado -- From: Eric C. [EMAIL PROTECTED] To: asterisk-users@lists.digium.com Date: Sun, 9 Dec 2007 19:55:51 -0500 Subject: [asterisk-users] One server, multiple companies Hello all, Just starting to setup asterisk v 1.4.11 and need to run three distinct phone systems for three different companies. So far, I have inbound lines going to the appropriate dial plan within the extensions.conf file. I'm using exten = _X.,1,NoOp(FROM NUMBER: ${SIP_HEADER(TO):5:10}) to determine which number is being dialed by the caller and then using a gotoif to get to correct greeting (correct company). My question is... lets assume all three companies have extension numbers being 2000, 2001 2002, how does one separate them? Or, lets say the extensions are: company A -- 2000, 2001,2002 company B -- 3000, 3001, 3002 company C -- 4000, 4001, 4002 Since they're on one server with one asterisk process, how can I use context correctly so that the user at 4002 cannot get through to the user at company A whose extension is 2000 as currently, I can dial 2000 from phone 4002. That's my current problem, how should this be setup? Is my architecture correct? Should I be running different processes for each company? Can context resolve what I need? Hi, You should try DeStar, a management interface for Asterisk: http://destar.berlios.de/ DeStar supports Virtual PBXs, then you can install it and take a look at the dialplan. Sorry for the late answer but I've just read the list messages. Bye, Diego Andrés. So Please advise. thanks, Otto ___ -- 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
Re: [asterisk-users] One server, multiple companies
[incoming] exten = 2125551211,1,GoTo(companyA,1) exten = 2125551212,1,GoTo(companyB,1) exten = 2125551213,1,GoTo(companyC,1) [companyA] exten = 2000,1,Dial() [companyB] exten = 2000,1,Dial() [companyC] exten = 2000,1,Dial() On Dec 13, 2007, at 5:53 PM, Diego Andrés Asenjo González wrote: -- Mensaje reenviado -- From: Eric C. [EMAIL PROTECTED] To: asterisk-users@lists.digium.com Date: Sun, 9 Dec 2007 19:55:51 -0500 Subject: [asterisk-users] One server, multiple companies Hello all, Just starting to setup asterisk v 1.4.11 and need to run three distinct phone systems for three different companies. So far, I have inbound lines going to the appropriate dial plan within the extensions.conf file. I'm using exten = _X.,1,NoOp(FROM NUMBER: ${SIP_HEADER(TO):5:10}) to determine which number is being dialed by the caller and then using a gotoif to get to correct greeting (correct company). My question is... lets assume all three companies have extension numbers being 2000, 2001 2002, how does one separate them? Or, lets say the extensions are: company A -- 2000, 2001,2002 company B -- 3000, 3001, 3002 company C -- 4000, 4001, 4002 Since they're on one server with one asterisk process, how can I use context correctly so that the user at 4002 cannot get through to the user at company A whose extension is 2000 as currently, I can dial 2000 from phone 4002. That's my current problem, how should this be setup? Is my architecture correct? Should I be running different processes for each company? Can context resolve what I need? Hi, You should try DeStar, a management interface for Asterisk: http://destar.berlios.de/ DeStar supports Virtual PBXs, then you can install it and take a look at the dialplan. Sorry for the late answer but I've just read the list messages. Bye, Diego Andrés. So Please advise. thanks, Otto ___ --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
Re: [asterisk-users] One server, multiple companies
-- Mensaje reenviado -- From: Eric C. [EMAIL PROTECTED] To: asterisk-users@lists.digium.com Date: Sun, 9 Dec 2007 19:55:51 -0500 Subject: [asterisk-users] One server, multiple companies Hello all, Just starting to setup asterisk v 1.4.11 and need to run three distinct phone systems for three different companies. So far, I have inbound lines going to the appropriate dial plan within the extensions.conf file. I'm using exten = _X.,1,NoOp(FROM NUMBER: ${SIP_HEADER(TO):5:10}) to determine which number is being dialed by the caller and then using a gotoif to get to correct greeting (correct company). My question is... lets assume all three companies have extension numbers being 2000, 2001 2002, how does one separate them? Or, lets say the extensions are: company A -- 2000, 2001,2002 company B -- 3000, 3001, 3002 company C -- 4000, 4001, 4002 Since they're on one server with one asterisk process, how can I use context correctly so that the user at 4002 cannot get through to the user at company A whose extension is 2000 as currently, I can dial 2000 from phone 4002. That's my current problem, how should this be setup? Is my architecture correct? Should I be running different processes for each company? Can context resolve what I need? Hi, You should try DeStar, a management interface for Asterisk: http://destar.berlios.de/ DeStar supports Virtual PBXs, then you can install it and take a look at the dialplan. Sorry for the late answer but I've just read the list messages. Bye, Diego Andrés. So Please advise. thanks, Otto ___ --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
Re: [asterisk-users] One server, multiple companies
Eric C. wrote: Hello all, Just starting to setup asterisk v 1.4.11 and need to run three distinct phone systems for three different companies. So far, I have inbound lines going to the appropriate dial plan within the extensions.conf file. I'm using exten = _X.,1,NoOp(FROM NUMBER: ${SIP_HEADER(TO):5:10}) to determine which number is being dialed by the caller and then using a gotoif to get to correct greeting (correct company). My question is... lets assume all three companies have extension numbers being 2000, 2001 2002, how does one separate them? Or, lets say the extensions are: company A -- 2000, 2001,2002 company B -- 3000, 3001, 3002 company C -- 4000, 4001, 4002 Since they're on one server with one asterisk process, how can I use context correctly so that the user at 4002 cannot get through to the user at company A whose extension is 2000 as currently, I can dial 2000 from phone 4002. That's my current problem, how should this be setup? Is my architecture correct? Should I be running different processes for each company? Can context resolve what I need? Please advise. thanks, Otto First off, *nuke* the default context in sip.conf, extensions.conf, and voicemail.conf ... it will just get you into trouble! I do something like in my extensions.conf file: [incoming] exten = 208229,1,Goto(s,1,incoming-acme) exten = 208229,1,Goto(s,1,incoming-fido) exten = 208229,1,Goto(s,1,incoming-big-jims) ... [incoming-acme] exten = s,1,Answer() exten = s,n,Wait(0.75) exten = s,n(greeting),Playback(brief-directory-acme) exten = s,n(exten),Background(vm-enter-num-to-call) exten = s,n,WaitExten(5) exten = s,n(goodbye),Playback(vm-goodbye) exten = s,n(end),Hangup() ; these are the extensions that are exposed both to internal callers as ; well as to incoming calls... be careful what you put here. include = extens-acme exten = i,1,Playback(pbx-invalid) exten = i,n,Goto(s,exten) exten = t,1,Goto(s,goodbye) [internal-acme] exten = s,1,Answer() exten = s,n(exten),Background(vm-enter-num-to-call) exten = s,n,WaitExten(5) exten = s,n(goodbye),Playback(vm-goodbye) exten = s,n(end),Hangup() include = outbound-toll include = outbound-local include = extens-acme ; for our SIP phones, we can program a non-numeric extension exten = voicemail,1,VoicemailMain([EMAIL PROTECTED]) exten = voicemail,n,Hangup() ; and for DTMF coming through an ATA... exten = 777,1,Goto(voicemail) [extens-acme] exten = 111,1,Macro(stdexten,111,${PHILIP}) exten = 111,n,Goto(s,exten) ... [outbound-local] exten = _NXX,1,Dial(${TRUNK}/${AREA}${EXTEN},,r) exten = _NXX,n,Congestion() exten = _NXX,n,Hangup() [outbound-toll] exten = _NX,1,Dial(${TRUNK}/${EXTEN},,r) exten = _NX,n,Congestion() exten = _NX,n,Hangup() exten = _011.,1,Dial(${TRUNK}/${EXTEN:3},,r) exten = _011.,n,Congestion() exten = _011.,n,Hangup() Note: we had to modify the stdexten macro to be: [macro-stdexten]; ; ; Standard extension macro: ; ${ARG1} - Extension (we could have used ${MACRO_EXTEN} here as well) ;
Re: [asterisk-users] One server, multiple companies
Contexts Its all about Contexts. You can place the three groups of extensions/ dial plans in different contexts. The only dilemma you are going to encounter is that all three companies will need to share the same company directory, and the same parking lot (For ParK) However, may orgs do the same thing- Eric C. wrote: Eric C. wrote: Hello all, Just starting to setup asterisk v 1.4.11 and need to run three distinct phone systems for three different companies. So far, I have inbound lines going to the appropriate dial plan within the extensions.conf file. I'm using exten = _X.,1,NoOp(FROM NUMBER: ${SIP_HEADER(TO):5:10}) to determine which number is being dialed by the caller and then using a gotoif to get to correct greeting (correct company). My question is... lets assume all three companies have extension numbers being 2000, 2001 2002, how does one separate them? Or, lets say the extensions are: company A -- 2000, 2001,2002 company B -- 3000, 3001, 3002 company C -- 4000, 4001, 4002 Since they're on one server with one asterisk process, how can I use context correctly so that the user at 4002 cannot get through to the user at company A whose extension is 2000 as currently, I can dial 2000 from phone 4002. That's my current problem, how should this be setup? Is my architecture correct? Should I be running different processes for each company? Can context resolve what I need? Please advise. thanks, Otto First off, *nuke* the default context in sip.conf, extensions.conf, and voicemail.conf ... it will just get you into trouble! I do something like in my extensions.conf file: [incoming] exten = 208229,1,Goto(s,1,incoming-acme) exten = 208229,1,Goto(s,1,incoming-fido) exten = 208229,1,Goto(s,1,incoming-big-jims) ... [incoming-acme] exten = s,1,Answer() exten = s,n,Wait(0.75) exten = s,n(greeting),Playback(brief-directory-acme) exten = s,n(exten),Background(vm-enter-num-to-call) exten = s,n,WaitExten(5) exten = s,n(goodbye),Playback(vm-goodbye) exten = s,n(end),Hangup() ; these are the extensions that are exposed both to internal callers as ; well as to incoming calls... be careful what you put here. include = extens-acme exten = i,1,Playback(pbx-invalid) exten = i,n,Goto(s,exten) exten = t,1,Goto(s,goodbye) [internal-acme] exten = s,1,Answer() exten = s,n(exten),Background(vm-enter-num-to-call) exten = s,n,WaitExten(5) exten = s,n(goodbye),Playback(vm-goodbye) exten = s,n(end),Hangup() include = outbound-toll include = outbound-local include = extens-acme ; for our SIP phones, we can program a non-numeric extension exten = voicemail,1,VoicemailMain([EMAIL PROTECTED]) exten = voicemail,n,Hangup() ; and for DTMF coming through an ATA... exten = 777,1,Goto(voicemail) [extens-acme] exten = 111,1,Macro(stdexten,111,${PHILIP}) exten = 111,n,Goto(s,exten) ... [outbound-local] exten = _NXX,1,Dial(${TRUNK}/${AREA}${EXTEN},,r) exten = _NXX,n,Congestion() exten = _NXX,n,Hangup() [outbound-toll] exten = _NX,1,Dial(${TRUNK}/${EXTEN},,r) exten = _NX,n,Congestion() exten = _NX,n,Hangup() exten = _011.,1,Dial(${TRUNK}/${EXTEN:3},,r) exten = _011.,n,Congestion() exten = _011.,n,Hangup() Note: we had to modify the stdexten
Re: [asterisk-users] One server, multiple companies
Matthew Mackes wrote: Contexts Its all about Contexts. You can place the three groups of extensions/ dial plans in different contexts. The only dilemma you are going to encounter is that all three companies will need to share the same company directory, and the same parking lot (For ParK) (a) not quite true that they have to share the same company directory -- the directory command takes a voicemail context so you put the staff names/voicemail accounts into separate voicemail contexts and thus keep the company directories separate; (b) call parking is a problem -- the standard call parking mechanism cannot be partitioned into different groups/contexts. There are replacements for the call parking mechanism that allows one to have separate independent parking lots but I have not tried any of them. The other approach is to use some form of server virtualisation such as OpenVZ and to run a separate independent copy of Asterisk for each company (in a separate virtual server). The downside is the additional complexity of setting up the virtual servers -- the upside is that not only can you provide call parking to each company, you can even provide tools such as the AsteriskGUI or FreePBX to each company so they can manage their own configuration without seeing the other companies' dialplans. -- George Pajari (dCAP), netVOICE communications 604 484 VOIP(8647) x102 www.netvoice.ca www.ip-centrex.ca www.ip-pbx.ca www.vpas.ca www.digium.ca www.grandstream.ca www.sipura.ca www.snom.ca Open Source VoIP/Telephony Specialists 1 877 NET VOIP (638 8647 x102) ___ --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
Re: [asterisk-users] One server, multiple companies
Eric C. wrote: Hello all, Just starting to setup asterisk v 1.4.11 and need to run three distinct phone systems for three different companies. So far, I have inbound lines going to the appropriate dial plan within the extensions.conf file. I'm using exten = _X.,1,NoOp(FROM NUMBER: ${SIP_HEADER(TO):5:10}) to determine which number is being dialed by the caller and then using a gotoif to get to correct greeting (correct company). My question is... lets assume all three companies have extension numbers being 2000, 2001 2002, how does one separate them? Or, lets say the extensions are: company A -- 2000, 2001,2002 company B -- 3000, 3001, 3002 company C -- 4000, 4001, 4002 Since they're on one server with one asterisk process, how can I use context correctly so that the user at 4002 cannot get through to the user at company A whose extension is 2000 as currently, I can dial 2000 from phone 4002. That's my current problem, how should this be setup? Is my architecture correct? Should I be running different processes for each company? Can context resolve what I need? Please advise. thanks, Otto First off, *nuke* the default context in sip.conf, extensions.conf, and voicemail.conf ... it will just get you into trouble! I do something like in my extensions.conf file: [incoming] exten = 208229,1,Goto(s,1,incoming-acme) exten = 208229,1,Goto(s,1,incoming-fido) exten = 208229,1,Goto(s,1,incoming-big-jims) ... [incoming-acme] exten = s,1,Answer() exten = s,n,Wait(0.75) exten = s,n(greeting),Playback(brief-directory-acme) exten = s,n(exten),Background(vm-enter-num-to-call) exten = s,n,WaitExten(5) exten = s,n(goodbye),Playback(vm-goodbye) exten = s,n(end),Hangup() ; these are the extensions that are exposed both to internal callers as ; well as to incoming calls... be careful what you put here. include = extens-acme exten = i,1,Playback(pbx-invalid) exten = i,n,Goto(s,exten) exten = t,1,Goto(s,goodbye) [internal-acme] exten = s,1,Answer() exten = s,n(exten),Background(vm-enter-num-to-call) exten = s,n,WaitExten(5) exten = s,n(goodbye),Playback(vm-goodbye) exten = s,n(end),Hangup() include = outbound-toll include = outbound-local include = extens-acme ; for our SIP phones, we can program a non-numeric extension exten = voicemail,1,VoicemailMain([EMAIL PROTECTED]) exten = voicemail,n,Hangup() ; and for DTMF coming through an ATA... exten = 777,1,Goto(voicemail) [extens-acme] exten = 111,1,Macro(stdexten,111,${PHILIP}) exten = 111,n,Goto(s,exten) ... [outbound-local] exten = _NXX,1,Dial(${TRUNK}/${AREA}${EXTEN},,r) exten = _NXX,n,Congestion() exten = _NXX,n,Hangup() [outbound-toll] exten = _NX,1,Dial(${TRUNK}/${EXTEN},,r) exten = _NX,n,Congestion() exten = _NX,n,Hangup() exten = _011.,1,Dial(${TRUNK}/${EXTEN:3},,r) exten = _011.,n,Congestion() exten = _011.,n,Hangup() Note: we had to modify the stdexten macro to be: [macro-stdexten]; ; ; Standard extension macro: ; ${ARG1} - Extension (we could have used ${MACRO_EXTEN} here as well) ;