Section 1 Flashcards
How do you setup asterisk?
What are the standard asterisk ports?
Standard SIP Port: UDP 5060
Standard Media Port Range: UDP 10000-20000
IAX2 Standard Port: UDP 4569
What the typical layout of a asterisk based infrastructure?
Where do you create phone extensions?
sip.conf
How can you create a phone extension?
[extension]
type=friend
secret=[password]
disallow=all
allow=alaw
host=dynamic
context=[extension-context]
qualify=yes
Where do you create extension contexts?
extensions.conf
What does sip reload do?
reloads the sip.conf file
How do you reload all configuration files?
reload
Where do you create voicemails?
voicemail.conf
How do you create a simple voicemail?
[exten] => [password],[name],[email]
e.g.
[internal-vm]
101 => 123456,John Doe,john-email@gmail.com
Then add in sip.conf:
mailbox=101@internal-vm
How do you set a dialplan to go to a voicemail?
exten => 1,1,Answer
exten => 1,n,NoOp(This-is-a-sample-context)
exten => 1,n,Voicemail(101@internal-vm)
exten => 1,n,Hangup()
How do you set a dialplan to dial a number?
exten => 101,1,Answer
exten => 101,n,NoOp(internal-phone-call)
exten => 101,n,Dial([protocol]/[trunk]/[number], [call-time], [options]);
exten => 101,n,Hangup()
Note: You can exclude a trunk if it is an internal call
Why after the following dial plan does the call not go to voicemail after answer?
exten => 101,1,Answer
exten => 101,n,NoOp(internal-phone-call)
exten => 101,n,Dial(SIP/101,12,r);
exten => 101,n,Hangup()
Because the ‘g’ option was not specified, without the ‘g’ option, when an answered call is hungup the dial plan execution wont continue
What are the default standard extensions?
- s: Start. Used primarily for dialplans that enter a context with no other extension information. Think of a non DID phone line, call comes in, and we may only know that the line is ringing and nothing else. Even if you knew callerid, you have to still have a place to start. You can also think about s as a place to place part of the dialplan that you don’t want callers to get back to unless they have passed through other functions.
- t: Timeout. Used for when calls have been inactive after a prompt was played. Also used to hang up a line that has been idle.
- T: AbsoluteTimeout. Used for calls that have been hung up due to an AbsoluteTimeout() being reached. For example useful to play a notification with Playback().
- h: Hangup. Used to clean up a call. Could be used to play a goodbye message before hanging up. Also seemingly used by the calling card people to record end of call for billing purposes. h won’t run if the call is parked. More…
- i: Used when dialling an unknown extension in a context or unknown input in an IVR menu
Why do you need to register with a SIP trunk?
You need to register so that the trunk provider knows where to route calls to when an inbound call comes in