How to install Asterisk on CentOS? Package installation.
Follow these steps to install Asterisk (Open source PBX) on CentOS.
Step 1.
Make sure following packages were installed on CentOS/
- kernel-devel OR kernel-smp-devel
- bison
- openssl-devel
To installed above packages run following commands
sudo yum install kernel-devel sudo yum install bison sudo yum install openssl-devel
Step 2.
Now add atrpms repository for Asterisk Installation
- Create the file called atrpms.repo
sudo vim /etc/yum.repos.d/atrpms.repo
put following in the file
[atrpms] name=CentOS $releasever - $basearch - ATrpms baseurl=http://dl.atrpms.net/el$releasever-$basearch/atrpms/stable gpgkey=http://atrpms.net/RPM-GPG-KEY.atrpms gpgcheck=1
Step 3.
Run update command
sudo yum -y update
Step 4.
Now run following command to installed Asterisk
sudo yum install asterisk
After installation completed run following commands to check Asterisk status.
To check Asterisk Status
sudo /etc/init.d/asterisk status
To Start Asterisk
sudo /etc/init.d/asterisk start
To Stop Asterisk
sudo /etc/init.d/asterisk stop
To Restart Asterisk
sudo /etc/init.d/asterisk restart
5. Asterisk CLI
Go to asterisk directory and then use command -rvvv
cd /etc/asterisk/
asterisk]# asterisk -rvvvv
where ‘v’ indicates verbosity
Good Luck!
Reference:
I got all excited by this, but checked http://atrpms.net/dist/el5/ and see it only has 1.2 or 1.4 packages. I’m using 1.6 :-(
Thanks weave;
This repository have the stable version of asterisk and for those who do not want to download asterisk code and compile by themselve.
By the way if you have package installation repository link for Asterisk 1.6 please post it.
Cheers
Sh
I added the following lines to the repo name, which I labeled [asterisk] to avoid conficting packages:
==========
disable=*
enablepkg=*asterisk*,*dahdi*
=========
This way you can change from stable to bleeding or testing for asterisk only as well.
Hi, I’ve install Asterisk on CentOS 4.5. It show successfully but in /etc/rc.d/init.d doesn’t have asterisk so that I can start or stop asterisk by the command below :
/etc/rc.d/init.d/asterisk start
/etc/rc.d/init.d/asterisk stop
Have you ever met this problem ? Please tell my why, thank you.