Tuesday, November 24, 2009

PHP Fatal error: Call to undefined function mb_detect_encoding() in /var/www/html/voiceone/admin/lib/gettext/i18n.php on line 85

Make sure php-mbstring is installed.

1)yum install php-mbstring
2)service httpd restart

Running System Calls from Asterisk

Example


exten => 5000,1,system(echo "${DATETIME} - ${CALLERID} - ${CHANNEL}" >> /var/log/asterisk/calls)

You can call asterisk through the command line to parse a command via

Example

asterisk -r -x "console dial 5000@context"

Saturday, November 21, 2009

Installing Asterisk on CentOS5

Either via Yum or Source

YUM
1)Create these files in /etc/repos.d

asterisk.repo

[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

Create digium.repo

[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



2)yum -y install asterisk16 asterisk16-configs asterisk16-voicemail dahdi-linux dahdi-tools libpri iksemel.i386 iksemel-devel.i386

OR


Source


path_root="/usr/src/asterisk"
filez=`ls -1 $path_root/*tar.gz`

mkdir /usr/src/asterisk
`cd $path_root`

wget http://downloads.asterisk.org/pub/telephony/asterisk/releases/asterisk-1.4.27.tar.gz
wget http://downloads.asterisk.org/pub/telephony/dahdi-linux-complete/releases/dahdi-linux-complete-2.2.0.2+2.2.0.tar.gz
wget http://downloads.asterisk.org/pub/telephony/libpri/releases/libpri-1.4.10.2.tar.gz

for tarballs in $filez
do
clear
echo "Now Extracting ---- $tarballs"
sleep 1
#`tar -zxvf $tarballs -C $path_root`
tar -zxvf $tarballs -C $path_root
echo "Done"
sleep 1
done


#Now start compiling and installing packages

#Let's start off with DAHDI

cd dahdi-linux-complete*
echo "Now installing DAHDI HardWare Interface Drivers"
make && make install & make config && sleep 1
echo "DONE"
cd ..


#Let's install LibPRI
cd libpri*
echo "Now installing LibPRI"
make && make install
echo "DONE"
cd ..


#Install GTALK Modules
yum install iksemel.i386 iksemel-devel.i386

#Let's install Asterisk
cd asterisk-1.*
echo "Now installing Asterisk"
./configure && make && make menuselect && make install && make samples && make config && sleep 1
echo "DONE"
cd ..

Wednesday, November 4, 2009

Aide Notes

1)Creating the Database

aide -c /etc/aide.conf --init

2)Checking the Database against the current FS

aide -c /etc/aide.conf --check

3)Updating the Database after changes

aide -c /etc/aide.conf --update

Followers