Asterisk Linux SuSE

Asterisk on SuSE Linux
Part of UnitedLinux.

A couple of users reported problems getting Asterisk to work with SuSe 8.2 or 9.0 when zaptel hardware drivers are involved. Others reported success (for 8.2 at least). 9.2 Professional comes with pre-built RPMs for Asterisk as well the associated modules and configuration files.

Novell has changed their policy on kernel modules, so as of SuSE v10.x Asterisk is no longer supported. More details on this 'change of heart' here:
Novell bans proprietary Linux modules

openSUSE 10.2

More excellence. More improvements even over 10.1 (there are worthwhile improvements for this minor version). Asterisk seems fine.

One small thing we are interested in, are tinkering with, and want to know if any one else is tinkering with, or has got working is using AppArmor. Please see:
Securing Your Server With AppArmor
for what seems like a fairly straight-forward start to this goal. Please add your notes here & we will try to do same.

openSUSE 10.1

No reported issues that we are aware of here. Upgrade from previous SUSE version was painless. New OS is fantastic, really like the direction that things are headed, better mgmnt, better tools, more packages, better security, more universality (ext3 now and not reiserFS, and others more RHEL/CentOS -like). Fewer complaints, more complements all around. Some previous versions (few versions back) used to have SUSE-specific oddities that our RHEL guys would get thrown a curveball on, but there are few of those these days it seems. Others please elaborate on your opinion here. It is always a debate on what distro' to go with (will they still be in business, how great will support be, how big is community, will all RPM's just work, what is developing sw on it like, etc) and we only see good things on all fronts.

SuSe 10.x

SLES 10 (SUSE Linux Enterprise Server) works with Asterisk 1.4beta sources but installation can be tricky.

You need to install the kernel-source package (via yast). Yast will download the latest greatest kernel source wich will NOT be the same version you are running. This causes the zaptel build to fail so you need to take the following steps (compile and install a new kernel):

  1. cd /usr/src/linux
  2. make cloneconfig
  3. make
  4. make install

Yes, because of the version differences you must install after the compile of the kernel. At this point you should be able to just reboot into your new kernel. Once you reboot do:

  1. uname -r

  1. ls -l /usr/src/linux
lrwxrwxrwx 1 root root 20 2006-09-28 15:13 linux -> linux-

As you can see, the running kernel must be the same as the version of the kernel you just compiled. e.g. /usr/src/linux -> linux-

If the version reported by uname -r does not match the what /usr/src/linux points at then you have a problem. The new kernel you compiled is not the one that booted. That probably means "make install" didn't adjust grub and other things correctly. Form some reason this seems to happen a lot with SUSE dating back to the 9.x release. There are a few steps to fix this. First, when you reboot the grub menu may show more than one "SUSE Linux Enterprise Server 10" entries. If you scroll down to the second one this might boot your new kernel but this will only be a temporary fix so its not recommended.

The proper thing to do is to look in the /boot directory. The symbolic links for /boot/vmlinz and /boot/initrd are probably wrong. Given the above example where the new kernel version should be "", then /boot should contain the following two entries:

initrd -> initrd-
vmlinuz -> vmlinuz-

If they don't, then they probably still point at the old kernel. Do the following (adjusted for your kernel version):

  1. rm vmlinuz
  2. rm initrd
  3. ln -s /boot/vmlinuz- /boot/vmlinuz
  4. ln -s /boot/initrd- /boot/initrd

  1. reboot

When your system comes back up check that uname -r is reporting the correct version. If it is then you should be all set!

SuSe 9.0

Compilation Error

Packages needed

Packages needed



SuSe 9.1 & ast_data

by Giovanni Powell

I have tried using ast_data-1.0.2. But it doesn't work. So i suggest using ast_data-1.0.1 and asterisk-1.0.1.

For ast_data to work correctly you have to edit the data_Makefile and the README.txt, as stated in their documentation.

1. edit the data_Makefile, go to line 25 and enter the location of your mysql folder.
Mine is set to, MYSQLDIR=/usr/lib/mysql and comment out the Postgres and ODBC stuff.

2. edit the README.txt

3. If asterisk is already installed then make the README.txt and it should say patch successfully installed or something like that.

4. make install for asterisk. then edit cdr_mysql.conf in your /etc/asterisk folder.

Use the square brackets...


5. edit the data.conf file.

SIPFriends = mysql
IAXFriends = mysql
ExtensionsLookup = mysql
Voicemail = mysql

QType = Default
Hostname = localhost
DBName = asteriskDB
User = root
Password =
Port = 3306
Sock = /var/lib/mysql/mysql.sock

Using an application like phpMyAdmin manage the database makes life alot easier.

In phpMyAdmin create a Database called asteriskDB and browse for the extensions.sql, iax-friends.sql,sip-friends.sql,vmdb.sql to create the tables. Located in the /usr/src/asterisk-1.0.1/contrib/scripts folder.

After that insert the relevant data in the extensions table and also in the sipfriends table, and you should be good to go!!

See Also:

SuSe 9.2 Compilation

NCurses and Termcap

In order to compile on SuSe 9.2, and most likely previous versions, you are going to need to make NCurses visible to the configure script since SuSe likes to hide it. You could pass it in as an argument, but other applications may want it someday too. So I did this as root:

ln -s /lib/ /usr/lib/

and that seemed to work.


At the linking stages, ld complains that it can not find ssl

ld: cannot find -lssl

So you will need to install openssl-devel

SuSe 9.2 Zaptel Installation

by Peter Sutter

All the zaptel modules get already installed by a minimum installation of SuSE V9.2, simply because the modules are loadable modules and are therefore part of the kernel. The SuSE V9.2 installation procedure puts them into the directory /lib/modules/{kernelname-version}/extra. Some of these modules are quite old and failed to work here.

A make install of zaptel puts the modules into the directory /lib/modules/{kernelname-version}/misc, so we have now two versions of the modules on our system. And modprobe still uses the modules from the extra directory. To get it working with the compiled modules, you have to remove all zaptel modules that are in /lib/modules/{kernelname-version}/extra. The quickest way to do this is
for module in /lib/modules/{kernelname-version}/misc/*; do rm -i /lib/modules/{kernelname-version}/extra/$(basename $module); done
You will get a few error messages for modules that are in the misc directory but not in extra. Just ignore them.

Check now with
modprobe zaptel
that the modules are really gone. You should get an error Could not open '/lib/modules/{kernelname-version}/extra/zaptel.ko'

Now issue
This will create a new dependencies and map file

Add also to the end of /etc/udev/rules.d/50-udev.rules the following lines
# Section for zaptel device
KERNEL="zapctl",     NAME="zap/ctl"
KERNEL="zaptimer",   NAME="zap/timer"
KERNEL="zapchannel", NAME="zap/channel"
KERNEL="zappseudo",  NAME="zap/pseudo"
KERNEL="zap[0-9]*",  NAME="zap/%n"

modprobe zaptel
will now load your compiled modules, not the ones which came with the system.

Also the zaptel startup file as installed with make install (/etc/init.d/zaptel) does not work under SuSE V9.2. Use the original one from SuSE.

SuSe 11 Compilation

SuSe 11 does not have libtermcap or libtermcap-devel. I installed termcap from the packages manager, but was still getting configure errors.

To solve it, i ran: ./configure --with-termcap=/usr/lib/termcap

hopefully that saves someone some time.

note on above: if you install packages after the initial ./configure, you have to run "make distclean" and then re-run ./configure or it Asterisk won't see the new packages.
Created by: wylie, Last modification: Mon 04 of Jun, 2012 (07:47 UTC) by admin
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+