Updates (Sticky)

December 27 2008

I tried upgrading to the latest GUI:

ipkg remove asterisk14-gui
ipkg install asterisk-gui

but had some problems with the CDR reader. While the
interface seems a little nicer, i would stay with
asterisk14-gui for now.

August 27 2008

I reinstalled asterisk on the slug today using
my instructions. It all seemed to work OK!

I did make a couple of minor changes: I added some
code under the Platform step to automatically start
asterisk on reboot; I also updated the version numbers
of the asterisk software for the ipkg install step.

FWD is no linger free. It can still be used
as an example of SIP trunking.

May 13 2008

I added a bit of an explanation to Step 3 on how
to allow all calls to go out. The original dialplan
blocks long distance calls by default (other than
to toll free numbers).

Friday, December 28, 2007

Fourth Step (Voicemail)

This took me a while to figure out!

Step 1

If you are using the extensions.conf script from the previous step you can skip to Step 2, if not make a voicemail extension in the Asterisk GUI. Easily done by navigating to the voicemail tab. For the record Asterisk will add the following entry to [default] in extensions.conf (using 6000 as an example extension):

exten => 6000,1,VoiceMailMain

The default password for checking voicemail is 1234 and is set in users.conf. You can set that to whatever you want by editing:


vmsecret = 1234

Step 2

Now we have to make some sendmail edits:
cd /opt/etc/mail
and edit
sendmail.cf
and modify the following:
# "Smart" relay host (may be null)
DSfqdn.smtp.adddress.of.your.ISP

Step 3

Modify the mailcmd line in voicemail.conf:


; You can override the default program to send e-mail if you wish, too
mailcmd = /opt/sbin/sendmail -t -f asterisk@the.fqdn.of.site

Step 4

You'll need to use wav49 as the format for writing voicemail files as the NSLU2 doesn't really have the horsepower to support the other formats. Edit voicemail.conf and modify the format line:

;format=g723sf|wav49|wav
format = wav49
;

Step 5

Go to the GUI and enter the email address of extension 6002. When they recieve a voicemail it will be sent to their email account as a wav file.

I have found that the Asterisk GUI does not directly modify the voicemail.conf when you add a new extension. I'm not sure if this is correct or not, but voicemail becomes activated nonetheless. The GUI only adds an entry to extensions.conf.

The voicemail.conf file should look like this:

