Asterisk where is extensions.conf




















The following ; applies to both the busy and unavailable modes of voicemail and can be applied to one ; or both, and differently. No options will ; cause Allison's generic message, 's' will go straight to beep. If the user wishes to enable a mode where a caller can press ; during their message and it goes straight to voicemail with only a 'beep' then ; this should be set to 's'.

A ; duplicate set is included for both unavail and busy. You could choose for to have an ; ivr when unavail is taken, but not with busy - or a different once with busy. Anything but 'enabled' is ; treated as disabled.

It is just a variable to the ; Read function which will do the repeating. A caller can enter a digit any time during the playback. This is ; typically either set to 's' or left blank. When set to 's' there will be no ; message played when entering the voicemail, just a beep. When blank, you will ; have Allison's generic message played. It is not typical to play the greetings ; since they have been 'hijacked' for these IVR's and from a caller's perspecitive ; this system appears interconnected with the voicemail so instructions can be ; left there.

None have to be set and a system default ; will be used. If just ext is set, then defaults will be used for context and ; pri, etc. You can use contexts to separate out functionality and features, enforce security boundaries between the various parts of our dialplan, as well as to provide different classes of service to groups of users. The syntax for a context is exactly the same as any other section heading in the configuration files, as explained in Sections and Settings.

Simply place the context name in square brackets. For example, here we define an example context called 'users'. Within each context, we can define one or more extensions.

An extension is simply a named set of actions. Asterisk will perform each action, in sequence, when that extension number is dialed. The syntax for an extension is:. Within each extension, there must be one or more priorities.

A priority is simply a sequence number. The first priority on an extension is executed first. When it finishes, the second priority is executed, and so forth. Priority numbers Priority numbers must begin with 1, and must increment sequentially. If Asterisk can't find the next priority number, it will terminate the call. We call this auto-fallthrough. Consider the example below:. In this case, Asterisk would execute priorities one and two, but would then terminate the call, because it couldn't find priority number three.

Priority numbers can also be simplified by using the letter n in place of the priority numbers greater than one. This does the initial setup for the channel that receives the incoming call. As we mentioned earlier, Answer takes no arguments. Answer is not always required in fact, in some cases it may not be desirable at all , but it is an effective way to ensure a channel is connected before performing further actions.

Sometimes it is useful to be able to pass information back to the network before answering a call. The Progress application attempts to provide call progress information to the originating channel. Some carriers expect this, and thus you may be able to resolve strange signaling problems by inserting Progress into the dialplan where your incoming calls arrive.

The Playback application is used for playing a previously recorded sound file over a channel. Input from the user is ignored, which means that you would not use Playback in an auto attendant, for example, unless you did not want to accept input at that point. When you compile Asterisk, you can choose to install various sets of sample sounds that have been recorded in a variety of languages and file formats.

Several of the files in our examples come from the Extra Sound Package, so please take the time to install it see Chapter 3, Installing Asterisk.

To use Playback , specify a filename without a file extension as the argument. For example, Playback filename would play the sound file called filename. Note that you can include the full path to the file if you want, like this:. The previous example would play filename. You can also use relative paths from the Asterisk sounds directory, as follows:. This example would play filename. Note that if the specified directory contains more than one file with that filename but with different file extensions, Asterisk automatically plays the best file.

The Hangup application does exactly as its name implies: it hangs up the active channel. The Hangup application does not require any arguments, but you can pass an ISDN cause code if you want e. As we work through the book, we will be introducing you to many more Asterisk applications. With traditional PBXs, there are generally a set of defaults for things like reception, which means that if you forget to define them, they will probably work anyway.

In Asterisk, the opposite is true. If you do not tell Asterisk how to handle every situation, and it comes across something it cannot handle, the call will typically be disconnected. Please note that extension s and priority s are two distinct concepts. When you start Asterisk, it calculates the translation costs between the different audio formats they often vary from system to system.

You can see these translation costs by typing show translation at the Asterisk command-line interface. The numbers shown represent how many milliseconds it takes Asterisk to transcode one second of audio. Dialplan Syntax Prev Chapter 6. Dialplan Basics Next. Dialplan Syntax. Tip The extensions. Sample Configuration Files. Note Context names have a maximum length of 79 characters 80 characters — 1 terminating null. Note This is one of the most important concepts to understand when dealing with channels and dialplans.

Tip Assigning names to extensions may seem like a revolutionary concept, but when you realize that many VoIP transports support or even actively encourage dialing by name or email address rather than just by number, it makes perfect sense. Unnumbered priorities. Priority labels. Tip Occasionally, you may also see the pipe character being used as a separator between arguments, instead of a comma. The Answer , Playback , and Hangup Applications.



0コメント

  • 1000 / 1000