Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Help Asterisk!!!

  • 25-11-2007 3:45pm
    #1
    Registered Users, Registered Users 2 Posts: 9


    Hi
    I was wondering if anybody could help me with asterisk. I have only been using linux for two months - intalled Ubuntu 7.04 (the first disk) and I am trying to install asterisk. It is for my college project to have two machines connected using crossover and capture a few voip packets. I downloaded Asterix but came up with errors - think I need to get openssl and bison and a few others - like I said I have only been using Linux for a few months and hate to say it but don't even know how to get those packages or install them- so used to windows. If any body could offer me any pointers in this regard would really appreciate it as I have hit a blank wall at the moment and my first project synopsis is due before christmas
    -


Comments

  • Registered Users, Registered Users 2 Posts: 3,568 ✭✭✭ethernet


    I can't claim to have used VoIP much at all so can't help you much on that front :)

    I suggest you download the latest version of Ubuntu, 7.10 [code-name "Gutsy"].

    How are you installing the software you need? Use the Synaptic Package Manager to install all software. Only install by source if you have to, i.e. if the package isn't in the repositories set up for your machine.


  • Closed Accounts Posts: 1,637 ✭✭✭joePC


    Heres a run down on how to install asterisk on,

    Ubuntu

    Debian

    Red Hat / CentOS


  • Closed Accounts Posts: 1,637 ✭✭✭joePC


    Whats the aim of the project - You want to trunk 2x asterisk servers and have calls going to and from each other?

    Why does it have to be a cross over cable, use a small switch and connect up a couple of IP phones.


  • Registered Users, Registered Users 2 Posts: 9 black1e


    Thanks for all the replies, the project is an intro to VOIP and besides the research the practicle side is to get a voip package talking in a server/ client role and capture some packets and look at them using wireshark. Basically if I can get asterisk on one machine to call another machine and capture some packets. I wanted to use skype and windows but the instructor said that woudl be too easy. I had a laptop and a desktop - so I thought that this would be the best /cheapest implementation
    H


  • Registered Users, Registered Users 2 Posts: 9 black1e


    All I want to be able to do is PC to PC calls - is this easy to configure and can it be done with asterisk. Does it use IP or another naming configuration to identify PCs? Yep think I am in over my head


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 1,391 ✭✭✭fatherdougalmag


    If you just need to capture some SIP traffic, why don't you sign up to something like freespeech.ie, get a SIP client for Linux and capture your traffic that way instead of going through the rigours of setting up a complete Asterisk environment?


  • Closed Accounts Posts: 1,637 ✭✭✭joePC


    Its more fun - setup your asterisk server with FreePBX this is quite simply to accomplish, I wrote this script a while ago to to install asterisk + freePBX you should be able to modify for the latest version, let me know if you have any issues.
    #UPDATED 03-12-06
    #
    #How to Install Production Ready Asterisk and FreePBX on CentOS 4
    #==========================================
    #Total Install Size 1.2GB
    #CentOS 4 installation:
    #You will need the Centos 4 "Server Edition"
    #I used graphical install mode
    #Disable the SELINUX and Firewall 
    #Install the "minimal" package (it's at the bottom of the package selection)
    #
    #This guide is now executable!!!!   
    #
    #run "yum -y update && reboot" prior to executing this script!
    #execute this script by entering "sh guide.txt" at the linux prompt
    
    #-----------------------------------------------------------------------------------
    
    clear
    
    yum -y install gcc libxml2-devel libtiff-devel mysql-server php-gd php-mysql kernel-devel bison ncurses-devel audiofile-devel subversion libogg-devel openssl-devel tftp-server php-mbstring ntp
    
    rpm -ivh http://www.asteriskprojects.com/lame-3.96.1-2.2.el4.rf.i386.rpm
    
    #------------------------------------------------------------------------------------
    
    cd /usr/src
    
    wget http://kent.dl.sourceforge.net/sourceforge/amportal/freepbx-2.2.0rc1.tar.gz
    
    tar -zxvf freepbx-2.2.0rc1.tar.gz
    
    mv freepbx-2.2.0rc1 freepbx
    
    rm -vf freepbx-2.2.0rc1.tar.gz
    
    #--------------------------------------------------------------------------------------
    
    wget http://ftp.digium.com/pub/asterisk/releases/asterisk-1.2.13.tar.gz
    
    tar -zxvf asterisk-1.2.13.tar.gz
    
    mv asterisk-1.2.13 asterisk
    
    rm -vf asterisk-1.2.13.tar.gz
    
    wget http://ftp.digium.com/pub/zaptel/releases/zaptel-1.2.11.tar.gz
    
    tar -zxvf zaptel-1.2.11.tar.gz
    
    mv zaptel-1.2.11 zaptel
    
    rm -vf zaptel-1.2.11.tar.gz
    
    wget http://ftp.digium.com/pub/libpri/releases/libpri-1.2.4.tar.gz 
    
    tar -zxvf libpri-1.2.4.tar.gz 
    
    mv libpri-1.2.4 libpri
    
    rm -vf libpri-1.2.4.tar.gz 
    
    wget http://ftp.digium.com/pub/asterisk/releases/asterisk-addons-1.2.5.tar.gz 
    
    tar -zxvf asterisk-addons-1.2.5.tar.gz 
    
    mv asterisk-addons-1.2.5 asterisk-addons
    
    rm -vf asterisk-addons-1.2.5.tar.gz 
    
    wget http://ftp.digium.com/pub/asterisk/releases/asterisk-sounds-1.2.1.tar.gz 
    
    tar -zxvf asterisk-sounds-1.2.1.tar.gz 
    
    mv asterisk-sounds-1.2.1 asterisk-sounds
    
    rm -vf asterisk-sounds-1.2.1.tar.gz 
    
    #-------------------------------------------------------------------------------------------
    
    cd /usr/src/zaptel
    
    mv ztdummy.c ztdummy.c.orig 
    
    sed "s/if 0/if 1/" < ztdummy.c.orig > ztdummy.c
    
    cd /usr/src/kernels/`uname -r`-`uname -m`/include/linux/ 
    
    mv spinlock.h spinlock.h.orig 
    
    sed "s/rw_lock_t/rwlock_t/" < spinlock.h.orig > spinlock.h 
    
    cd /usr/src/zaptel
    
    make linux26 
    
    make install 
    
    make config
    
    cd /etc/sysconfig
    
    mv -vf zaptel zaptel.old
    
    touch zaptel
    
    echo "TELEPHONY=yes" >> /etc/sysconfig/zaptel
    
    echo "#DEBUG=yes" >> /etc/sysconfig/zaptel
    
    echo 'MODULES="$MODULES ztdummy"' >> /etc/sysconfig/zaptel
    
    modprobe zaptel 
    
    modprobe ztdummy
    
    echo "modprobe ztdummy" >> /etc/rc.d/rc.local
    
    #-----------------------------------------------------------------------------------------------
    
    cd /usr/src/libpri
    
    make install
    
    #-----------------------------------------------------------------------------------------------
    
    cd /usr/src/asterisk
    
    mkdir /var/run/asterisk
    
    make install
    
    make config
    
    #-------------------------------------------------------------------------------------------------
    
    useradd -c "Asterisk PBX" -d /var/lib/asterisk asterisk
    
    chown asterisk /var/lib/php/session/
    
    sed -i "s/User apache/User asterisk/" /etc/httpd/conf/httpd.conf
    
    sed -i "s/Group apache/Group asterisk/" /etc/httpd/conf/httpd.conf
    
    sed -i "s/AllowOverride None/AllowOverride All/" /etc/httpd/conf/httpd.conf
    
    sed -i "s/disable=yes/disable=no/" /etc/xinetd.d/tftp
    
    #---------------------------------------------------------------------------------------------------
    
    /etc/init.d/mysqld start
    
    cd /usr/src/freepbx
    
    mysqladmin create asterisk
    
    mysqladmin create asteriskcdrdb
    
    mysql asterisk < SQL/newinstall.sql
    
    mysql asteriskcdrdb < SQL/cdr_mysql_table.sql
    
    mysql -vv -e "GRANT ALL PRIVILEGES ON asteriskcdrdb.* TO asteriskuser@localhost IDENTIFIED BY 'amp109'"
    
    mysql -vv -e "GRANT ALL PRIVILEGES ON asterisk.* TO asteriskuser@localhost IDENTIFIED BY 'amp109'"
    
    mysql -vv -e "flush privileges"
    
    mysqladmin -u root password 'passw0rd'
    
    #--------------------------------------------------------------------------------------------------------
    
    cd /usr/src/asterisk-addons
    
    cp Makefile Makefile.orig
    
    sed -i 's/SOURCE/SOURCE -DMYSQL_LOGUNIQUEID/' Makefile
    
    make && make install
    
    #---------------------------------------------------------------------------------------------------------
    
    cd /usr/src/asterisk-sounds
    
    make install
    
    #----------------------------------------------------------------------------------------------------------
    
    clear
    
    cd /usr/src/freepbx
    
    ./install_amp
    
    mkdir /var/lib/asterisk/sounds/custom
    
    chmod 775 /var/lib/asterisk/sounds/custom
    
    echo /usr/sbin/amportal start >> /etc/rc.local
    
    chkconfig httpd on
    
    chkconfig mysqld on
    
    chkconfig smartd off
    
    sed -i "s/Web_hostname=UNUSED/Web_hostname=/" /var/www/html/panel/op_server.cfg
    
    cd /etc/asterisk
    
    touch zapata.conf
    
    echo "[channels] " >> /etc/asterisk/zapata.conf
    
    echo "language=en " >> /etc/asterisk/zapata.conf
    
    echo "#include zapata_additional.conf " >> /etc/asterisk/zapata.conf
    
    chkconfig asterisk off
    
    chkconfig ntpd on
    
    #------------------------------------------------------------------------------------------------------------
    
    cd /var/www/html/admin/modules/
    
    wget http://www.asteriskprojects.com/maint-modules.zip
    
    unzip maint-modules.zip
    
    rm -vf maint-modules.zip
    
    cd /var/www/html/admin/modules/sysstatus
    
    sed -i "s|#!/usr/bin/perl|#!/usr/bin/perl -w|" status.pl
    
    chmod -v 775 status.pl
    
    cd /var/www/html/admin/modules/sysinfo/includes/os
    
    sed -i "s|$bufr = rfts( '/proc/scsi/scsi' );|$bufr = rfts( '/proc/scsi/scsi', 0, 4096, false );|" class.Linux.inc.php
    
    sed -i "s/upload_max_filesize = 2M/upload_max_filesize = 20M/" /etc/php.ini
    
    #------------------------------------------------------------------------------------------------------------
    
    #Rotate Log Files - You wont need this one anymore!!!!!!!!!
    
    cd /etc/logrotate.d/
    
    rm -vf asterisk
    
    wget http://asteriskprojects.com/asterisk.txt
    
    mv asterisk.txt asterisk
    
    #------------------------------------------------------------------------------------------------------------
    
    echo "All Done you can reboot the system now."
    


  • Registered Users, Registered Users 2 Posts: 9 black1e


    Appreciate all the advice guys and ye both seem to know a lot about linux. I am going to use the synaptic package manager to see if I can download the extra packages I need and hopefully that will sort out my installation worries. Can you let me know if it is possible to configrue asterisk to do PC to PC calls and if so how is it done? Two machines, one crossover cable, asterisk on both - set to a 10.1.1.1 and 10.1.1.2 with a headset. Can it be done ?


Advertisement