How to install Asterisk on Rocky Linux 9.2
To Install Asterisk On Rocky Linux 9.2
Introduction:
Asterisk is a complete telephony server that provides Private Branch Exchange (PBX), Interactive Voice Response (IVR), Automated Call Distribution (ACD), Voice over IP (VoIP) gatewaying, Conferencing, and a wide variety of other telephony applications to a broad range of telephony devices including packet voice devices.
Installation Steps:-
Step 1: Check the OS version by using the below command
[root@Linuxhelp ~]# cat /etc/os-release
NAME="Rocky Linux"
VERSION="9.3 (Blue Onyx)"
ID="rocky"
ID_LIKE="rhel centos fedora"
VERSION_ID="9.3"
PLATFORM_ID="platform:el9"
PRETTY_NAME="Rocky Linux 9.3 (Blue Onyx)"
ANSI_COLOR="0;32"
LOGO="fedora-logo-icon"
CPE_NAME="cpe:/o:rocky:rocky:9::baseos"
HOME_URL="https://rockylinux.org/"
BUG_REPORT_URL="https://bugs.rockylinux.org/"
SUPPORT_END="2032-05-31"
ROCKY_SUPPORT_PRODUCT="Rocky-Linux-9"
ROCKY_SUPPORT_PRODUCT_VERSION="9.3"
REDHAT_SUPPORT_PRODUCT="Rocky Linux"
REDHAT_SUPPORT_PRODUCT_VERSION="9.3"
Step 2: Next change the directory to /usr/src directory by using the below command because this is a convenient place to store all our installations.
[root@Linuxhelp ~]# cd /usr/src
Step 3: Download the Asterisk source file by using the wget command
[root@Linuxhelp src]# wget https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-20-current.tar.gz
--2023-12-13 16:49:29-- https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-20-current.tar.gz
Resolving downloads.asterisk.org (downloads.asterisk.org)... 165.22.184.19, 2604:a880:400:d0::14:9001
Connecting to downloads.asterisk.org (downloads.asterisk.org)|165.22.184.19|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 28214209 (27M) [application/octet-stream]
Saving to: ‘asterisk-20-current.tar.gz’
asterisk-20-current.tar.gz 100%[==============================================================================================================>] 26.91M 6.09MB/s in 4.6s
2023-12-13 16:49:35 (5.80 MB/s) - ‘asterisk-20-current.tar.gz’ saved [28214209/28214209]
Step 4: After downloading long the files by using the below command.
[root@Linuxhelp src]# ll
total 27556
-rw-r--r--. 1 root root 28214209 Oct 18 22:40 asterisk-20-current.tar.gz
drwxr-xr-x. 2 root root 6 May 16 2022 debug
drwxr-xr-x. 2 root root 6 May 16 2022 kernels
Step 5: Extract the downloaded Asterisk source file by using the tar command
[root@Linuxhelp src]# tar xvfz asterisk-20-current.tar.gz
asterisk-20.5.0/
asterisk-20.5.0/.cleancount
asterisk-20.5.0/.gitignore
asterisk-20.5.0/.lastclean
asterisk-20.5.0/.version
asterisk-20.5.0/BSDmakefile
asterisk-20.5.0/BUGS
asterisk-20.5.0/CHANGES.md
asterisk-20.5.0/COPYING
asterisk-20.5.0/utils/db1-ast/recno/rec_utils.c
asterisk-20.5.0/utils/db1-ast/recno/recno.h
asterisk-20.5.0/utils/expr2.testinput
asterisk-20.5.0/utils/extconf.c
asterisk-20.5.0/utils/frame.c
asterisk-20.5.0/utils/frame.h
asterisk-20.5.0/utils/smsq.c
asterisk-20.5.0/utils/stereorize.c
asterisk-20.5.0/utils/streamplayer.c
asterisk-20.5.0/utils/utils.xml
asterisk-20.5.0/sounds/asterisk-core-sounds-en-gsm-1.6.1.tar.gz
asterisk-20.5.0/sounds/asterisk-moh-opsound-wav-2.03.tar.gz
Step 6: Go the extracted directory and run the below command to install the init script for svn chkconfig
[root@Linuxhelp src]# cd asterisk-20.5.0
[root@Linuxhelp asterisk-20.5.0]# dnf install -y initscripts svn chkconfig
Rocky Linux 9 - BaseOS 3.7 kB/s | 4.1 kB 00:01
Rocky Linux 9 - BaseOS 1.3 MB/s | 2.2 MB 00:01
Rocky Linux 9 - AppStream 3.8 kB/s | 4.5 kB 00:01
Rocky Linux 9 - AppStream 4.4 MB/s | 7.4 MB 00:01
Rocky Linux 9 - Extras 3.0 kB/s | 2.9 kB 00:00
Dependencies resolved.
==========================================================================================================================================================================================================
Package Architecture Version Repository Size
==========================================================================================================================================================================================================
Installing:
chkconfig x86_64 1.24-1.el9 baseos 161 k
initscripts x86_64 10.11.5-1.el9 baseos 210 k
subversion x86_64 1.14.1-5.el9_0 appstream 1.0 M
Installing dependencies:
apr x86_64 1.7.0-12.el9_3 appstream 122 k
apr-util x86_64 1.6.1-23.el9 appstream 94 k
apr-util-bdb x86_64 1.6.1-23.el9 appstream 12 k
Transaction Summary
==========================================================================================================================================================================================================
Install 10 Packages
Total download size: 3.2 M
Installed size: 13 M
Downloading Packages:
(1/10): apr-util-openssl-1.6.1-23.el9.x86_64.rpm 74 kB/s | 14 kB 00:00
(2/10): apr-util-bdb-1.6.1-23.el9.x86_64.rpm 310 kB/s | 12 kB 00:00
(3/10): initscripts-10.11.5-1.el9.x86_64.rpm 766 kB/s | 210 kB 00:00
(4/10): chkconfig-1.24-1.el9.x86_64.rpm 551 kB/s | 161 kB 00:00
(5/10): libserf-1.3.9-26.el9.x86_64.rpm 1.2 MB/s | 57 kB 00:00
(6/10): apr-util-1.6.1-23.el9.x86_64.rpm 953 kB/s | 94 kB 00:00
(7/10): utf8proc-2.6.1-4.el9.x86_64.rpm 1.4 MB/s | 79 kB 00:00
(8/10): apr-1.7.0-12.el9_3.x86_64.rpm 2.3 MB/s | 122 kB 00:00
(9/10): subversion-libs-1.14.1-5.el9_0.x86_64.rpm 6.6 MB/s | 1.5 MB 00:00
(10/10): subversion-1.14.1-5.el9_0.x86_64.rpm 3.8 MB/s | 1.0 MB 00:00
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total 1.4 MB/s | 3.2 MB 00:02
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Installing : apr-1.7.0-12.el9_3.x86_64 1/10
Installing : apr-util-bdb-1.6.1-23.el9.x86_64 2/10
Installing : apr-util-1.6.1-23.el9.x86_64 3/10
Installing : apr-util-openssl-1.6.1-23.el9.x86_64 4/10
Installing : libserf-1.3.9-26.el9.x86_64 5/10
Installing : utf8proc-2.6.1-4.el9.x86_64 6/10
Installing : subversion-libs-1.14.1-5.el9_0.x86_64 7/10
Installing : chkconfig-1.24-1.el9.x86_64 8/10
Installing : initscripts-10.11.5-1.el9.x86_64 9/10
Running scriptlet: initscripts-10.11.5-1.el9.x86_64 9/10
Created symlink /etc/systemd/system/sysinit.target.wants/import-state.service → /usr/lib/systemd/system/import-state.service.
Created symlink /etc/systemd/system/sysinit.target.wants/loadmodules.service → /usr/lib/systemd/system/loadmodules.service.
Installing : subversion-1.14.1-5.el9_0.x86_64 10/10
Running scriptlet: subversion-1.14.1-5.el9_0.x86_64 10/10
Verifying : chkconfig-1.24-1.el9.x86_64 1/10
Verifying : initscripts-10.11.5-1.el9.x86_64 2/10
Verifying : apr-util-openssl-1.6.1-23.el9.x86_64 3/10
Verifying : apr-util-bdb-1.6.1-23.el9.x86_64 4/10
Verifying : apr-util-1.6.1-23.el9.x86_64 5/10
Verifying : libserf-1.3.9-26.el9.x86_64 6/10
Verifying : utf8proc-2.6.1-4.el9.x86_64 7/10
Verifying : apr-1.7.0-12.el9_3.x86_64 8/10
Verifying : subversion-libs-1.14.1-5.el9_0.x86_64 9/10
Verifying : subversion-1.14.1-5.el9_0.x86_64 10/10
Installed:
apr-1.7.0-12.el9_3.x86_64 apr-util-1.6.1-23.el9.x86_64 apr-util-bdb-1.6.1-23.el9.x86_64 apr-util-openssl-1.6.1-23.el9.x86_64 chkconfig-1.24-1.el9.x86_64 initscripts-10.11.5-1.el9.x86_64
libserf-1.3.9-26.el9.x86_64 subversion-1.14.1-5.el9_0.x86_64 subversion-libs-1.14.1-5.el9_0.x86_64 utf8proc-2.6.1-4.el9.x86_64
Complete!
Step 7: Download the mp3 decoder library by using the below command.
[root@Linuxhelp asterisk-20.5.0]# ./contrib/scripts/get_mp3_source.sh
A addons/mp3
A addons/mp3/huffman.h
A addons/mp3/tabinit.c
A addons/mp3/Makefile
A addons/mp3/README
A addons/mp3/decode_i386.c
A addons/mp3/dct64_i386.c
A addons/mp3/MPGLIB_TODO
A addons/mp3/mpg123.h
A addons/mp3/layer3.c
A addons/mp3/mpglib.h
A addons/mp3/decode_ntom.c
A addons/mp3/interface.c
A addons/mp3/MPGLIB_README
A addons/mp3/common.c
Exported revision 204.
Step 8: Install the prerequisites for Asterisk Installation by using the below command
[root@Linuxhelp asterisk-20.5.0]# contrib/scripts/install_prereq install
Last metadata expiration check: 0:00:31 ago on Wednesday 13 December 2023 04:51:08 PM.
Package pkgconf-pkg-config-1.7.3-10.el9.x86_64 is already installed.
No match for argument: jansson-devel
No match for argument: speex-devel
No match for argument: speexdsp-devel
No match for argument: hoard
No match for argument: codec2-devel
Dependencies resolved.
==========================================================================================================================================================================================================
Package Architecture Version Repository Size
==========================================================================================================================================================================================================
Installing:
alsa-lib-devel x86_64 1.2.9-1.el9 appstream 795 k
binutils-devel x86_64 2.35.2-42.el9 appstream 4.0 M
bison x86_64 3.7.4-5.el9 appstream 921 k
fftw-devel x86_64 3.3.8-12.el9 appstream 128 k
Transaction Summary
==========================================================================================================================================================================================================
Install 108 Packages
Upgrade 3 Packages
Total download size: 93 M
Downloading Packages:
(1/111): cyrus-sasl-2.1.27-21.el9.x86_64.rpm 270 kB/s | 71 kB 00:00
(2/111): python3-pyparsing-2.4.7-9.el9.noarch.rpm 506 kB/s | 150 kB 00:00
(3/111): libquadmath-11.4.1-2.1.el9.x86_64.rpm 1.9 MB/s | 197 kB 00:00
(4/111): make-4.3-7.el9.x86_64.rpm 1.3 MB/s | 530 kB 00:00
(5/111): perl-Test-Harness-3.42-461.el9.noarch.rpm 2.4 MB/s | 267 kB 00:00
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total 15 MB/s | 93 MB 00:06
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Installing : zlib-devel-1.2.11-40.el9.x86_64 1/114
Upgrading : libxml2-2.9.13-5.el9_3.x86_64 2/114
Installing : libzstd-devel-1.5.1-2.el9.x86_64 3/114
Installing : perl-version-7:0.99.28-4.el9.x86_64 4/114
Installing : perl-File-Copy-2.34-480.el9.noarch 5/114
Installing : perl-CPAN-Meta-Requirements-2.140-461.el9.noarch
Verifying : python3-pyparsing-2.4.7-9.el9.noarch 1/114
Verifying : make-1:4.3-7.el9.x86_64 2/114
Verifying : cyrus-sasl-2.1.27-21.el9.x86_64 3/114
Verifying : libquadmath-11.4.1-2.1.el9.x86_64 4/114
Verifying : perl-Test-Harness-1:3.42-461.el9.noarch 5/114
Upgraded:
libxml2-2.9.13-5.el9_3.x86_64 net-snmp-libs-1:5.9.1-11.el9_3.1.x86_64 python3-libxml2-2.9.13-5.el9_3.x86_64
Installed:
adwaita-gtk2-theme-3.28-14.el9.x86_64 alsa-lib-devel-1.2.9-1.el9.x86_64 annobin-12.12-1.el9.x86_64 binutils-devel-2.35.2-42.el9.x86_64
bison-3.7.4-5.el9.x86_64 cmake-filesystem-3.20.2-9.el9_3.x86_64 cyrus-sasl-2.1.27-21.el9.x86_64 cyrus-sasl-devel-2.1.27-21.el9.x86_64
dwz-0.14-3.el9.x86_64 efi-srpm-macros-6-2.el9_0.noarch elfutils-devel-0.189-3.el9.x86_64 elfutils-libelf-devel-0.189-3.el9.x86_64
fftw-3.3.8-12.el9.x86_64 fftw-devel-3.3.8-12.el9.x86_64 fftw-libs-3.3.8-12.el9.x86_64 fftw-libs-double-3.3.8-12.el9.x86_64
fftw-libs-long-3.3.8-12.el9.x86_64 fftw-libs-quad-3.3.8-12.el9.x86_64 fftw-libs-single-3.3.8-12.el9.x86_64 flex-2.6.4-9.el9.x86_64
fonts-srpm-macros-1:2.0.5-7.el9.1.noarch gcc-11.4.1-2.1.el9.x86_64 gcc-c++-11.4.1-2.1.el9.x86_64 gcc-plugin-annobin-11.4.1-2.1.el9.x86_64
ghc-srpm-macros-1.5.0-6.el9.noarch glibc-devel-2.34-83.el9.7.x86_64 glibc-headers-2.34-83.el9.7.x86_64 go-srpm-macros-3.2.0-2.el9.noarch
Complete!
#############################################
## install completed successfully
Step 9: Now run the Asterisk configure script by using the below command
[root@Linuxhelp asterisk-20.5.0]# ./configure --libdir=/usr/lib64 --with-jansson-bundled
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for a sed that does not truncate output... /usr/bin/sed
checking for LIBXML2... yes
checking for GTK2... no
configure: creating ./config.status
config.status: creating makeopts
config.status: creating autoconfig.h
configure: Menuselect build configuration successfully completed
.$$$$$$$$$$$$$$$=..
.$7$7.. .7$$7:.
.$$:. ,$7.7
.$7. 7$$$$ .$$77
..$$. $$$$$ .$$$7
..7$ .?. $$$$$ .?. 7$$$.
$.$. .$$$7. $$$$7 .7$$$. .$$$.
.777. .$$$$$$77$$$77$$$$$7. $$$,
$$$~ .7$$$$$$$$$$$$$7. .$$$.
.$$7 .7$$$$$$$7: ?$$$.
$$$ ?7$$$$$$$$$$I .$$$7
$$$ .7$$$$$$$$$$$$$$$$ :$$$.
$$$ $$$$$$7$$$$$$$$$$$$ .$$$.
$$$ $$$ 7$$$7 .$$$ .$$$.
$$$$ $$$$7 .$$$.
7$$$7 7$$$$ 7$$$
$$$$$ $$$
$$$$7. $$ (TM)
$$$$$$$. .7$$$$$$ $$
$$$$$$$$$$$$7$$$$$$$$$.$$$$$$
$$$$$$$$$$$$$$$$.
configure: Package configured for:
configure: OS type : linux-gnu
configure: Host CPU : x86_64
configure: build-cpu:vendor:os: x86_64 : pc : linux-gnu :
configure: host-cpu:vendor:os: x86_64 : pc : linux-gnu :
Step 10: Run the make menuselect command and make selections based on your requirements.
[root@Linuxhelp asterisk-20.5.0]# make menuselect
Snap 1
Snap 2
Snap 3
Snap 4
Snap 5
Snap 6
Snap 7
Snap 8
Snap 9
Snap 10
Snap 11
Snap 12
Snap 13
Snap 14
Snap 15
Snap 16
Snap 17
Snap 18
Snap 19
CC="cc" CXX="g++" LD="" AR="" RANLIB="" CFLAGS="" LDFLAGS="" make -C menuselect CONFIGURE_SILENT="--silent" cmenuselect
make[1]: Entering directory '/usr/src/asterisk-20.5.0/menuselect'
gcc -g -D_GNU_SOURCE -Wall -Wno-deprecated-declarations -DHAVE_NCURSES -I/usr/include/libxml2 -c -o menuselect.o menuselect.c
gcc -g -D_GNU_SOURCE -Wall -Wno-deprecated-declarations -DHAVE_NCURSES -c -o strcompat.o strcompat.c
gcc -g -D_GNU_SOURCE -Wall -Wno-deprecated-declarations -DHAVE_NCURSES -c -o menuselect_curses.o menuselect_curses.c
gcc -o cmenuselect menuselect.o strcompat.o menuselect_curses.o -lncurses -ltinfo -lxml2
make[1]: Leaving directory '/usr/src/asterisk-20.5.0/menuselect'
CC="cc" CXX="g++" LD="" AR="" RANLIB="" CFLAGS="" LDFLAGS="" make -C menuselect CONFIGURE_SILENT="--silent" nmenuselect
make[1]: Entering directory '/usr/src/asterisk-20.5.0/menuselect'
gcc -g -D_GNU_SOURCE -Wall -Wno-deprecated-declarations -DHAVE_NCURSES -c -o menuselect_newt.o menuselect_newt.c
gcc -o nmenuselect menuselect.o strcompat.o menuselect_newt.o -lnewt -lxml2
make[1]: Leaving directory '/usr/src/asterisk-20.5.0/menuselect'
CC="cc" CXX="g++" LD="" AR="" RANLIB="" CFLAGS="" LDFLAGS="" make -C menuselect CONFIGURE_SILENT="--silent" gmenuselect
make[1]: Entering directory '/usr/src/asterisk-20.5.0/menuselect'
make[1]: Nothing to be done for 'gmenuselect'.
make[2]: Leaving directory '/usr/src/asterisk-20.5.0/menuselect'
menuselect/menuselect --check-deps menuselect.makeopts
menuselect/menuselect --check-deps menuselect.makeopts
menuselect changes saved!
make[1]: Leaving directory '/usr/src/asterisk-20.5.0'
Step 11: Compile and install Asterisk by running the make and make install command
[root@Linuxhelp asterisk-20.5.0]# make && make install
[LD] abstract_jb.o acl.o adsi.o alaw.o alertpipe.o aoc.o app.o ast_expr2.o ast_expr2f.o asterisk.o astfd.o astmm.o astobj2.o astobj2_container.o astobj2_global.o astobj2_hash.o astobj2_rbtree.o audiohook.o autochan.o autoservice.o backtrace.o bridge.o bridge_after.o bridge_basic.o bridge_channel.o bridge_roles.o bucket.o callerid.o channel.o channel_internal_api.o chanvars.o cli.o codec.o codec_builtin.o config_options.o conversions.o core_local.o core_unreal.o crypt.o data_buffer.o datastore.o db.o devicestate.o dial.o dns.o dns_core.o dns_naptr.o dns_query_set.o dns_recurring.o dns_srv.o dns_system_resolver.o dns_test.o dns_tlsa.o dns_txt.o endpoints.o event.o features_config.o file.o fixedjitterbuf.o format.o format_cache.o format_cap.o format_compatibility.o frame.o framehook.o fskmodem.o global_datastores.o hashtab.o heap.o image.o io.o iostream.o jitterbuf.o json.o loader.o lock.o logger_category.o manager_bridges.o manager_channels.o manager_endpoints.o manager_mwi.o manager_system.o max_forwards.o md5.o media_cache.o media_index.o message.o mixmonitor.o mwi.o named_locks.o netsock2.o optional_api.o options.o parking.o pbx.o pbx_app.o pbx_builtins.o pbx_functions.o pbx_hangup_handler.o pbx_ignorepat.o pbx_include.o pbx_sw.o pbx_switch.o pbx_timing.o pbx_variables.o pickup.o poll.o presencestate.o privacy.o refer.o rtp_engine.o say.o sched.o sdp_srtp.o security_events.o sem.o serializer.o sha1.o sip_api.o slinfactory.o smoother.o sorcery.o srv.o stasis.o stasis_bridges.o stasis_cache.o stasis_cache_pattern.o stasis_channels.o stasis_endpoints.o stasis_message.o stasis_message_router.o stasis_state.o stasis_system.o stdtime/localtime.o strcompat.o stream.o stringfields.o strings.o stun.o syslog.o taskprocessor.o tcptls.o tdd.o term.o test.o threadpool.o threadstorage.o time.o timing.o translate.o ulaw.o uri.o utf8.o utils.o uuid.o version.o xml.o xmldoc.o ccss.o cdr.o cel.o config.o dnsmgr.o dsp.o enum.o features.o http.o indications.o logger.o manager.o named_acl.o plc.o sounds.o udptl.o -> asterisk
+--------- Asterisk Build Complete ---------+
+ Asterisk has successfully been built, and +
+ can be installed by running: +
+ +
+ make install +
+-------------------------------------------+
Installing modules from channels...
Installing modules from pbx...
Installing modules from apps...
Installing modules from addons...
/usr/bin/install -c -m 755 contrib/scripts/astversion "/usr/sbin/"
/usr/bin/install -c -m 755 contrib/scripts/astgenkey "/usr/sbin/"
/usr/bin/install -c -m 755 contrib/scripts/autosupport "/usr/sbin/"
./build_tools/install_subst contrib/scripts/safe_asterisk "/usr/sbin/safe_asterisk";
/usr/bin/install -c -m 644 doc/core-*.xml "/var/lib/asterisk/documentation"
/usr/bin/install -c -m 644 doc/appdocsxml.xslt "/var/lib/asterisk/documentation"
/usr/bin/install -c -m 644 doc/appdocsxml.dtd "/var/lib/asterisk/documentation"
/usr/bin/install -c -m 644 doc/asterisk.8 "/usr/share/man/man8"
/usr/bin/install -c -m 644 doc/astdb*.8 "/usr/share/man/man8"
/usr/bin/install -c -m 644 contrib/scripts/astgenkey.8 "/usr/share/man/man8"
/usr/bin/install -c -m 644 contrib/scripts/autosupport.8 "/usr/share/man/man8"
/usr/bin/install -c -m 644 contrib/scripts/safe_asterisk.8 "/usr/share/man/man8"
if [ -f contrib/firmware/iax/iaxy.bin ] ; then \
/usr/bin/install -c -m 644 contrib/firmware/iax/iaxy.bin "/var/lib/asterisk/firmware/iax/iaxy.bin"; \
fi
CFLAGS=" -I/usr/include/libxml2 -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g3 " build_tools/mkpkgconfig "/usr/lib64/pkgconfig";
find static-http | while read x; do \
if test -d $x; then \
/usr/bin/install -c -m 755 -d "/var/lib/asterisk/$x"; \
else \
/usr/bin/install -c -m 644 $x "/var/lib/asterisk/$x" ; \
fi \
done
/usr/bin/install -c -m 644 doc/core-en_US.xml "/var/lib/asterisk/static-http";
/usr/bin/install -c -m 644 doc/appdocsxml.xslt "/var/lib/asterisk/static-http";
if [ -d doc/tex/asterisk ] ; then \
/usr/bin/install -c -d "/var/lib/asterisk/static-http/docs" ; \
for n in doc/tex/asterisk/* ; do \
/usr/bin/install -c -m 644 $n "/var/lib/asterisk/static-http/docs" ; \
done \
fi
for x in images/*.jpg; do \
/usr/bin/install -c -m 644 $x "/var/lib/asterisk/images" ; \
done
make -C sounds install
make[1]: Entering directory '/usr/src/asterisk-20.5.0/sounds'
make[1]: Leaving directory '/usr/src/asterisk-20.5.0/sounds'
find rest-api -name "*.json" | while read x; do \
/usr/bin/install -c -m 644 $x "/var/lib/asterisk/rest-api" ; \
done
+---- Asterisk Installation Complete -------+
+ +
+ YOU MUST READ THE SECURITY DOCUMENT +
+ +
+ Asterisk has successfully been installed. +
+ If you would like to install the sample +
+ configuration files (overwriting any +
+ existing config files), run: +
+ +
+ For generic reference documentation: +
+ make samples +
+ +
+ For a sample basic PBX: +
+ make basic-pbx +
+ +
+ +
+----------------- or ---------------------+
+ +
+ You can go ahead and install the asterisk +
+ program documentation now or later run: +
+ +
+ make progdocs +
+ +
+ **Note** This requires that you have +
+ doxygen installed on your local system +
+-------------------------------------------+
[root@Linuxhelp asterisk-20.5.0]#
Step 12: run make samples command to install the sample configs.
[root@Linuxhelp asterisk-20.5.0]# make samples
Installing adsi config files...
/usr/bin/install -c -d "/etc/asterisk"
Installing configs/samples/asterisk.adsi
Installing configs/samples/telcordia-1.adsi
Installing other config files...
Installing file configs/samples/acl.conf.sample
Installing file configs/samples/adsi.conf.sample
Installing file configs/samples/aeap.conf.sample
Installing file configs/samples/agents.conf.sample
Installing file configs/samples/alarmreceiver.conf.sample
/usr/bin/install -c -d "/var/spool/asterisk/voicemail/default/1234/INBOX"
build_tools/make_sample_voicemail "//var/lib/asterisk" "//var/spool/asterisk"
Installing file phoneprov/000000000000.cfg
Installing file phoneprov/000000000000-directory.xml
Installing file phoneprov/000000000000-phone.cfg
Installing file phoneprov/polycom_line.xml
Installing file phoneprov/polycom.xml
Installing file phoneprov/snom-mac.xml
Step 13: Run the below command to install basic pbx configuration files
[root@Linuxhelp asterisk-20.5.0]# make basic-pbx
Installing basic-pbx config files...
Installing file configs/basic-pbx/asterisk.conf
Installing file configs/basic-pbx/cdr.conf
Installing file configs/basic-pbx/cdr_custom.conf
Installing file configs/basic-pbx/confbridge.conf
Installing file configs/basic-pbx/extensions.conf
Installing file configs/basic-pbx/indications.conf
Installing file configs/basic-pbx/logger.conf
Installing file configs/basic-pbx/modules.conf
Installing file configs/basic-pbx/musiconhold.conf
Installing file configs/basic-pbx/pjsip.conf
Config file configs/basic-pbx/pjsip_notify.conf is unchanged
Installing file configs/basic-pbx/queues.conf
Installing file configs/basic-pbx/README
Installing file configs/basic-pbx/voicemail.conf
Updating asterisk.conf
Step 14: Run the make config command to install the Asterisk startup script
[root@Linuxhelp asterisk-20.5.0]# make config
Step 15: Update the shared libraries cache by using the below command
[root@Linuxhelp asterisk-20.5.0]# ldconfig
Step 16: Now reboot the system once by using the below command
[root@Linuxhelp asterisk-20.5.0]# reboot
Step 17: After the reboot, disable the SELinux by running the below command.
[root@Linuxhelp asterisk-20.5.0]# setenforce 0
Step 18: Now check the installed asterisk server by entering into Asterisk CLI mode by using the below command.
[root@Linuxhelp ~]# asterisk -rvvvvvvv
Asterisk 20.5.0, Copyright (C) 1999 - 2022, Sangoma Technologies Corporation and others.
Created by Mark Spencer <markster@digium.com>
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core show warranty' for details.
This is free software, with components licensed under the GNU General Public
License version 2 and other licenses; you are welcome to redistribute it under
certain conditions. Type 'core show license' for details.
=========================================================================
Connected to Asterisk 20.5.0 currently running on Linuxhelp (pid = 2260)
Linuxhelp*CLI>
Conclusion:
We have reached the end of this article. In this guide, we have walked you through the steps required to install Asterisk on Rocky Linux 9.2. Your feedback is much welcome.