login | register
Sun 07 of Sep, 2008 [07:35 UTC]

voip-info.org

Asterisk MacOSX Support

Created by: oej,Last modification on Fri 30 of May, 2008 [10:19 UTC] by jameslegg

NOTE: Astmasters.net is being migrated to Mactelephony.net - Links temporarily unavailable



News



Migration Notice


  • 21 Nov 2006 - Astmasters.net is currently being rebuild under a new domain (mactelephony.net) — new site will be up shortly

Asterisk runs on various versions of MacOSX, starting with MacOSX "Jaguar" (ver 10.2), "Panther" (ver 10.3), and "Tiger" (ver 10.4.x). MacOSX, uses an open-source subsystem called Darwin which is based on FreeBSD and the Mach 3.0 microkernel. This means that BSD code can mostly be used without modification but drivers need to be specifically written for Darwin/MacOSX only.

NOTE: PCI CARD SUPPORT for MacOSX is not available. Use EXTERNAL GATEWAY DEVICES instead.



Getting Started

If you are new to Asterisk and VoIP and you don't have the time or the nerve to concern yourself with building software from source code and editing configuration files, then a Mac running OSX is the best choice for you to get started. Installing Asterisk and setting up a basic home IP-PBX system on your Mac is as easy as anything else you do on your Mac, just as you would expect it to be. You don't need a consultant to do it for you. You can do it yourself and you don't need any prior knowledge to do so.

Here is all you need to do:
Note: link temporarily unavailable due to migration of astmasters.net to new mactelephony.net domain

  • Download the Asterisk Launcher for MacOSX so you can control your Asterisk server using only the MacOSX GUI interface
  • Download the Asterisk Assistants for MacOSX to easily configure your Asterisk server using only the MacOSX GUI interface
  • Make and receive phone calls via Asterisk and enjoy!

For more details with illustrations:

More GUI tools for further configuration tasks are under development. Check this Wiki page regularly for updates.

Installation

Installing a pre-built package

Most recent precompiled packages.

  • The most up to date packages for asterisk can be found at mezzo.net.
But notice that they install at a different location than the sunrise packages and as a result most wizards will not work without tweaking. App_notify and bonjour support included.

Stable Branch

  • If you don't want to build Asterisk yourself, you can download this MacOSX install package. This install package will install an older but proven and stable build of Asterisk (CVS 10-28-03) which runs on MacOS X version 10.2.8 or higher (including 10.3.9). A new build of Asterisk 1.0.7 is available here.

Developer Branch (Experimental)

  • If you want to test the beta version of Asterisk 1.2, you can download this installer. It will install Asterisk 1.2.0beta1 into /opt/local, and put an uninstaller in your home directory. Note, however that this build is not compatible with the GUI utilities (Asterisk Launcher and Asterisk Assistants).

Building from source using Fink


Asterisk has a number of dependencies that are not included in a normal Mac OS X install, even with all of the developer tools. You can get these dependecies from the Fink package management system. These dependecies include libgsm, libspeex, libvorbis, libusb, lua, libintl, popt, and maybe others. After you have installed Fink, then install these packages:

fink install popt gsm speex3 libgettext3-dev libusb

Get your asterisk however you want, svn, tarball, etc. and then run ./configure with some flags to tell it where to find the Fink stuff:

./configure --prefix=/usr/local CFLAGS=-I/sw/include LDFLAGS=-L/sw/lib --without-popt
make CFLAGS=-I/sw/include LDFLAGS=-L/sw/lib

Removal (Uninstall)

  • To remove an Asterisk installation download and run the asterisk_uninstall.sh script - Download link
  • Copy the script to your home folder, open Terminal.app and type: sudo ./uninstall_asterisk.sh help
  • Note: Read the documentation at the head of each script in the zip archive for further information

Default location of Asterisk

