CentOS5.5+Elastix 2.x on Amazon EC2
?????????????? CentOS ??????? CentOS ??? Elastix 2.x?
?????
• Elastix 2.2: CentOS 5.6 (Linux 2.6.18-238.12.1) • Elastix 2.3: CentOS 5.7 (Linux 2.6.18-238.12.1) • Elastix 2.4: CentOS 5.9 (Linux 2.6.18-348.1.1) • ?????????
?? Instance ?? AMI: CentOS-55-Base-32bit-10GB-S3-pvgrub--v1-0 (ami-eb807682)
• Kernel : 2.6.18-194.26.1.el5xen (uname -r) • Linux: CentOS 5.5 • root : 10GB • OS: 32 bit • Region: US East
?? Elastix 2.2 ISO http://www.elastix.org/index.php/en/downloads.html cd /mnt wget http://downloads.sourceforge.net/project/elastix/Elastix%20PBX%20Appliance%20Software/2.2.0/ Elastix-2.2.0-i386-bin-01Nov2011.iso?r=http%3A%2F%2Fwww.elastix.org%2Findex.php%2Fen%2Fdownloads.html&ts=1340876498&use_mirror=nchc mkdir ISO/ mount -o loop Elastix-2.2.0-i386-bin-01Nov2011.iso ISO/
?? /etc/yum.repos.d/Elastix-cd.repo
[elastix-cd] name=Elastix RPM Repository for CentOS baseurl=file:///mnt/ISO gpgcheck=0 enabled=1
[elastix-epel] name=Extra Packages for Enterprise Linux 5 - $basearch mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch failovermethod=priority gpgcheck=0 enabled=1
?? CentOS 5.6&7 ? kernel-xen, kernel-xen-devel cd /mnt/ISO/Elastix yum --nogpgcheck localinstall kernel-xen-2.6.18-238.12.1.el5.i686.rpm kernel-xen-devel-2.6.18-238.12.1.el5.i686.rpm
1 CentOS5.5+Elastix 2.x on Amazon EC2
?? /boot/grub/menu.lst default=0 <==== ??? timeout=1 title CentOS (2.6.18-238.12.1.el5xen) root (hd0) kernel /boot/vmlinuz-2.6.18-238.12.1.el5xen ro root=/dev/sda1 initrd /boot/initrd-2.6.18-238.12.1.el5xen.img title CentOS (2.6.18-194.26.1.el5xen) root (hd0) kernel /boot/vmlinuz-2.6.18-194.26.1.el5xen ro root=/dev/sda1 initrd /boot/initrd-2.6.18-194.26.1.el5xen--with-xenblk-xennet.img
??? Instance ???????
? ISO ?? mount mount -o loop Elastix-2.2.0-i386-bin-01Nov2011.iso /mnt/ISO
?? DAHDI ?? ?????? Meetme ?????????
?? ISO ????? DAHDI ????????????? SRPM?
SRPM ???http://repo.elastix.org/elastix/inde...updates/SRPMS/ cd ~ wget 'http://repo.elastix.org/elastix/index.php?dir=2.2/updates/ SRPMS/&file=dahdi-2.4.1.2-5.src.rpm' yum install rpm-build newt-devel libusb-devel gcc rpmbuild --rebuild dahdi-2.4.1.2-5.src.rpm cd /usr/src/redhat/RPMS/i386/ rpm -ivh dahdi-2.4.1.2-5.i386.rpm rpm -ivh kernel-module-dahdi-2.4.1.2-5_2.6.18_238.12.1.el5.i386.rpm
? ISO ???? cd /mnt/ISO/Elastix
// for Elastix 2.2 yum --nogpgcheck localinstall dahdi-2.4.1.2-5.i686.rpm kernel-module-dahdi-xen-2.4.1.2-5_2.6.18_238.12.1.el5.i686.rpm
// For Elastix 2.3 yum --nogpgcheck localinstall dahdi-2.4.1.2-10.i686.rpm kmod-dahdi-xen-2.4.1.2-10.i686.rpm
// For Elastix 2.4 yum --nogpgcheck localinstall dahdi-2.6.1-4.i686.rpm cd ~ wget http://repo.elastix.org/elastix/2.0/updates/i386/RPMS/kmod-dahdi-xen-2.6.1-4.i686.rpm yum --nogpgcheck localinstall kmod-dahdi-xen-2.6.1-4.i686.rpm
2 CentOS5.5+Elastix 2.x on Amazon EC2
?? dahdi ?? chkconfig dahdi on service dahdi start dahdi_test -v
??? MySQL ??? *??* yum install mysql-server chkconfig mysqld on service mysqld start
?? root ??? eLaStIx.2oo7????????????? mysqladmin -uroot -p password 'eLaStIx.2oo7'
?? Elastix ?? ??? /mnt/ISO/Elastix ???????? cd /mnt/ISO/Elastix yum --nogpgcheck install asterisk* elastix-* freeze fxload lzop perl-HTML-TokeParser-Simple perl-WWW-Mechanize mod_ssl mlocate gcc gcc-c++ system-config-network-tui wget sox nano
????????????????????????
????
• ?? Web UI (Elastix + FreePBX) ???? admin / palosanto? • ?? vTigerCRM ???admin / eLaStIx.asteriskuser.2oo7 • ???????????????????
????????? ?? Sangoma ??? chkconfig wanrouter off
???????? (optional) mysql> select host,user,password from mysql.user; mysql> delete from mysql.user where user='root' and host='ip-10-134-166-4'; mysql> delete from mysql.user where user='root' and host='127.0.0.1'; mysql> delete from mysql.user where user='' and host='localhost'; mysql> delete from mysql.user where user='' and host='ip-10-134-166-4'; mysql> flush privileges;
?? MySQL Root ??
3 CentOS5.5+Elastix 2.x on Amazon EC2 mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('mypass'); mysql> flush privileges;
?? /etc/elastix.conf ???? elastix.conf ????????????????/????? mysqlrootpwd=mypass ....
?? EPEL ????? ??????? EPEL ?????? Addons ?????? ?? /etc/yum.repos.d/epel.repo
[epel] name=Extra Packages for Enterprise Linux 5 - $basearch #baseurl=http://download.fedoraproject.org/pub/epel/5/$basearch mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch failovermethod=priority enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL
[epel-debuginfo] name=Extra Packages for Enterprise Linux 5 - $basearch - Debug #baseurl=http://download.fedoraproject.org/pub/epel/5/$basearch/debug mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-5&arch=$basearch failovermethod=priority enabled=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL gpgcheck=1
[epel-source] name=Extra Packages for Enterprise Linux 5 - $basearch - Source #baseurl=http://download.fedoraproject.org/pub/epel/5/SRPMS mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-5&arch=$basearch failovermethod=priority enabled=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL gpgcheck=1
?? /etc/yum.repos.d/epel-testing.repo
[epel-testing] name=Extra Packages for Enterprise Linux 5 - Testing - $basearch #baseurl=http://download.fedoraproject.org/pub/epel/testing/5/$basearch mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=testing-epel5&arch=$basearch failovermethod=priority enabled=0
4 CentOS5.5+Elastix 2.x on Amazon EC2 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL
[epel-testing-debuginfo] name=Extra Packages for Enterprise Linux 5 - Testing - $basearch - Debug #baseurl=http://download.fedoraproject.org/pub/epel/testing/5/$basearch/debug mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=testing-debug-epel5&arch=$basearch failovermethod=priority enabled=0 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL gpgcheck=1
[epel-testing-source] name=Extra Packages for Enterprise Linux 5 - Testing - $basearch - Source #baseurl=http://download.fedoraproject.org/pub/epel/testing/5/SRPMS mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=testing-source-epel5&arch=$basearch failovermethod=priority enabled=0 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL gpgcheck=1
?? EPEL ? RPM GPG KEY rpm --import http://mirror01.idc.hinet.net/EPEL//RPM-GPG-KEY-EPEL
Q & A Q:Elastix 2.3 ?????Web-UI > PBX ???? A??? /etc/amportal.conf ? DB ??????????????? mysql> SET PASSWORD FOR 'asteriskuser'@'localhost' = PASSWORD('eLaStIx.asteriskuser.2oo7');
Q: Elastix 2.4 ???? ??? ISO ??????????????? kernel-xen ???????????? ????????http://forum.elastix.org/viewtopic.p...it=xen#p118574
2.x RPM ???http://repo.elastix.org/elastix/2/updates/
1. ???? kernel-xen ?? ????????????? CentOS 5.9 ??????????? CentOS 5.10 ???????????
???? kernel-xen, kernel-xen-devel yum install kernel-xen-2.6.18-348.12.1.el5 kernel-xen-devel-2.6.18-348.12.1.el5
Notes:
??? kernel-xen ?????? Elastix 2.9 ??? CentOS ????
5 CentOS5.5+Elastix 2.x on Amazon EC2
??? 64-bit ???????????
2. ????? CentOS 5.9 yum -y update
3. ?? kmod-dahdi-xen ?? wget http://repo.elastix.org/elastix/2.0/updates/i386/RPMS/kmod-dahdi-xen-2.6.1-4.i686.rpm
Q:?????????????????
• ?? /var/log/httpd/ssl_error_log • ?? Manager ??? amportal.conf ? manager.conf ???? • ?? /etc/hosts
?? /etc/hosts
127.0.0.1 localhost.localdomain localhost
Q:???????????????????????
• ?? /etc/rc.local ???? /usr/sbin/amportal start_fop • ???? elastix-firstboot, elastix-updaterd
Q:???? email ???????"Error applying changes. failed to login to IMAP" Ans:
1. ?? chmod 0644 /etc/sasldb2
2. ?? cyrus ??
# cat /etc/elastix.conf cyrususerpwd=XXXXXXXXXX
# cyradm -u cyrus localhost ????
3. ???????????????????
# /usr/sbin/saslpasswd2 -c cyrus -u example.com
6 CentOS5.5+Elastix 2.x on Amazon EC2
Q:?????????? "FATAL ERROR: Trying to write null voicemail file! I efuser to continue!" Ans: ??????? Elastix ???????
• /etc/asterisk/vm_email.inc • /etc/asterisk/vm_general.inc • /etc/asterisk/voicemail.conf
7