chan_sip.c:26407 handle_request_invite: Call from '' (185.xx.xxx.xx:yyyy) to extension '+xxxxxxxxx' rejected because extension not found in context 'public'.
chan_sip.c:4072 retrans_pkt: Retransmission timeout reached on transmission 406352109-1273432794-715019137 for seqno 1 (Critical Response)
Action: Atxfer
[ActionID:]
Channel:
Exten:
[Context:]
Выключаем SeLinux и перезагружаемся
vim /etc/selinux/config
systemctl reboot
(sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config && systemctl reboot)
Обновляем ОС и удовлетворяем зависимости
yum update -y && yum install vim wget -y
yum group install "Development Tools"
yum -y install mariadb-server httpd php php-pear php-mysql php-process curl bison perl perl-CPAN openssl-devel kernel-devel audiofile-devel sox svn gcc-c++ make ncurses-devel libxml2-devel mysql-devel sqlite-devel mysql-connector-odbc uuid-devel uuid libuuid-devel rpm-build libcurl-devel libtool-ltdl-devel unixODBC-devel
Для realtime с внешней базой:
yum -y install curl bison perl perl-CPAN openssl-devel kernel-devel audiofile-devel sox svn gcc-c++ make ncurses-devel libxml2-devel mysql-devel sqlite-devel mysql-connector-odbc uuid-devel uuid libuuid-devel rpm-build libcurl-devel libtool-ltdl-devel unixODBC-devel
wget http://www.digip.org/jansson/releases/jansson-2.7.tar.gz && tar xf jansson-2.7.tar.gz && cd jansson-2.7
tar xf jansson-2.7.tar.gz
cd jansson-2.7
./configure --libdir=/usr/lib64
make
make install
целиком:
wget http://www.digip.org/jansson/releases/jansson-2.7.tar.gz && tar xf jansson-2.7.tar.gz && cd jansson-2.7 && ./configure --libdir=/usr/lib64 && make && make install
DAHDI и LIBPRI
„DAHDI (Digium/Asterisk Hardware Device Interface) is the open source device interface technology used to control Digium and other legacy telephony interface cards.” (DAHDI)
Установка DADHI:
Распакуем ТАРом
tar -xvf dahdi-linux-complete*
cd /usr/src/dahdi-linux-complete*
make && make install && make config
LIBPRI:
„LIBPRI is an open source library that encapsulates the protocols used to communicate over ISDN Primary Rate Interfaces (T1, E1, J1). „ (LIBPRI)
Эти библиотеки нам нужны, если у нас будут T1 или E1 каналы.
Установка LIBPRI:
Распакуем ТАРом
tar -xvf libpri*
cd /usr/src/libpri*
make && make install
REALTIME?
/ Установим ODBC MySQL коннектор и ODBC библиотеки
yum -y install unixODBC unixODBC-devel libtool-ltdl libtool-ltdl-devel /
Сам Астериск
wget http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-13.15.0.tar.gz
tar xf asterisk-13.15.0.tar.gz
cd asterisk-13.15.0
./configure --libdir=/usr/lib64
make menuconfig
Если необходимо MP3
contrib/scripts/get_mp3_source.sh
make
make install
make config - устанавливает INIT скрипт (скрипт запуска)
make install-logrotate - устанавливает и настраивает файлы ЛОГов
make samples - делает примеры конфигов
asterisk -rx 'sip show peers' | grep XXX
tail -f /var/log/asterisk/full
accept_outofcall_message = yes
outofcall_message_context = messages
auth_message_requests = no
exten => _XXХX,1,MessageSend(sip:${EXTEN},"${CALLERID(name)}"${MESSAGE(from)})