Asterisk: Difference between revisions

From Halfface
Jump to navigation Jump to search
No edit summary
No edit summary
Line 115: Line 115:
  # Error checking.
  # Error checking.
  tail /var/log/asterisk/full
  tail /var/log/asterisk/full
Asterisk installation through rpm.
yum install lame php php-pear php-pear-DB spandsp zaptel asterisk asterisk-addons
chmod -R g+rwx /etc/asterisk
chmod g+s /etc/asterisk
/etc/group
apache belongs to asterisk
asterisk belongs to apache
svn co http://svn.freepbx.org/freepbx/trunk /usr/src/freepbx
/usr/src/freepbx/install_amp
/www/www-halfface/freepbx
/var/lib/asterisk/bin
chown -R apache:apache /www/www-halfface/freepbx/
chmod -R g+rwx  /www/www-halfface/freepbx/
chmod g+s  /www/www-halfface/freepbx/

Revision as of 21:55, 14 October 2007

823547@fwd.pulver.com
823547@iax.fwdnet.net
+882 9999 432225
+882 9900 52230
Mark Spencer at Digium.

Usefull commands.

sip show registry

sip show users

sip show peers

sip debug
sip no debug
Download source.
http://www.asterisk.org
Mailing list. Commercial , development, user.
http://list.digium.com
Wiki.
http://www.voip-info.org
Documentation project.
http://www.asteriskdocs.org
AoR Address-of-Record, a canonical address by which a user is known in SIP
e.164 International Telecominication Union standard for telefon numbers.
fxo Foreign eXchange Office (pstn)
fxs Foreign eXchange Station (phone)
ivr Interactive voice response 
moh Message On Hold
pstn public switched telephone network
proxy servers route requests to the user's current location
registrar registrations, User Agent Server handles registers
rtp Real-time Transport Protocol
sdp Session Description Protocol
tdm Time Division Multiplexing (circuit switched network)
  1. Communication overview.
Asterisk
chan_zap.so
/dev/zap
zaptel
Hardware driver wctdm
hardware
Your Woize phone number is +46754400875. Your Woize account is now fully functional
# Install dependencies.
yum -y install gcc libxml2-devel libtiff-devel mysql-server php-gd php-mysql kernel-devel kernel-smp-devel bison ncurses-devel audiofile-devel subversion libogg-devel openssl-devel mysql-devel

# Install livna repository.
rpm -i http://rpm.livna.org/livna-release-7.rpm

# Install lame
yum install lame

# Prepare source.
cd /usr/src
tar zxf /net/www/storage/temp/freepbx-2.3.0.tar.gz
svn co http://svn.digium.com/svn/asterisk/branches/1.2 asterisk
svn co http://svn.digium.com/svn/asterisk-addons/branches/1.2 asterisk-addons
svn co http://svn.digium.com/svn/asterisk-sounds/trunk asterisk-sounds
svn co http://svn.digium.com/svn/zaptel/branches/1.2 zaptel
svn co http://svn.digium.com/svn/libpri/branches/1.2 libpri

# Create ztdummy
cd /usr/src/zaptel
cp ztdummy.c ztdummy.c.orig
sed -i "s/if 0/if 1/" ztdummy.c
make
make install
make config
echo "modprobe ztdummy" >> /etc/rc.d/rc.local

# Install asterisk
cd /usr/src/asterisk
mkdir /var/run/asterisk
make install
make config 

# Create asterisk user.
useradd -c "Asterisk PBX" -d /var/lib/asterisk asterisk
mkdir /var/lib/php/session/
chown asterisk /var/lib/php/session/

# Setup mysql database.
cd /usr/src/freepbx-2.3.0/
mysqladmin create asterisk
mysqladmin create asteriskcdrdb
mysql asterisk < SQL/newinstall.sql
mysql asteriskcdrdb < SQL/cdr_mysql_table.sql

# Setup passwords on databases.
mysql
GRANT ALL PRIVILEGES ON asteriskcdrdb.* TO asteriskuser@localhost IDENTIFIED BY 'amp109';
GRANT ALL PRIVILEGES ON asterisk.* TO asteriskuser@localhost IDENTIFIED BY 'amp109';
flush privileges;
\q
mysqladmin -u root password 'PGPisvery5afe'

# Install FreePBX.
cd /usr/src/asterisk-addons
cp Makefile Makefile.orig
sed -i 's/SOURCE/SOURCE -DMYSQL_LOGUNIQUEID/' Makefile
make && make install

# Backup asterisk database.
tar zcf /temp/etc_asterisk /etc/asterisk/

cd /usr/src/freepbx-2.3.0/
rpm -y install php php-pear-DB

# Error checking.
tail /var/log/asterisk/full

Asterisk installation through rpm.

yum install lame php php-pear php-pear-DB spandsp zaptel asterisk asterisk-addons

chmod -R g+rwx /etc/asterisk
chmod g+s /etc/asterisk 

/etc/group
apache belongs to asterisk
asterisk belongs to apache

svn co http://svn.freepbx.org/freepbx/trunk /usr/src/freepbx 

/usr/src/freepbx/install_amp
/www/www-halfface/freepbx
/var/lib/asterisk/bin

chown -R apache:apache /www/www-halfface/freepbx/
chmod -R g+rwx  /www/www-halfface/freepbx/
chmod g+s  /www/www-halfface/freepbx/