LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-06-2008, 06:27 PM   #16
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41

dam double. sorry guys

Last edited by Lantzvillian; 03-06-2008 at 06:52 PM.
 
Old 03-06-2008, 06:50 PM   #17
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41
Yay it works Even hooked up some fancy dancy Linksys IP phone which sees the asterisk box fine ( although I have to figure out how to configure it to have a specific extension ) and it can call the 4001 number while seeing all registed extensions.

Couple of questions:

In /etc/voicemail.conf

uncomment or add user like so to make a voicemail box right?

4001 => 4242,Sean Comeau,root@localhost

Voicemail? Is that 2nd number arbitrary and some random value?


I then need to add users through extensions.conf too correct?
like:

[fwdincoming]
; call 4001, 874319 is Sean's FWD account
exten => 874321,1,Macro(stdexten,${EXTEN},SIP/${EXTEN})

but where does that UID come from???? is that something I have to get within the asterisk console?

Anyways a quick rundown on how to add a user would be amazing,
thanks.
 
Old 03-07-2008, 06:53 AM   #18
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
Great, first thing you want to do is backup the files you will be editing if you have not done so;
Code:
su
<password>
cd /etc/asterisk
ls
cp sip.conf sip.conf.bak
cp voicemail.conf voicemail.conf.bak
cp extensions.conf extensions.conf.bak
OK now to add the phone in sip.conf
Code:
[phone]
type=friend
username=phone
secret=0000
context=default ; remember this very important in your dialplan
callid=phone
mailbox=2000
host=dynamic
allow=ulaw
now to give it an extension in extensions.conf
Code:
[default] ; under the context above
exten => 2000,1,Dial(SIP/phone,20,)
exten => 2000,n,Voicemail(u2000)
exten => 2000,n,Hangup()
add it to voicemail
Code:
2000 => 0000, 2000 postmaster@localhost
the second is the password
Log into the phone and make sure the settings are the same then;
Code:
asterisk -vvvvvvr
reload
Now leave that open and test it out.
Something like that, you should buy the *BOOK* it is a great way to give back and it will come in handy.
Good Luck and have fun ...

Last edited by comprookie2000; 03-07-2008 at 06:54 AM.
 
Old 03-07-2008, 07:18 AM   #19
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
You can change the context to whatever you want to make it more organized in extentions.conf
At the bottom to reference the default context add include => default
Once I have everything working I like to remove all the commented lines just so I can see it better.
For voicemail.conf I do;
Code:
cd /etc/asterisk
sed '/^\;/d' voicemail.conf > voicemail.conf.txt
If it looks ok I will rename voicemail.conf.txt voicemail.conf
 
Old 03-07-2008, 06:47 PM   #20
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41
No idea why, but for some reason it just won't do voicemail. I setup the phone to recieve the call Slick deal that was, however... if I press voicemail its ringing itself which is the extension 4242( for voicemail right )...maybe my below configuration can explain:

extensions.conf
Code:
exten => 4242,1,Dial(SIP/4001,20,)
exten => 4242,n,Voicemail(u4242)
exten => 4242,n,Hangup()
sip.conf
Code:
[4001]                          ; test
type=friend                     ; allow incoming and outgoing calls
username=4001                   ; username
secret=mytest1                  ;password
context=default;
host=dynamic                    ;require this device to registry with us, can't be in general
fromuser=FromUser 4001          ;
callerid=CallId 4001            ;
mailbox=4242                    ; voicemail box
allow=ulaw
deny=0.0.0.0/0.0.0.0            ; network acls
permit=192.168.2.0/255.255.255.0
voicemail.conf
Code:
[default]
4242=> mytest1,4242 brashr@itas.ca
From the console I get this when I call which might help explain as well: I know this has to be soooo simple.

Executing [4242@default:1] Dial("SIP/4001-b7706760", "SIP/4001|20|") in new stack
-- Called 4001
-- SIP/4001-083b17b8 is ringing
 
Old 03-07-2008, 07:25 PM   #21
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
Change this;
Code:
[default]
4242=> mytest1,4242 brashr@itas.ca
to
Code:
[default]
4242 => 0000, brashr@itas.ca
now reload asterisk then;
dial 8500 with the phone to get to asterisks voicemail
you will need to program the voicemail button on the phone, that is something different.
 
Old 03-10-2008, 06:14 PM   #22
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41
awesome possum thanks very much and I got the phones to do the voicemail correctly as well

This is pretty simple after awhile for basic setup and surprisingly not cryptic web consoles for the phones. Neat!

Next up on my list to do is to set up from the in-comming connections:
Quote:
Extensions like so: ( They already be set up which I think they might be already, but where would I go to check that out )
General Inquiries 1
Accounting 2
Tofino Technical Support 3
Development Team 4
and it looks like we are going through Fugu for our callplan. I imagine they tell you what to do for its usage?

