Below is my Level3 SIP trunk config that worked with Elastix. Their config is kind of weird. Inbound calls come on port 5060 UDP and outgoing 5070 UDP.
Peer Details:
username=??????
secret=??????
type=friend
qualify=no
port=5070
nat=yes
insecure=very
host=4.55.44.16
allow=all
context=from-trunk
dtmfmode=auto
canreinvite=yes
User Details:
type=peer
dtmfmode=auto
context=from-pstn
host=4.55.44.16
I could find the default password for the Cisco 8961 9951 9971 anywhere is Cisco documentation. The default password is Cisco.
Today I’m going to discuss how to fix the Elastix 2.x music on hold problems. I’m not sure if you noticed this but you cannot upload an MP3 file in Elastix and make it work. There are a few programs that need to be on the server to make it work and you need to delete the old recordings. I didn’t like doing manual audio file conversions so I thought I figure this out. Below are the steps I took to make this work.
SSH into you box
1.
First install sox
[root@elastix ~]# yum install sox
2.
You need to install mpg123. You can get the wget command and download it from this site.
http://pkgs.repoforge.org/mpg123/
I’m running a 64bit version so I downloaded x86_64
[root@elastix ~]#wget http://pkgs.repoforge.org/mpg123/mpg123-1.13.3-1.el5.rf.x86_64.rpm
[root@elastix ~]#rpm -i mpg123-1.13.3-1.el5.rf.x86_64.rpm
3.
Here is the trick, once you have uploaded your files and the conversion is successful you need to go into the mohmp3 directory and delete all files that have *.gsm file extension.
Login into you phone system with SSH or secure ftp. I prefer secure ftp because its easier to create, delete directories and files.
delete every file with a .gsm file extension in /var/lib/asterisk/mohmp3/
Its pretty stupid but your newly converted files will not play if those files are in the directory.
This guide is to show you how to upgrade Trixbox 2.6.x or 2.8.x to Elastix. I have tested this with Trixbox 2.6.3 and Elastix 2.0.3 but this should work with most versions. It seems like development has stalled on Trixbox CE so I decided to start moving my customers over to Elastix. My only solution before this was to completely reprogram the phone system from Scratch. Some of my Customers are call centers with allot of queues and 100+ phones so were taking about allot of programming. Below are the steps I took to make it work
1.
First backup your Trixbox
Trixbox 2.6.x left out the freepbx backup and restore module which I thought was better then the Trixbox backup. You will have to go to the module admin and upload it
First down load the module from freepbx
http://www.freepbx.org/trac/browser/modules/release/2.5/backup-2.5.0.2.tgz
Go to module admin / upload module/ browse for the module you just downloaded / manage modules locally / scroll down to the backup & restore module / click on install / process / apply changes
Now go to tools / backup & restore and do a complete backup of your phone system.
The backup file is store in /var/lib/asterisk/backups.
You will need a ftp utility to get the file off the server. I use coretfp, its free and easy to use.
You should also backup the tftpboot folder is you want to save your phone config files.
2.
Now that you have a backup of your Trixbox system login into your newly installed Elastix system. We first need to copy over the backup file to Elastix
Since Elastix has not backed anything up yet a backups folder does not exist on the system. You will need to create this folder in SSH or some sFTP client
SSH
[root@elastix]# cd /var/lib/asterisk
[root@elastix]# mkdir backups
Now copy your Trixbox backup to
/var/lib/asterisk/backups
3.
Log into Elastix and click on PBX. Click on unembedded freePBX. This should open another windows. Login and now you should be in unembedded freePBX. Click on tools / backup & restore. On the right hand side click on restore backup.
You should now see the trixbox backup file. Click on it and do a Restore Full Backup Set. Is a few seconds you should see that ugly green Trixbox version of freePBX. Do not click the orange apply bar yet
Clicking the orange apply bar at this point will not do anything. The problem here is that Elastix and Trixbox use two different Asterisk Manager passwords. Elastix uses elastix456 and trixbox used amp111.
SSH into your box to go to
[root@elastix]# cd /etc/asterisk
[root@elastix]# nano manager.conf
Config should look like this.
;
; AMI – Asterisk Manager interface
;
; FreePBX needs this to be enabled. Note that if you enable it on a different IP, you need
; to assure that this can’t be reached from un-authorized hosts with the ACL settings (permit/deny).
; Also, remember to configure non-default port or IP-addresses in amportal.conf.
;
; The AMI connection is used both by the portal and the operator’s panel in FreePBX.
;
; FreePBX assumes an AMI connection to localhost:5038 by default.
;
[general]
enabled = yes
port = 5038
bindaddr = 0.0.0.0
[admin]
secret = elastix456
deny=0.0.0.0/0.0.0.0
permit=127.0.0.1/255.255.255.0
permit=192.168.1.99/255.255.255.0
read = system,call,log,verbose,command,agent,user,config,command,dtmf,reporting,cdr,dialplan,originate
write = system,call,log,verbose,command,agent,user,config,command,dtmf,reporting,cdr,dialplan,originate
#include manager_additional.conf
#include manager_custom.conf
Know that we have the Asterisk manager password fixed we need t update freePBX to a version that is compatible with Elastix. The problem with Trixbox is when you go into freepbx module admin and click check online for updates the system try’s to call update.trixbox.com instead of the real freePBX update servers. You need to either update all the links in the file /var/www/html/admin/functions.inc.php or just down a copy of mine that is already fixed.
http://www.fintechcommunications.com/trixbox-to-elastix-fix.zip
The only major issue and key to this upgrade is the file above
Unzip and overwrite the file that is aleady in /var/www/html/admin
When you do updates now it will call freePBX update servers instead of trixbox.
The next major step is to update freepbx to version 2.6. On the module admin click on check for updates. Download and intall 2.6 upgrade tool.
Now click on upgrade tool (upper left corner) click on the 2.6 upgrade tool.
Do as the 2.6 upgrade instruction says. Click upgrade.
Go back to module admin and click check for updates.
Download freepbx framework and upgrade and install.
Yeah, Your back to freepbx colors again
From here its just a matter of updating modules and version until you end up with the freePBX version you want.
I got a Cisco 8961 the other day to program for a Callmanager and the thought I would try and make it work with Elastix. I was not able to get the voicemail button to dial *97 but I was able to get the extensions to register and dial out. I used my 7975 config. I’m going to try and get root access to my CUCM and get the files so I see what the phone wants. Below is my working config so far:
<device xsi:type=”axl:XIPPhone” ctiid=”203849429″ uuid=”{96f8508b-10ef-f98c-d20d-
0471777ec725}”>
<fullConfig>true</fullConfig>
<deviceProtocol>SIP</deviceProtocol>
<sshUserId>user</sshUserId>
<sshPassword>pass</sshPassword>
<devicePool uuid=”{a755aa55-089c-2b47-9603-c7d51b9ca4b5}”>
<name>Dallas 5.0 Beta</name>
<dateTimeSetting uuid=”{9ec4850a-7748-11d3-bdf0-00108302ead1}”>
<name>CMLocal</name>
<dateTemplate>M/D/Ya</dateTemplate>
<timeZone>Pacific Standard/Daylight Time</timeZone>
</dateTimeSetting>
<callManagerGroup>
<name>5.0 Beta</name>
<tftpDefault>true</tftpDefault>
<members>
<member priority=”0″>
<callManager>
<name>192.168.1.4</name>
<description>Your PBX</description>
<ports>
<ethernetPhonePort>2000</ethernetPhonePort>
<sipPort>5060</sipPort>
<securedSipPort>5061</securedSipPort>
<mgcpPorts>
<listen>2427</listen>
<keepAlive>2428</keepAlive>
</mgcpPorts>
</ports>
<processNodeName>192.168.1.4</processNodeName>
</callManager>
</member>
</members>
</callManagerGroup>
<srstInfo uuid=”{cd241e11-4a58-4d3d-9661-f06c912a18a3}”>
<name>Disable</name>
<srstOption>Disable</srstOption>
<userModifiable>false</userModifiable>
<ipAddr1>192.168.1.4</ipAddr1>
<port1>2000</port1>
<ipAddr2></ipAddr2>
<port2>2000</port2>
<ipAddr3></ipAddr3>
<port3>2000</port3>
<sipIpAddr1>192.168.1.4</sipIpAddr1>
<sipPort1>5060</sipPort1>
<sipIpAddr2></sipIpAddr2>
<sipPort2>5060</sipPort2>
<sipIpAddr3></sipIpAddr3>
<sipPort3>5060</sipPort3>
<isSecure>false</isSecure>
</srstInfo>
<mlppDomainId>-1</mlppDomainId>
<mlppIndicationStatus>Default</mlppIndicationStatus>
<preemption>Default</preemption>
<connectionMonitorDuration>120</connectionMonitorDuration>
</devicePool>
<sipProfile>
<sipProxies>
<backupProxy></backupProxy>
<backupProxyPort>5060</backupProxyPort>
<emergencyProxy></emergencyProxy>
<emergencyProxyPort>5060</emergencyProxyPort>
<outboundProxy></outboundProxy>
<outboundProxyPort>5060</outboundProxyPort>
<registerWithProxy>true</registerWithProxy>
</sipProxies>
<sipCallFeatures>
<cnfJoinEnabled>true</cnfJoinEnabled>
<callForwardURI>x-cisco-serviceuri-cfwdall</callForwardURI>
<callPickupURI>x-cisco-serviceuri-pickup</callPickupURI>
<callPickupListURI>x-cisco-serviceuri-opickup</callPickupListURI>
<callPickupGroupURI>x-cisco-serviceuri-gpickup</callPickupGroupURI>
<meetMeServiceURI>x-cisco-serviceuri-meetme</meetMeServiceURI>
<abbreviatedDialURI>x-cisco-serviceuri-abbrdial</abbreviatedDialURI>
<rfc2543Hold>false</rfc2543Hold>
<callHoldRingback>2</callHoldRingback>
<localCfwdEnable>true</localCfwdEnable>
<semiAttendedTransfer>true</semiAttendedTransfer>
<anonymousCallBlock>2</anonymousCallBlock>
<callerIdBlocking>2</callerIdBlocking>
<dndControl>0</dndControl>
<remoteCcEnable>true</remoteCcEnable>
</sipCallFeatures>
<sipStack>
<sipInviteRetx>6</sipInviteRetx>
<sipRetx>10</sipRetx>
<timerInviteExpires>180</timerInviteExpires>
<timerRegisterExpires>3600</timerRegisterExpires>
<timerRegisterDelta>5</timerRegisterDelta>
<timerKeepAliveExpires>120</timerKeepAliveExpires>
<timerSubscribeExpires>120</timerSubscribeExpires>
<timerSubscribeDelta>5</timerSubscribeDelta>
<timerT1>500</timerT1>
<timerT2>4000</timerT2>
<maxRedirects>70</maxRedirects>
<remotePartyID>true</remotePartyID>
<userInfo>None</userInfo>
</sipStack>
<autoAnswerTimer>1</autoAnswerTimer>
<autoAnswerAltBehavior>true</autoAnswerAltBehavior>
<autoAnswerOverride>true</autoAnswerOverride>
<transferOnhookEnabled>true</transferOnhookEnabled>
<enableVad>false</enableVad>
<preferredCodec>none</preferredCodec>
<dtmfAvtPayload>101</dtmfAvtPayload>
<dtmfDbLevel>3</dtmfDbLevel>
<dtmfOutofBand>avt</dtmfOutofBand>
<alwaysUsePrimeLine>false</alwaysUsePrimeLine>
<alwaysUsePrimeLineVoiceMail>false</alwaysUsePrimeLineVoiceMail>
<kpml>3</kpml>
<phoneLabel>Justin</phoneLabel>
<stutterMsgWaiting>1</stutterMsgWaiting>
<callStats>false</callStats>
<offhookToFirstDigitTimer>15000</offhookToFirstDigitTimer>
<silentPeriodBetweenCallWaitingBursts>10</silentPeriodBetweenCallWaitingBursts>
<disableLocalSpeedDialConfig>true</disableLocalSpeedDialConfig>
<startMediaPort>16384</startMediaPort>
<stopMediaPort>32766</stopMediaPort>
<sipLines>
<line button=”1″>
<featureID>9</featureID>
<featureLabel>3015</featureLabel>
<proxy>USECALLMANAGER</proxy>
<port>5060</port>
<name>3015</name>
<displayName>3015</displayName>
<autoAnswer>
<autoAnswerEnabled>2</autoAnswerEnabled>
</autoAnswer>
<callWaiting>3</callWaiting>
<authName>3015</authName>
<authPassword>53124AA53124</authPassword>
<sharedLine>false</sharedLine>
<messageWaitingLampPolicy>3</messageWaitingLampPolicy>
<messagesNumber>*97</messagesNumber>
<ringSettingIdle>4</ringSettingIdle>
<ringSettingActive>5</ringSettingActive>
<contact>3015</contact>
<forwardCallInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</forwardCallInfoDisplay>
</line>
<line button=”2″>
<featureID>9</featureID>
<featureLabel>Fintech Voicemail</featureLabel>
<proxy>USECALLMANAGER</proxy>
<port>5060</port>
<name>3050</name>
<displayName>3050</displayName>
<autoAnswer>
<autoAnswerEnabled>2</autoAnswerEnabled>
</autoAnswer>
<callWaiting>3</callWaiting>
<authName>3050</authName>
<authPassword>53124AA53124</authPassword>
<sharedLine>false</sharedLine>
<messageWaitingLampPolicy>3</messageWaitingLampPolicy>
<messagesNumber>*97</messagesNumber>
<ringSettingIdle>4</ringSettingIdle>
<ringSettingActive>5</ringSettingActive>
<contact>3050</contact>
<forwardCallInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</forwardCallInfoDisplay>
</line>
<line button=”3″>
<featureID>9</featureID>
<featureLabel>E-Recycler Voicemail</featureLabel>
<proxy>USECALLMANAGER</proxy>
<port>5060</port>
<name>3060</name>
<displayName>3060</displayName>
<autoAnswer>
<autoAnswerEnabled>2</autoAnswerEnabled>
</autoAnswer>
<callWaiting>3</callWaiting>
<authName>3060</authName>
<authPassword>53124AA53124</authPassword>
<sharedLine>false</sharedLine>
<messageWaitingLampPolicy>3</messageWaitingLampPolicy>
<messagesNumber>*97</messagesNumber>
<ringSettingIdle>4</ringSettingIdle>
<ringSettingActive>5</ringSettingActive>
<contact>3060</contact>
<forwardCallInfoDisplay>
<callerName>true</callerName>
<callerNumber>false</callerNumber>
<redirectedNumber>false</redirectedNumber>
<dialedNumber>true</dialedNumber>
</forwardCallInfoDisplay>
</line>
<line button=”6″>
<featureID>2</featureID>
<featureLabel>Conf</featureLabel>
<speedDialNumber>825</speedDialNumber>
</line>
<line button=”7″>
<featureID>2</featureID>
<featureLabel>Page</featureLabel>
<speedDialNumber>850</speedDialNumber>
</line>
<line button=”8″>
<featureID>2</featureID>
<featureLabel>Pickup</featureLabel>
<speedDialNumber>*8</speedDialNumber>
</line>
</sipLines>
<voipControlPort>5060</voipControlPort>
<dscpForAudio>184</dscpForAudio>
<ringSettingBusyStationPolicy>0</ringSettingBusyStationPolicy>
<dialTemplate>dialplan.xml</dialTemplate>
<softKeyFile>SK50719900-3bee-4594-bc3f-6400e1a33bf0.xml</softKeyFile>
</sipProfile>
<commonProfile>
<phonePassword></phonePassword>
<backgroundImageAccess>true</backgroundImageAccess>
<callLogBlfEnabled>2</callLogBlfEnabled>
</commonProfile>
<loadInformation>sip8961.9-1-1SR1</loadInformation>
<vendorConfig>
<disableSpeaker>false</disableSpeaker>
<disableSpeakerAndHeadset>false</disableSpeakerAndHeadset>
<pcPort>0</pcPort>
<settingsAccess>1</settingsAccess>
<garp>0</garp>
<voiceVlanAccess>0</voiceVlanAccess>
<videoCapability>0</videoCapability>
<autoSelectLineEnable>0</autoSelectLineEnable>
<webAccess>1</webAccess>
<daysDisplayNotActive>6,7</daysDisplayNotActive>
<displayOnTime>08:00</displayOnTime>
<displayOnDuration>18:00</displayOnDuration>
<displayIdleTimeout>00:10</displayIdleTimeout>
<displayOnWhenIncomingCall>1</displayOnWhenIncomingCall>
<spanToPCPort>1</spanToPCPort>
</vendorConfig>
<versionStamp>1136931633-57191cee-5ffc-4342-b286-4246b4991890</versionStamp>
<userLocale>
<name>English_United_States</name>
<uid>1</uid>
<langCode>en_US</langCode>
<version>1.0.0.0-1</version>
<winCharSet>iso-8859-1</winCharSet>
</userLocale>
<networkLocale>United_States</networkLocale>
<networkLocaleInfo>
<name>United_States</name>
<version>5.0(2)</version>
</networkLocaleInfo>
<deviceSecurityMode>1</deviceSecurityMode>
<idleTimeout>0</idleTimeout>
<authenticationURL></authenticationURL>
<directoryURL>http://192.168.1.4/xmlservices/directory.xml</directoryURL>
<idleURL></idleURL>
<informationURL>http://192.168.1.4/ccmcip/GetTelecasterHelpText.jsp</informationURL>
<messagesURL></messagesURL>
<proxyServerURL>192.168.1.4</proxyServerURL>
<servicesURL>http://192.168.1.4/xmlservices/service.xml</servicesURL>
<dscpForSCCPPhoneConfig>96</dscpForSCCPPhoneConfig>
<dscpForSCCPPhoneServices>0</dscpForSCCPPhoneServices>
<dscpForCm2Dvce>96</dscpForCm2Dvce>
<transportLayerProtocol>4</transportLayerProtocol>
<capfAuthMode>0</capfAuthMode>
<capfList>
<capf>
<phonePort>3804</phonePort>
<processNodeName>192.168.1.4</processNodeName>
</capf>
</capfList>
<certHash></certHash>
<encrConfig>false</encrConfig>
</device>
Generates a key that I store on the backup server which allows me to copy files over without asking for a password
ssh-keygen -t rsa
# hit return three times
This copies the newly generated key to the backup server
ssh-copy-id -i ~/.ssh/id_rsa.pub root@192.168.3.253
# enter your password for username on remote_host
This will be the cron commands that we run each week. This will backup freepbx and the phone config files
rsync -ave ssh /var/lib/asterisk/backups/ 192.168.3.253:/var/lib/asterisk/backups/
rsync -ave ssh /tftpboot/ 192.168.3.253:/tftpboot/
for Elastix run
rsync -ave ssh /var/www/backup/ 192.168.3.253:/var/www/backup/
I recently upgrade my Cisco ASA 5510 to 8.4 and started getting exchange server bounces. I started doing some test and realized my sever was not responding to server HELO 220 request with my domain info. It was showing 220 **********************************. Somehow having ESMTP enabled in my global inspect policy was modifying my HELO 220. If you are having similar problems disable ESMTP in you global inspect policy.
The other day I decided to integrate Elastix with Microsoft Lync. Below are the steps involved. I assumes you know how to install Lync and Asterisk (trixbox, elastix, PBXinaflash). I have a Lync extension with 3015 and an Asterisk extension 205
The first step is to create a SIP trunk with TCP support. My favorite distro is Elastix. Add the following to your sip_general_custom.conf file
elastix*CLI> nano /etc/asterisk/sip_general_custom.conf
Add the following:
tcpenable=yes
tcpbindaddr=0.0.0.0
Save your work cntrl-shift-O
Go back into elastix or freepbx
create a sip trunk with the following:
host=192.168.1.7 (IP address of Lync)
type=friend
insecure=very
transport=tcp
port=5060
context=from-internal
create and outbound route to lync. In my case 30XX for extension 3015
This is all you have to do on the Asterisk Side
On the Lync side go into your topology editor and add the IP address of your asterisk server to PSTN gateway. Do forget to add the PSTN gateway to you mediation server.
192.168.1.8 = Vicidial
192.168.1.15 = Elastix
68.68.124.55 = Sip trunk provider
You not have to create a dial plan in Lync
Under the default dial plan
I'm dialing extension 205 so add the following normalization rull ^(2\d{2})$ this should allow me to dial 2XX
Next under voice policy
Next under route
Under PSTN usuage
That should be it. You should be able to dial between systems.
We where having issues sending email from elastix with go daddy and getting the following error.
Name service error for name=smtpout.secureserver.net type=MX: Host not found, try again)
If you don’t have webmin I suggest you install it. It makes it allot easier to troubleshoot and fix remote systems.
Login into the linux console and type in
wget http://prdownloads.sourceforge.net/webadmin/webmin-1.540-1.noarch.rpm
rpm -i webmin-1.540-1.noarch.rpm
To fix it we disabled Ignore MX lookup error
- login into webmin and go servers
- click on postfix Mail Server
- Click on SMTP client options
- Make Ignore MX lookup error
Now go back to the main page and flush queue
below is a working postfix config with godaddy using Elastix
virtual_transport = lmtp:unix:/var/lib/imap/socket/lmtp
relayhost =smtpout.secureserver.net:25
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps =hash:/etc/postfix/sasl/passwd
smtp_sasl_security_options =
broken_sasl_auth_clients = yes
smtpd_tls_auth_only =
smtp_use_tls = no
smtpd_use_tls = no
smtp_tls_note_starttls_offer = no
smtpd_tls_loglevel =
smtpd_tls_received_header = no
smtpd_tls_session_cache_timeout =
tls_random_source =
smtp_tls_CAfile =
mydomain = yourdomain.com
myhostname = elastix.yourdomain.com
ignore_mx_lookup_error = yes
fallback_relay =