The default location of the Asterisk executable on Linux is /usr/sbin/asterisk. On BSD systems, user installed software is usually located in /usr/local/bin. However, for the sake of configuration compatibility with Linux, the MacOS X builds and installers use the Linux convention and place Asterisk in /usr/sbin/asterisk. Since Asterisk is a faceless Unix daemon will not show up in your /Applications folder and it will not be displayed in the dock. Instead, use Asterisk Launcher to start and stop Asterisk.

NOTE: Asterisk Launcher and the Asterisk Assistants will only work if Asterisk has been installed in the default location /usr/sbin/asterisk. They will not work if Asterisk is installed in a different location. These utilities use the MacOS X security framework to call Asterisk and for security reasons the path has been hardcoded so that it cannot be changed to a another executable (potentially containing malicious code).

Starting and stopping Asterisk using the GUI

Use Asterisk Launcher to start and stop Asterisk and monitor its status. Asterisk Launcher also allows you to let Asterisk launch automatically at system startup. For an alternative autostart method (using launchd), see Building Asterisk on MacOSX.

Building Asterisk from source

If you want to buid Asterisk yourself, you will need the developer tools for MaxOSX and the Asterisk source code, then follow the instructions at Building Asterisk on MacOSX.

Limitations

  • PCI based telephony interface cards, such as Digium's wildcard series, require drivers which are currently only available for GNU/Linux operating systems. The only way to connect a MacOSX based Asterisk server to conventional telephone lines and telephones is through external devices such as media gateways and ATAs. For example, to connect an analog telephone line, an FXO media gateway can be used and to connect an analog telephone, an analog telephone adapter (ATA) can be used. An example of a very affordable FXO gateway/ATA combo device often used with Asterisk is the Sipura 3000. The Sipura 3000 costs about 75 USD and is well suited for a home PBX setup.
  • Another possibility is to install LinuxPPC on your Mac and then run MacOSX through a virtualisation facility called Mac on Linux or MoL in short. MoL allows you to run both LinuxPPC and MacOSX at the same time. Since the telephony drivers work just fine under LinuxPPC, you could run Asterisk with full hardware support under LinuxPPC while still using MacOSX on the same Mac. The LinuxPPC distribution for which Asterisk support was originally done by Digium is called Yellow Dog Linux (aka YDL) from Terra Soft Solutions. Make sure you use YDL version 3.01 and not 3.0 if you want to build the Zaptel telephony drivers.

How you can contribute

  • If you are a MacOSX developer and want to contribute to Asterisk visit #asterisk-dev on irc.freenode.net.

Other Resources


MacOS X How-to's


MacOSX specific Asterisk utilities and add-ons




MacOSX Softphones

Softphones which can be configured to connect to Asterisk

Softphones which cannot be configured to connect to Asterisk

  • Gizmo Project: nice SIP client but hardcoded to only connect to SIPphone.com - Website
  • iChat AV from Apple: incompatible derivative of SIP - Website
  • Internet Phone from Empower Pro: undocumented proprietary VoIP protocol - Website
  • KDX from Haxial: undocumented proprietary VoIP protocol - Website
  • SquidCam from SquidSoft: undocumented proprietary VoIP protocol - Website
  • Skype: closed and proprietary VoIP protocol, very restrictlive EULA, client hijacks resources of your Mac for use by Skype network
If you happen to visit any of these non-standard softphone maker's websites, you may want to drop them an email and ask them to consider to support IAX in future versions of their software. The open source iaxComm project has all the libraries they need to make it work and they'll save themselves a lot of work maintaining their own protocols in the long term.



See also:

  • Another Mac OS-X installer package of an universal binary version of Asterisk 1.2/1.4 can be downloaded from mezzo.net. It installs os-x-like into /Library/Asterisk. Note: GUI tools from Sunrise cannot be used with this version. Also, please don't contact Sunrise about this build with your problems unless you are willing to pay for consulting. Sunrise did not make this build and is not responsible for any problems with it.
  • Asterisk on LinuxPPC
  • Linux Yellow Dog Yellow Dog Linux general information


