Asterisk Upgrade: Difference between revisions

From KlavoWiki
Jump to navigationJump to search
New page: This upgrade is based on Asterisk 1.6.0.1 and DAHDI 2.0.0 = Prerequisite = It is not necessary but I like doing it as a precaution. I stop DAHDI and Asterisk before the upgrade. <pre> se...
 
No edit summary
 
(7 intermediate revisions by the same user not shown)
Line 1: Line 1:
This upgrade is based on Asterisk 1.6.0.1 and DAHDI 2.0.0
I've been using this bash script to upgrade my Asterisk versions, staying with the same release number.
<pre>
#!/bin/bash
 
ASTER=12


= Prerequisite =
It is not necessary but I like doing it as a precaution.  I stop DAHDI and Asterisk before the upgrade.
<pre>
service asterisk stop
service dahdi stop
</pre>


= DAHDI =
cd /usr/src
== DAHDI Linux ==
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-$ASTER-current.tar.gz
<pre>
tar xvf asterisk-$ASTER-current.tar.gz
cd dahdi-linux-2.1.0.3
rm -f asterisk-$ASTER-current.tar.gz
make
make install
</pre>


== DAHDI Tools ==
if [ -d $(tar tvf asterisk-$ASTER-current.tar.gz | tail -n 1 | cut -d' ' -f11 | cut -d'/' -f1) ]
<pre>
then
cd dahdi-tools-2.1.0.2
  echo "Folder already Exists. Upgrade Aborted"
  exit 0
fi


cd $(ls -d /usr/src/asterisk-$ASTER* | tail -1 |  cut -d' ' -f8)
./configure
./configure
make menuselect
./contrib/scripts/get_mp3_source.sh
 
make menuselect.makeopts
menuselect/menuselect --enable format_mp3 --enable app_mysql --enable cdr_mysql --enable app_fax --enable app_meetme --disable pbx_ael --disable pbx_realtime --disable-category MENUSELECT_CDR --disable-category MENUSELECT_CORE_SOUNDS --disable-category MENUSELECT_MOH --disable-category MENUSELECT_EXTRA_SOUNDS menuselect.makeopts
 
if [ $ASTER -eq 12 ]
then
  menuselect/menuselect --disable res_ari --disable res_ari_model menuselect.makeopts
fi
 
make
make
make install
make install
</pre>
</pre>


= Asterisk =
 
manual commands
<pre>
<pre>
cd asterisk-1.6.0.3
./configure
./configure
make menuselect
./contrib/scripts/get_mp3_source.sh
 
make menuselect.makeopts
 
menuselect/menuselect --enable format_mp3 --enable app_mysql --enable cdr_mysql --enable app_fax --enable app_meetme --disable pbx_ael --disable pbx_realtime --disable-category MENUSELECT_CDR --disable-category MENUSELECT_CORE_SOUNDS --disable-category MENUSELECT_MOH --disable-category MENUSELECT_EXTRA_SOUNDS menuselect.makeopts
 
menuselect/menuselect --disable res_ari --disable res_ari_model menuselect.makeopts
 
make
make
make upgrade
make install
</pre>
</pre>


= Start Services =
[[Category : Asterisk]] [[Category : Linux]]
If you stoped the services before the upgrade you now need to start them again.
<pre>
service dahdi start
service asterisk start
</pre>
 
 
[[Category : Asterisk]]

Latest revision as of 02:46, 3 June 2014

I've been using this bash script to upgrade my Asterisk versions, staying with the same release number.

#!/bin/bash

ASTER=12


cd /usr/src
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk-$ASTER-current.tar.gz
tar xvf asterisk-$ASTER-current.tar.gz
rm -f asterisk-$ASTER-current.tar.gz

if [ -d $(tar tvf asterisk-$ASTER-current.tar.gz | tail -n 1 | cut -d' ' -f11 | cut -d'/' -f1) ]
 then
   echo "Folder already Exists.  Upgrade Aborted"
   exit 0
 fi

cd $(ls -d /usr/src/asterisk-$ASTER* | tail -1 |  cut -d' ' -f8)
./configure
./contrib/scripts/get_mp3_source.sh

make menuselect.makeopts
menuselect/menuselect --enable format_mp3 --enable app_mysql --enable cdr_mysql --enable app_fax --enable app_meetme --disable pbx_ael --disable pbx_realtime --disable-category MENUSELECT_CDR --disable-category MENUSELECT_CORE_SOUNDS --disable-category MENUSELECT_MOH --disable-category MENUSELECT_EXTRA_SOUNDS menuselect.makeopts

if [ $ASTER -eq 12 ]
 then
  menuselect/menuselect --disable res_ari --disable res_ari_model menuselect.makeopts
 fi

make
make install


manual commands

./configure
./contrib/scripts/get_mp3_source.sh

make menuselect.makeopts

menuselect/menuselect --enable format_mp3 --enable app_mysql --enable cdr_mysql --enable app_fax --enable app_meetme --disable pbx_ael --disable pbx_realtime --disable-category MENUSELECT_CDR --disable-category MENUSELECT_CORE_SOUNDS --disable-category MENUSELECT_MOH --disable-category MENUSELECT_EXTRA_SOUNDS menuselect.makeopts

menuselect/menuselect --disable res_ari --disable res_ari_model menuselect.makeopts

make
make install