Last edited by Lantzvillian; 03-10-2008 at 06:15 PM.
 
Old 03-10-2008, 07:31 PM   #23
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
Lets say for General Inquiries 111 , in my example lets say [phone] is at the receptionists desk so the [phone] is set up in sip.conf and registered with asterisk so in extensions.conf add something like;
Code:
[incoming]
exten => 111,1,Dial(SIP/phone,20,)
exten => 111,n,Voicemail(u2000)
exten => 111,n,Hangup()
include => default
To explain where the extentions are for people that call in have someone record a greeting explaining the options and have that at the start of your dialplan like so;
Code:
exten => s,1,Answer()
exten => s,n,Wait(2)
exten => s,n,Background(greeting)
exten => s,n,WaitExten()
exten => s,n,Voicemail(2000@default,u)
exten => s,n,Hangup()
exten => s,102,Voicemail(2000@default,b)
exten => #,1,Hangup()  
exten => i,1,Goto(s,5)
exten => h,1,Hangup()
exten => t,1,Playback(vm-goodbye)
exten => t,n,Hangup()
asterisk is so cool that you can do whatever you want, that is why it will replace proprietary PBX's. I am just getting started and there are so many things you can do with it including video.
 
Old 03-10-2008, 07:36 PM   #24
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
I started a site for Asterisk links, you may get something out of it;
http://asterisklinks.com/

Last edited by comprookie2000; 03-10-2008 at 07:58 PM.
 
Old 03-11-2008, 06:15 PM   #25
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41
Ok looked at some of the stuff you posted and this is what I think should work

Code:
[incoming2]
;==============================================
;MAIN MENU
;==============================================

;Does the introduction to the main menu
;----------------------------------------------

exten => s,1,Answer
exten => s,n,Background(thanks)
; "Thanks for calling press 1 to continue"


exten => s,n,WaitExten
exten => 1,1,Goto(submenu,s,1)
exten => 2,1,Hangup

[submenu]
;=============================================
;SUBMENU
;=============================================

;Does the introduction to the submenu:
;---------------------------------------------

exten => s,1,Ringing ; Make them comfortable with 2 seconds of ringback
exten => s,n,Wait,2
exten => s,n,Background(submenuopts) ; "Thanks for calling the inquiries..press 1 for inquiries..press 2 for..."

;Goes to extensions like mentioned in the above recording
;---------------------------------------------

exten => s,n,WaitExten
exten => 1,1,Goto(default,inquiries,1)
exten => 2,1,Goto(default,accounting,2)
exten => 3,1,Goto(default,support,3)
exten => 4,1,Goto(default,development,4)
I also noticed this include you mentioned. Is that like an option for the person calling, if they know the extension of the phone they want to call, they can enter it? For example, Cartman is trying to call Stan, but Cartman knows the extension.. is that the point in time where Cartman can enter it?:

Code:
include => default
 
Old 03-12-2008, 01:42 AM   #26
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
[submenu] <-- this is a context
so in sip.conf
Code:
[4001]                          ; test
type=friend                     ; allow incoming and outgoing calls
username=4001                   ; username
secret=mytest1                  ;password
context=default;               <<<<---- to include this extention 
host=dynamic                    ;require this device to registry with us, can't be in general
fromuser=FromUser 4001          ;
callerid=CallId 4001            ;
mailbox=4242                    ; voicemail box
allow=ulaw
deny=0.0.0.0/0.0.0.0            ; network acls
permit=192.168.2.0/255.255.255.0
 
Old 03-13-2008, 01:03 PM   #27
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41
Still haven't figured out how to do the enter your extension now.. I am thinking something like this?

Code:
[incoming2]
;==============================================
;MAIN MENU
;==============================================

;Does the introduction to the main menu
;----------------------------------------------

exten => s,1,Answer
exten => s,n,Background(thanks)
; "Thanks for calling press 1 to continue"


exten => s,n,WaitExten
exten => 1,1,Goto(submenu,s,1)
exten => 2,1,Hangup

[submenu]
;=============================================
;SUBMENU
;=============================================

;Does the introduction to the submenu:
;---------------------------------------------

exten => s,1,Ringing ; Make them comfortable with 2 seconds of ringback
exten => s,n,Wait,2
exten => s,n,Background(submenuopts) ; "Thanks for calling the inquiries..press 1 for inquiries..press 2 for..."

;Goes to extensions like mentioned in the above recording
;---------------------------------------------

exten => s,n,WaitExten
exten => 1,1,Goto(default,inquiries,1)
exten => 2,1,Goto(default,accounting,2)
exten => 3,1,Goto(default,support,3)
exten => 4,1,Goto(default,development,4)
exten => 5,1,Goto(default,extdefault,5)

[extdefault]

exten => s,1,Answer
exten => s,n,Background(thanks)
; "Enter your extension now..."
exten => s,n,WaitExten
include => default
Also.. I know incoming Telus lines are going through the FXOs.. Where would I put the outbound dialplan that is going to use FUGU so that all calls are routed outwards through that Internet VoIP provider through Eth0??

