Dahdi linux complete current

Asterisk

Downloads of Asterisk are available at https://downloads.asterisk.org/pub/telephony/asterisk/. The currently supported versions of Asterisk will each have a symbolic link to their related release on this server, named asterisk—current.tar.gz. All releases ever made for the Asterisk project are available at https://downloads.asterisk.org/pub/telephony/asterisk/releases/.

The currently supported versions of Asterisk are documented on the Asterisk Versions page. It is highly recommended that you install one of the currently supported versions, as these versions continue to receive bug and security fixes.

Which version should I install?

  • If you want a rock solid communications framework, choose the latest Long Term Support (LTS) release.
  • If you want the latest cool features and capabilities, choose the latest release of Asterisk. If that is a Standard release, note that these releases may have larger changes made in them than LTS releases.

Unless otherwise noted, for the purposes of this section we will assume that Asterisk 14 is being installed.

Review Asterisk’s System Requirements in order to determine what needs to be installed for the version of Asterisk you are installing. While Asterisk will look for any missing system requirements during compilation, it’s often best to install these prior to configuring and compiling Asterisk.

Asterisk does come with a script, install_prereq, to aid in this process. If you’d like to use this script, download Asterisk first, then see Checking Asterisk Requirements for instructions on using this script to install prerequisites for your version of Asterisk.

Downloading Asterisk

You can also get the latest releases from the downloads page on asterisk.org.

Alternatively, you can us e wget to retrieve the latest release:

[[email protected]:/usr/local/src]# wget https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-14-current.tar.gz --2017-04-28 15:45:36-- https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-14-current.tar.gz Resolving downloads.asterisk.org (downloads.asterisk.org). 76.164.171.238 Connecting to downloads.asterisk.org (downloads.asterisk.org)|76.164.171.238|:443. connected. HTTP request sent, awaiting response. 200 OK Length: 40692588 (39M) [application/x-gzip] Saving to: ‘asterisk-14-current.tar.gz’ asterisk-14-current.tar.gz 100%[======================================================================>] 38.81M 3.32MB/s in 12s 2017-04-28 15:45:47 (3.37 MB/s) - ‘asterisk-14-current.tar.gz’ saved [40692588/40692588]

Other Projects

libpri

The libpri library allows Asterisk to communicate with ISDN connections.You’ll only need this if you are going to use DAHDI with ISDN interface hardware (such as T1/E1/J1/BRI cards).

Читайте также:  Графические установщики arch linux

DAHDI

The DAHDI library allows Asterisk to communicate with analog and digital telephones and telephone lines, including connections to the Public Switched Telephone Network, or PSTN.

DAHDI stands for Digium Asterisk Hardware Device Interface, and is a set of drivers and utilities for a number of analog and digital telephony cards, such as those manufactured by Digium. The DAHDI drivers are independent of Asterisk, and can be used by other applications. DAHDI was previously called Zaptel, as it evolved from the Zapata Telephony Project.