Asterisk | Asterisk AppleScripts | Asterisk Assistants for MacOSX | Asterisk Getting Started on MacOSX | Asterisk AGI MacinTalk

Comments

Comments Filter
222

333

by aniklaus, Tuesday 07 of February, 2006 [15:16:05 UTC]
Ok - I've managed :) All I had to do to remove prevoius instalation (Asterisk 1.0.7).
Regards,
Niko;)
222

333Asterisk 1.2.4?

by aniklaus, Tuesday 07 of February, 2006 [11:26:09 UTC]
Hi there,
I'm asterisk and OS X newbee. I've compiled Asterisk 1.2.4. But unfortunately I can't start my compiled *. I've removed app_striplsd.so, app_substring.so, chan_modem.so, chan_modem_aopen.so, chan_modem_bestdata.so, chan_modem_i4l.so, pbx_wilcalu.so (I've updated asterisk 1.0.7). When I start my * with -f I can see:
Feb 7 11:15:35 NOTICE12120: cdr.c:1188 do_reload: CDR simple logging enabled.
Feb 7 11:15:35 WARNING12120: loader.c:325 __load_resource: dlopen(/usr/lib/asterisk/modules/chan_modem.so, 10): image not found
Feb 7 11:15:35 WARNING12120: loader.c:499 load_modules: Loading module chan_modem.so failed!
It looks like my asterisk doesn't start at all, because astrisk -rc gives me:
Unable to connect to remote asterisk (does /var/run/asterisk.ctl exist?)
Did anybody successfuly compiled and run Asterisk 1.2.4 on OS X (Xserve 10.4.4)? Can anybody help me?
Regards,
Niko;)
222

333Re: Install directory

by STS, Thursday 17 of November, 2005 [21:50:37 UTC]
Quote: "Is there a Mac / Asterisk forum that people frequent? Since I'm a newb I'm looking for a place to post questions and discuss configs."

You didn't read this Wiki carefully enough ;-) It lists under "Other Resources" ...

the Astmasters.net community site http://www.astmasters.net

... and the Macintosh Asterisk Mailing List http://www.astmasters.net/maml.html

hope this helps.


222

333Install directory

by ppmax, Monday 03 of October, 2005 [22:38:30 UTC]
Just getting started with Asterisk--thanks to the folks that have packaged it up for OS X.

Out of curiosity, why does Asterisk install to /usr/sbin? Isnt the convention that user installed binaries should go into /usr/local? Does anyone have a makefile that uses /usr/local/ ?

I went ahead and installed the 1.0.7 beta build and used the Asterisk Launcher to create a startup item. I also created a new asterisk user and group. Since I'm on Tiger I removed the /Library/StartupItmes/Asterisk and followed the directions for creating a LaunchDaemon. When I use launchctl to start Asterisk I get a string of errors in my system.log file:
Oct 3 11:31:55 mydevmachine launchd: com.asterisk.org.asterisk: exited with exit code: 1
Oct 3 11:31:55 mydevmachine launchd: com.asterisk.org.asterisk: respawning too quickly! throttling
Oct 3 11:31:55 mydevmachine launchd: com.asterisk.org.asterisk: 9 more failures without living at least 60 seconds will cause job removal
Oct 3 11:31:55 mydevmachine launchd: com.asterisk.org.asterisk: will restart in 10 seconds

I made sure the path in the ProgramArguments key was /usr/sbin/asterisk. When I use a StartupItem Asterisk starts fine--but runs as root. Any suggestions to get the LaunchDaemon working and running Asterisk as user asterisk?

Lastly: Is there a Mac / Asterisk forum that people frequent? Since I'm a newb I'm looking for a place to post questions and discuss configs.

Thanks again--looking forward to ditching my phone service provider...
222

333Re: Extension Applescript Error