;!
;! Automatically generated configuration file
;! Filename: voicemail.conf (/opt/etc/asterisk/voicemail.conf)
;! Generator: Manager
;! Creation Date: Sat Dec 15 17:08:56 2007
;!
[general]
; Default formats for writing Voicemail
;format=g723sf|wav49|wav
format = wav49
;
; WARNING:
; If you change the list of formats that you record voicemail in
; when you have mailboxes that contain messages, you _MUST_ absolutely
; manually go through those mailboxes and convert/delete/add the
; the message files so that they appear to have been stored using
; your new format list. If you don't do this, very unpleasant
; things may happen to your users while they are retrieving and
; manipulating their voicemail.
;
; In other words: don't change the format list on a production system
; unless you are _VERY_ sure that you know what you are doing and are
; prepared for the consequences.
;
; Who the e-mail notification should appear to come from
serveremail = asterisk
;serveremail=asterisk@linux-support.net
; Should the email contain the voicemail as an attachment
attach = yes
; Maximum length of greetings in seconds
;maxgreet=60
; How many miliseconds to skip forward/back when rew/ff in message playback
skipms = 3000
; How many seconds of silence before we end the recording
maxsilence = 6
; Silence threshold (what we consider silence, the lower, the more sensitive)
silencethreshold = 128
; Max number of failed login attempts
maxlogins = 3
; If you need to have an external program, i.e. /usr/bin/myapp called when a
; voicemail is left, delivered, or your voicemailbox is checked, uncomment
; this:
;externnotify=/usr/bin/myapp
; If you need to have an external program, i.e. /usr/bin/myapp called when a
; voicemail password is changed, uncomment this:
;externpass=/usr/bin/myapp
; For the directory, you can override the intro file if you want
;directoryintro=dir-intro
; The character set for voicemail messages can be specified here
;charset=ISO-8859-1
; The ADSI feature descriptor number to download to
;adsifdn=0000000F
; The ADSI security lock code
;adsisec=9BDBF7AC
; The ADSI voicemail application version number.
;adsiver=1
; Skip the "[PBX]:" string from the message title
;pbxskip=yes
; Change the From: string
;fromstring=The Asterisk PBX
; Permit finding entries for forward/compose from the directory
;usedirectory=yes
;
; Change the from, body and/or subject, variables:
; VM_NAME, VM_DUR, VM_MSGNUM, VM_MAILBOX, VM_CALLERID, VM_CIDNUM,
; VM_CIDNAME, VM_DATE
;
; Note: The emailbody config row can only be up to 512 characters due to a
; limitation in the Asterisk configuration subsystem.
;emailsubject=[PBX]: New message ${VM_MSGNUM} in mailbox ${VM_MAILBOX}
; The following definition is very close to the default, but the default shows
; just the CIDNAME, if it is not null, otherise just the CIDNUM, or "an unknown
; caller", if they are both null.
;emailbody=Dear ${VM_NAME}:\n\n\tjust wanted to let you know you were just left a ${VM_DUR} long message (number ${VM_MSGNUM})\nin mailbox ${VM_MAILBOX} from ${VM_CALLERID}, on ${VM_DATE}, so you might\nwant to check it when you get a chance. Thanks!\n\n\t\t\t\t--Asterisk\n
;
; You can also change the Pager From: string, the pager body and/or subject.
; The above defined variables also can be used here
;pagerfromstring=The Asterisk PBX
;pagersubject=New VM
;pagerbody=New ${VM_DUR} long msg in box ${VM_MAILBOX}\nfrom ${VM_CALLERID}, on ${VM_DATE}
;
; Set the date format on outgoing mails. Valid arguments can be found on the
; strftime(3) man page
;
; Default
emaildateformat = %A, %B %d, %Y at %r
; 24h date format
;emaildateformat=%A, %d %B %Y at %H:%M:%S
;
; You can override the default program to send e-mail if you wish, too
;
mailcmd = /opt/sbin/sendmail -t -f asterisk@the.fqdn.of.site
;servermail=
;
; Users may be located in different timezones, or may have different
; message announcements for their introductory message when they enter
; the voicemail system. Set the message and the timezone each user
; hears here. Set the user into one of these zones with the tz= attribute
; in the options field of the mailbox. Of course, language substitution
; still applies here so you may have several directory trees that have
; alternate language choices.
;
; Look in /usr/share/zoneinfo/ for names of timezones.
; Look at the manual page for strftime for a quick tutorial on how the
; variable substitution is done on the values below.
;
; Supported values:
; 'filename' filename of a soundfile (single ticks around the filename
; required)
; ${VAR} variable substitution
; A or a Day of week (Saturday, Sunday, ...)
; B or b or h Month name (January, February, ...)
; d or e numeric day of month (first, second, ..., thirty-first)
; Y Year
; I or l Hour, 12 hour clock
; H Hour, 24 hour clock (single digit hours preceded by "oh")
; k Hour, 24 hour clock (single digit hours NOT preceded by "oh")
; M Minute, with 00 pronounced as "o'clock"
; N Minute, with 00 pronounced as "hundred" (US military time)
; P or p AM or PM
; Q "today", "yesterday" or ABdY
; (*note: not standard strftime value)
; q "" (for today), "yesterday", weekday, or ABdY
; (*note: not standard strftime value)
; R 24 hour time, including minute
;
;
;
; Each mailbox is listed in the form <mailbox>=<password>,<name>,<email>,<pager_email>,<options>
; if the e-mail is specified, a message will be sent when a message is
; received, to the given mailbox. If pager is specified, a message will be
; sent there as well. If the password is prefixed by '-', then it is
; considered to be unchangable.
;
; Advanced options example is extension 4069
; NOTE: All options can be expressed globally in the general section, and
; overriden in the per-mailbox settings, unless listed otherwise.
;
; tz=central ; Timezone from zonemessages above. Irrelevant if envelope=no.
; attach=yes ; Attach the voicemail to the notification email *NOT* the pager email
; saycid=yes ; Say the caller id information before the message. If not described,
; or set to no, it will be in the envelope
; cidinternalcontexts=intern ; Internal Context for Name Playback instead of extension digits when saying caller id.
; sayduration=no ; Turn on/off the duration information before the message. [ON by default]
; saydurationm=2 ; Specify the minimum duration to say. Default is 2 minutes
dialout = from-vm ; Context to dial out from [option 4 from the advanced menu]
; if not listed, dialing out will not be permitted
sendvoicemail = yes ; Context to Send voicemail from [option 5 from the advanced menu]
; if not listed, sending messages from inside voicemail will not be
; permitted
; searchcontexts=yes ; Current default behavior is to search only the default context
; if one is not specified. The older behavior was to search all contexts.
; This option restores the old behavior [DEFAULT=no]
callback = from-vm ; Context to call back from
; if not listed, calling the sender back will not be permitted
; review=yes ; Allow sender to review/rerecord their message before saving it [OFF by default
; operator=yes ; Allow sender to hit 0 before/after/during leaving a voicemail to
; reach an operator [OFF by default]
; envelope=no ; Turn on/off envelope playback before message playback. [ON by default]
; This does NOT affect option 3,3 from the advanced options menu
; delete=yes ; After notification, the voicemail is deleted from the server. [per-mailbox only]
; This is intended for use with users who wish to receive their voicemail ONLY by email.
; Note: deletevoicemail is provided as an equivalent option for Realtime configuration.
nextaftercmd = yes ; Skips to the next message after hitting 7 or 9 to delete/save current message.
deletevoicemail = yes
envelope = no
operator = no
review = no
saycid = yes
sayduration = no
maxgreet = 60
attachfmt = wav49
maxmessage = 60
maxmsg = 25
minmessage = 1
; [global option only at this time]
; forcename=yes ; Forces a new user to record their name. A new user is
; determined by the password being the same as
; the mailbox number. The default is "no".
; forcegreetings=no ; This is the same as forcename, except for recording
; greetings. The default is "no".
; hidefromdir=yes ; Hide this mailbox from the directory produced by app_directory
; The default is "no".
[zonemessages]
;eastern=America/New_York|'vm-received' Q 'digits/at' IMp
;central=America/Chicago|'vm-received' Q 'digits/at' IMp
;central24=America/Chicago|'vm-received' q 'digits/at' H N 'hours'
;military=Zulu|'vm-received' q 'digits/at' H N 'hours' 'phonetic/z_p'
[default]

2 comments:

Anonymous said...

Who knows where to download XRumer 5.0 Palladium?
Help, please. All recommend this program to effectively advertise on the Internet, this is the best program!

Hosted PBX Providers said...

Thanks for sharing your info. I truly appreciate your efforts and I am waiting for your next post thank you
once again.