同我一起安装dahdi、asterisk的最新版本(转)

转自:http://www.asteriskcn.com/index.php?q=content/%E5%90%8C%E6%88%91%E4%B8%80%E8%B5%B7%E5%AE%89%E8%A3%85dahdi%E3%80%81asterisk%E7%9A%84%E6%9C%80%E6%96%B0%E7%89%88%E6%9C%AC

闲话少叙,让我们开始迈出第一步,安装asterisk基本环境:

安装CentOS 5.4 DVD 光盘版,选择costom安装方式,不安装无用的,如果想方便那不选上x-windows .
进到#号下,一般我们选择/usr/src目录进行下载及安装:
cd /usr/src
//进行环境配置:
//更换语言:
vi /etc/sysconfig/i18n
//将LANG="zh_CN.UTF-8" 换成 LANG="en_US.UTF-8"
//增加DNS解晰:
vi /etc/resolv.conf
//添加 nameserver 202.97.224.68
//安装YUM环境:
http://www.afuns.cn/index.php?p=36&a=view&r=23
//安装开发环境及编绎环境:
yum -y groupinstall 'Development Tools'
yum -y install libtool*
yum -y install kernel-heads*
yum -y install ncurses-dev*
yum -y install kernel-devel
yum install -y kernel kernel-devel
//安装apache、PHP、MYSQL环境:
yum -y install httpd php mysql mysql-server php-mysql
/sbin/chkconfig httpd on
/sbin/chkconfig --add mysqld
/sbin/chkconfig mysqld on
/sbin/service httpd start
/sbin/service mysqld start
//设置mysql数据库root帐号密码。
mysqladmin -u root password 'newpassword' [引号内填密码]
//让mysql数据库更安全
mysql -u root -p [此时会要求你输入刚刚设置的密码,输入后回车即可]
mysql> DROP DATABASE test; [删除test数据库]
mysql> DELETE FROM mysql.user WHERE user = ''; [删除匿名帐户]
mysql> FLUSH PRIVILEGES; [重载权限]
//安装apache扩展 //安装php的扩展//安装mysql扩展
yum -y install httpd-manual mod_ssl mod_perl mod_auth_mysql
yum -y install php-gd
yum -y install php-gd php-xml php-mbstring php-ldap php-pear php-xmlrpc
yum -y install mysql-connector-odbc mysql-devel libdbi-dbd-mysql
//下载最新的ver:1.6版本
wget http://downloads.asterisk.org/pub/telephony/libpri/old/libpri-1.4.10.2.tar.gz
wget http://downloads.asterisk.org/pub/telephony/asterisk/old-releases/asterisk-1.6.2.8-rc1.tar.gz
wget http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-addons-1.6.2.1.tar.gz
wget http://downloads.asterisk.org/pub/telephony/dahdi-linux/releases/dahdi-linux-2.3.0.tar.gz
wget http://downloads.asterisk.org/pub/telephony/dahdi-tools/releases/dahdi-tools-2.3.0.tar.gz
//安装libpri:
tar zxvf libpri-1.4.10.2.tar.gz
cd libpri-1.4.10.2
make
make install
cd ..
//安装dahdi驱动:
tar zxvf dahdi-linux-2.3.0.tar.gz
cd dahdi-linux-2.3.0
make
make install
cd ..
//安装dahdi-tools工具:
tar zxvf dahdi-tools-2.3.0.tar.gz
cd dahdi-tools-2.3.0
./configure
make
make install
make config
cd ..
//安装asterisk:
tar zxvf asterisk-1.6.2.8-rc1.tar.gz
cd asterisk-1.6.2.8-rc1
./configure
make
make install
make config
make samples
cd ..
//安装asterisk扩展包(H323/mysql支持):
tar zxvf asterisk-addons-1.6.2.1.tar.gz
cd asterisk-addons-1.6.2.1
./configure
make
make install
make samples
至此asterisk的基本环境安装完毕!

另:安装asterisk的yum方式:

Use the text editor of your choice to create a new file named "centos-asterisk.repo" in the "/etc/yum.repos.d" folder. Add the following text to the file:
[asterisk-tested]
name=CentOS-$releasever - Asterisk - Tested
baseurl=http://packages.asterisk.org/centos/$releasever/tested/$basearch/
enabled=0
gpgcheck=0
#gpgkey=http://packages.asterisk.org/RPM-GPG-KEY-Digium
[asterisk-current]
name=CentOS-$releasever - Asterisk - Current
baseurl=http://packages.asterisk.org/centos/$releasever/current/$basearch/
enabled=1
gpgcheck=0
#gpgkey=http://packages.asterisk.org/RPM-GPG-KEY-Digium
Save the new file and create another named "centos-digium.repo" and insert the following text:
[digium-tested]
name=CentOS-$releasever - Digium - Tested
baseurl=http://packages.digium.com/centos/$releasever/tested/$basearch/
enabled=0
gpgcheck=0
#gpgkey=http://packages.digium.com/RPM-GPG-KEY-Digium
[digium-current]
name=CentOS-$releasever - Digium - Current
baseurl=http://packages.digium.com/centos/$releasever/current/$basearch/
enabled=1
gpgcheck=0
#gpgkey=http://packages.digium.com/RPM-GPG-KEY-Digium
At this point your system has been updated to use the Asterisk and Digium repositories in addition to the base CentOS repositories. You are now ready to install Asterisk. To star the installation, execute the following at the Linux command line:
[root@localhost~]# yum install asterisk16 asterisk16-configs asterisk16-voicemail dahdi-linux dahdi-tools libpri
The system will respond with something like:

yum方式安装参考链接:http://www.vpsee.com/2010/02/install-and-configure-asterisk-and-digium-card-on-centos-5/

Powered by Zoundry Raven

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值