by ppuskari, Monday 18 of April, 2005 [04:19:12 UTC]
If anyone hasn't fixed this yet, I am also getting the applescript error on a 10.2.8 setup. Actual config is a Beige G3 upgraded with a Sonnet Encore 1.0GHZ G4 chip. I've done a fresh install two days ago then installed asterisk. The older one. Install went fine. I suppose I should just configure by hand like my Linux box :)

Hopefully this is something that someone can figure out. Would love to use the nice extra tools on this now vintage but still very fast old mac!!!

Keep up the good work!
222

333Re: not able to build zaptel

by , Wednesday 02 of February, 2005 [17:18:27 UTC]
In reply to my own post, I think I know what went wrong.
I was able to build asterisk 1.0.5 on OSX 10.3.7
The directions above point to a link http://www.asterisk.org/index.php?menu=download
I think that the only relevant info on that link is to build asterisk and not zaptel or the pri-libs.
Build successful for asterisk only.
222

333not able to build zaptel

by , Tuesday 01 of February, 2005 [15:13:47 UTC]
I followed the instructions above, downloaded bison 1.75 and the latest dev tools 1.5 on osx 10.3.7, and I'm getting this (where its looking for the linux-2.4 sources.. what should I be replacing that with?:
gcc -I/usr/src/linux-2.4/include -O6 -DMODULE -DKERNEL -DEXPORT_SYMTAB -I/usr/src/linux/drivers/net -Wall -I. -Wstrict-prototypes -fomit-frame-pointer -I/usr/src/linux/drivers/net/wan -I /usr/src/linux/include -I/usr/src/linux/include/net -DSTANDALONE_ZAPATA -c zaptel.c
In file included from zaptel.c:40:
zconfig.h:9:26: linux/config.h: No such file or directory

I was able to install the binary packages just fine, but I do wish to install from sources.
Thanks,
-UB
222

333Build 1.0.3 on MacOS X 10.3.6

by , Wednesday 08 of December, 2004 [00:35:55 UTC]
I just built the Asterisk 1.03 sources on MacOS X without hassle.

Not wishing to overwrite the system bison. I did a default build of Bison 1.875 which installs in /usr/local. All that was necessary was to change the single line in the Makefile which refers to bison to refer to /usr/local/bin/bison.

Everything then built without error. All I need is some hardware to test it.

Bill Northcott
222

333Re: How to call a plain old telephone?

by FACTSplus, Sunday 21 of November, 2004 [20:51:40 UTC]
UPDATE:
I have been successful in setting up PSTN termination service with VoipJet.com a strictly IAX protocol connected service. The setup is free and they give you 25cents to in order to test you connection and quality. After that, it is prepay setup through PayPal. Per minute charge is less that 2cents per minute. There are a couple other services I am looking into as well.
Also, follow the VoipJet instructions to the T as well as this line which they forgot to mention for the iax.cnf file:
register => your ID number:your secure password@216.118.117.46

One last thing. There are a couple of weird issues when setting up your outbound dialing for VoipJet due to the way Macsterisk uses external cnf files. I was able to get it working but not with clean instructions yet. More to come..
222

333Re: Asterisk and iChat

by benjk, Tuesday 16 of November, 2004 [16:42:53 UTC]
Asterisk has a SIP module built-in and iChat is also based on SIP. Running both at the same time on the same machine will create a conflict because both apps try to occupy the SIP port 5060.

Here is what you can do to prevent Asterisk and iChat competing for the same port:

- edit /etc/asterisk/sip.conf

where it says ...

general
port = 5060 ; Port to bind to

... change the port number to 5061

- save the changes

- get Asterisk to reload its configuration (AppleScript: Asterisk Reload)

Asterisk will now talk SIP on port 5061 instead of port 5060, thus leaving port 5060 for iChat.

Be aware though that you must configure any SIP phones you want to connect to your Asterisk server to also use port 5061.