The DAHDI code can be downloaded as individual pieces (dahdi-linux for the DAHDI drivers, and dahdi-tools for the DAHDI utilities. They can also be downloaded as a complete package called dahdi-linux-complete, which contains both the Linux drivers and the utilities.

You will only need to install DAHDI if you are going to utilize DAHDI compatible analog or digital telephony interface boards.

Why is DAHDI split into different pieces?

DAHDI has been split into two pieces (the Linux drivers and the tools) as third parties have begun porting the DAHDI drivers to other operating systems, such as FreeBSD. Eventually, we may have dahdi-linux, dahdi-freebsd, and so on.

Download Locations

Источник

Установка Asterisk LTS на CentOS 7

Обновлено

Обновлено: 16.07.2022 Опубликовано: 04.04.2018

Тематические термины: Asterisk, CentOS. В описанной инструкции рассмотрим пример установки с нуля Asterisk 18 LTS (с длительной поддержкой) на Linux CentOS 7.

Подготовка сервера

1. Устанавливаем необходимые программы

* gcc нужен для сборки исходников, wget — для загрузки файлов из командной строки; ntpdate — синхронизации времени; automake — участвует в создании Makefile при запуске configure; libtool — обеспечивает процесс сборки и использования динамических библиотек.

2. Настраиваем время

3. Настройка безопасности:

* где 5060 — SIP, 5061 — SIP over TLS, 4569 — IAX, 5038 — AMI (Asterisk Manager Interface), 10000-20000 — диапазон для динамических портов. Теперь добавляем созданный сервис как разрешенный:

Установка Asterisk

  1. Установка DAHDI (драйверов плат интерфейсов);
  2. Установка LibPRI (библиотека для работы с потоковыми TDM-интерфейсами);
  3. Собственно, сборка и установка Asterisk.

1. Сборка DAHDI

Устанавливаем исходники для используемого ядра:

yum install «kernel-devel-uname-r == $(uname -r)»

Загружаем исходник, распаковываем его и переходим в распакованный каталог:

tar -xvf dahdi-linux-complete-current.tar.gz

Выполняем сборку и установку:

Выходим из каталога с исходником:

2. Сборка LibPRI

Процедура, во многом, похожа на сборку DAHDI. Загружаем исходник, распаковываем его и переходим в распакованный каталог:

tar -xvf libpri-current.tar.gz

Выполняем сборку и установку:

Выходим из каталога с исходником:

3. Установка самого астериска

Для начала, загружаем исходник на сервер. Так как мы планируем установить LTS версию, заходим на страницу https://www.asterisk.org/downloads/asterisk/all-asterisk-versions, раздел «Long Term Support (LTS) Releases» и копируем ссылку на загрузку пакета:

Копируем ссылку на LTS версию Asterisk PBX

* Certified Asterisk — бизнес версия с поддержкой для коммерческих клиентов.

Используя ссылку, скачиваем на сервер программу:

Читайте также:  Linux директории что это

Распаковываем архив и переходим в него:

Используем встроенный скрипт, чтобы установить зависимости для астериска:

Чистим образовавшиеся временные файлы:

Добавляем библиотеку для работы с mp3:

./configure —prefix=/usr —sysconfdir=/etc —localstatedir=/var —libdir=/usr/lib64 —with-dahdi —with-pri —with-iconv —with-libcurl —with-speex —with-mysqlclient —with-jansson-bundled —with-pjproject-bundled

* полный перечень опция и что они означают можно посмотреть командой ./configure -h.

Выбираем необходимые компоненты (в данном примере res_config_mysql, app_mysql, cdr_mysql):

Конфигурирование пакета перед сборкой

Запускаем сборку и установку:

Устанавливаем скрипты для автозапуска АТС и готовые конфигурационные файлы:

Базовая настройка и запуск

Открываем конфигурационный файл:

Снимаем комментарии и редактируем следующие пункты:

runuser = asterisk
rungroup = asterisk
defaultlanguage = ru
documentation_language = ru_RU

Задаем права на следующие каталоги:

chown -R asterisk:asterisk /var/run/asterisk

chown -R asterisk:asterisk /etc/asterisk

chown -R asterisk:asterisk /var//asterisk

chown -R asterisk:asterisk /usr/lib64/asterisk

chown -R asterisk:asterisk /var/log/asterisk

require = chan_sip.so
require = chan_pjsip.so

Если программа запустится, мы увидим Asterisk Ready:

Успешный запуск Asterisk

* все ошибки и предупреждения можно проигнорировать, но правильнее их исправить, отключив неиспользуемые модули.

Теперь можно запустить астериск как службу:

systemctl enable asterisk

Заведение пользователя

Создадим наш первый диалплан (правило обработки звонков):

[outcaling]
exten => _XXX,1,Dial(SIP/$,,m)

* в данном примере мы создаем контекст с именем outcaling для трехзначных номеров (XXX) с вызовом по SIP по внутреннему номеру.

Теперь создадим два внутренних номера:

[public](!)
type=friend
context=outcaling
host=dynamic
disallow=all
allow=alaw
allow=ulaw
language=ru
qualify=yes
canreinvite=yes
call-limit=4
nat=no

[101](public)
regexten=101
secret=1234
callerid=»101″
callgroup=1
pickupgroup=1

[102](public)
regexten=102
secret=5678
callerid=»102″
callgroup=1
pickupgroup=1

* сначала мы создали шаблон public, в который занесли общие параметры. Шаблон мы применили к создаваемым коротким номерам.
* где:

  • [101], [102] — имена для обозначения номеров.
  • type — типы проверки номеров. Могут быть peer, user или friend. Peer — вызовы сопоставляются с IP-адресами и номерами портов. User — проверка username. Friend — включает возможности peer и user (проверка username и IP-адреса источника) и лучше всего подходит для телефонов и телефонных программ.
  • regexten — добавочный номер. Если не задан, используется имя.
  • secret — пароль для аутентификации.
  • context — контекст или группа правил.
  • host — IP-адрес или имя клиента. Для автоматической регистрации используем dynamic.
  • callerid — идентификатор пользователя при звонке.
  • disallow — запрещает кодеки (задается перед параметром allow).
  • allow — разрешает кодеки. alaw и ulaw — алгоритмы для кодеков g711.
  • language — код используемого языка.
  • callgroup — задает группу устройства (для возможности перехвата).
  • pickupgroup — задает перечень групп, которые можно перехватывать.
  • qualify — включает или отключает периодическую проверку подключенного клиента.
  • canreinvite — включает или отключает прохождение голосового RTP трафика через Asterisk. Устанавливать, только если клиент поддерживает функцию SIP re-invites.
  • call-limit — ограничение количества одновременных вызовов.
  • nat — устанавливается в yes, если клиент находиться за NAT.

systemctl restart asterisk

Подключение телефона и проверка

Для проверки сервера устанавливаем софт-телефон на компьютер. Например, а качестве SIP-клиента под Windows можно установить бесплатную программу 3CX Phone, для Android — Zoiper.

Читайте также:  All basic commands in linux

Пример настройки клиента 3CX Phone:

Пример настройки 3CX Phone

Настраиваем подключение с логином и паролем 101 / 1234, второй — 102 / 5678. Пробуем позвонить.

Исправление ошибок

Рассмотрим процесс устранения предупреждений и ошибок во время запуска Asterisk.

Из-за неиспользуемых модулей

Для устранения данных проблем необходимо просто отключить данные модули.

И в зависимости от ошибок, добавляем нижеперечисленные исправления.

Источник

How to completely remove DAHDI and reinstall DAHDI

In this Article we are going to learn how to completely remove or uninstall the DAHDI driver and reinstall latest or same version of DAHDI in asterisk based servers. Due to server crash or planning to install the latest version of DAHDI you may want to remove the DAHDI driver then this article is for you.

What is DAHDI?

DAHDI is a collection of open source drivers, for linux, that are used to interface with a variety of telephony related hardware.

The DAHDI-Tools project contains an assortment of user space utilities that are used to setup and test the drivers.

Asterisk is a Open source Communication software , You can use Asterisk to build communications applications, things like business phone systems (also known as IP PBXs), call distributors, VoIP gateways and conference bridges.

Why we need to remove/uninstall DAHDI?

If you are planning to use the latest DAHDI driver or your current DAHDI deriver crashed or creating issue then you might need to remove or reinstall the DAHDI driver. this Blog topic I will be covering the steps to remove or uninstall the DADHI driver, followed to that either reinstall same DAHDI version or installing the latest version of DAHDI.

Steps to uninstall-Reinstall DAHDI

Follow the below steps to remove/uninstall DAHDI and install the same or latest version of DAHDI driver

Step 1: Stop Dahdi Service

Step 2: Uninstall DAHDI

Next you need to find the DAHDI modules drivers which are installed in the server, if multiple drivers modules are installed you need to remove all before removing the actual DAHDI driver.

Command to check the list of dahdi modules installed

you will get the below output

asterisk dahdi reinstall

Now uninstall all the modules which shown in above pic

Finally remove the actual dahdi driver by running below command

Step 3: Reinstalling or Upgrade to Latest DAHDI

Download the latest DAHDI driver from the below link.

cd /usr/src/
wget https://downloads.asterisk.org/pub/telephony/dahdi-linux-complete/dahdi-linux-complete-current.tar.gz

If want to download a specific version of dahdi, check out the below link for asterisk archive repository

Installing the Dahdi,
Run the below command to unzip and install the dahdi

Источник

Оцените статью
Adblock
detector