Last edited by Lantzvillian; 03-13-2008 at 01:11 PM.
 
Old 03-13-2008, 03:00 PM   #28
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
I am no expert but I will explain how mine works and then show another way I could do it if I had a lot of extentions like you will end up with. I would start simple and do one step at a time, call in and at the same time logged in to asterisks console "asterisk vvvvvvr" and see what happens.
Code:
[globals]
;OUTBOUNDTRUNK=SIP/377862XXX ;not needed
[general]
static=yes
writeprotect=no
[default] ;this must refer to the context in sip.conf or iax.conf
exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,Background(greeting)
exten => s,n,WaitExten()
exten => s,n,Voicemail(2000@default,u)
exten => s,n,Hangup()
exten => s,102,Voicemail(2000@default,b)
exten => #,1,Hangup()  
exten => i,1,Playback(tt-monkeys)
exten => i,n,Playback(go-away2)
exten => i,n,Hangup()
exten => h,1,Hangup()
exten => t,1,Playback(vm-goodbye)
exten => t,n,Hangup()
exten => _X.,1,Dial(SIP/377862XXX/${EXTEN}) 
exten => 8500,1,VoicemailMain()
exten => 8500,2,Hangup()
exten => 2000,1,Monitor(wav,podcast-${EPOCH},m)
exten => 2000,n,Dial(SIP/2000@192.168.0.110:5060,30)
exten => 2000,n,(unavail),VoiceMail(2000@default,u)
exten => 2000,n(busy),VoiceMail(2000@default,b)
exten => 2000,n,StopMonitor()
exten => 2000,n,Hangup()
exten => 600,1,Set(MEETME_RECORDINGFILE=/tmp/Podcast-${EPOCH})
exten => 600,2,Meetme(600,DPpisr,1111)
Quote:
Also.. I know incoming Telus lines are going through the FXOs.. Where would I put the outbound dialplan that is going to use FUGU so that all calls are routed outwards through that Internet VoIP provider through Eth0??
use the dial command

now I could break it up to look more organized;

Code:
[general]
static=yes
writeprotect=no
[default]
exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,Background(greeting)
exten => s,n,WaitExten()
exten => s,n,Voicemail(2000@default,u)
exten => s,n,Hangup()
exten => s,102,Voicemail(2000@default,b)
exten => #,1,Hangup()  
exten => i,1,Playback(tt-monkeys)
exten => i,n,Playback(go-away2)
exten => i,n,Hangup()
exten => h,1,Hangup()
exten => t,1,Playback(vm-goodbye)
exten => t,n,Hangup()
[outbound_trunk]
exten => _X.,1,Dial(SIP/377862882/${EXTEN})
include => [phones]
[voicemail] 
exten => 8500,1,VoicemailMain()
exten => 8500,2,Hangup()
include => default
[phones]
exten => 2000,1,Monitor(wav,podcast-${EPOCH},m)
exten => 2000,n,Dial(SIP/2000@192.168.0.110:5060,30)
exten => 2000,n,(unavail),VoiceMail(2000@default,u)
exten => 2000,n(busy),VoiceMail(2000@default,b)
exten => 2000,n,StopMonitor()
exten => 2000,n,Hangup()
include => outbound_trunk
[meetme]
exten => 600,1,Set(MEETME_RECORDINGFILE=/tmp/Podcast-${EPOCH})
exten => 600,2,Meetme(600,DPpisr,1111)
include => default
The FXO will be ZAP/something
 
Old 03-13-2008, 09:01 PM   #29
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 210

Original Poster
Rep: Reputation: 41
Ok, got the VoIP provider information which goes in iax.conf however, its looking for a outbound calling plan.. which is something I haven't set up. I have been looking on the net, but I don't see an example for one that makes much sense for me to understand.

Will you need some of the information that the VoIP persons provided me with?
 
Old 03-13-2008, 09:04 PM   #30
comprookie2000
Gentoo Developer
 
Registered: Feb 2004
Location: Fort Lauderdale FL.
Distribution: Gentoo
Posts: 3,291
Blog Entries: 5

Rep: Reputation: 58
Sure more the better.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Qmail + Asterisk + Hylafax mail2fax configuration havok1977 Linux - Server 2 08-17-2008 01:09 AM
LXer: Installing The Asterisk PBX And The Asterisk Web-Based Provisioning GUI On Linu LXer Syndicated Linux News 0 09-25-2007 02:50 PM
FC6 + Asterisk + DNS Server configuration Ciralia Fedora 2 09-04-2007 03:16 PM
asterisk configuration to make a call PC - PC through asterisk priya001 Linux - Server 0 11-08-2006 06:06 AM
asterisk server priya001 Linux - Server 1 10-30-2006 03:23 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration