All Posts By

solo@astercc.org

Install asterBilling on your server

By | asterBilling | 53 Comments
  1. Download and unzip the source
  2. cd /var/www/html
    wget https://voxel.dl.sourceforge.net/sourceforge/astercc/astercc-0.09beta.zip
    unzip astercc-0.09beta.zip
    mv astercc-0.09beta astercc

  3. Create the directories and move astercc daemon scripts:
  4. mkdir -p /opt/asterisk/scripts/astercc/
    mv /var/www/html/astercc/daemons/* /opt/asterisk/scripts/astercc/
    chmod +x /opt/asterisk/scripts/astercc/astercc
    chmod +x /opt/asterisk/scripts/astercc/asterrc
    chmod +x /opt/asterisk/scripts/astercc/asterccd

  5. Create the MySQL database and table, asterCC need mysql 4.1 or above
  6. mysqladmin -uyourmysqluser -pyourmysqlpasswd create astercc
    mysql -uyourmysqluser -pyourmysqlpasswd astercc <sql/astercc.sql

    Note: here we create the database named astercc, you could use whatever db name you want use your configration to replace yourmysqluser and yourmysqlpasswd

  7. Update /etc/asterisk/manager.conf to enable Manager connections
  8. Note: asterisk and astercc could be on different server

    Add something like this to the manager.conf file:

    [general] enabled = yes
    port = 5038
    bindaddr = 0.0.0.0
    ;displayconnects = yes

    ;the following line could be changed by yourself
    [eventsdaemon] secret = myeventsdaemon
    read = system,call,log,verbose,command,agent,user
    write = system,call,log,verbose,command,agent,user
    deny=0.0.0.0/0.0.0.0
    ; only allow local access, if you want to run astercrm on another server
    ; use your astercrm ip to replace 127.0.0.1 or add a new line
    permit=127.0.0.1/255.255.255.0

  9. Modify /var/www/html/astercc/astercc.conf.php and /opt/asterisk/scripts/astercc/astercc.conf to fit your configration
  10. Start astercc daemons
  11. /opt/asterisk/scripts/astercc/asterccd start
    Note: If your astercc scripts in other directory,
    you need to modify script path in CONFIGURATION SECTION of asterccd and asterccdaemon
    to fit your script path (modify path of astercc,asterrc and asterccdaemon in asterccd;
    modify path of asterccd and monitor log in asterccdaemon).

    Start astercc daemons when system startup:
    Note: This option can only fit to redhat-release system.
    If you want astercc daemons to start automatically when you boot your
    machine, you need to :

    cp /opt/asterisk/scripts/astercc/asterccd /etc/rc.d/init.d
    chmod 755 /etc/rc.d/init.d/asterccd
    chkconfig –add asterccd

    Advice: Configure your astercc restart once everyday, it’s not necessary, but it’s good for your astercc operation.
    for example: you want to restart astercc at 0′clock everyday,just do the following line as root.
    crontab -e
    add a line:
    0 0 * * * /etc/rc.d/init.d/asterccd restart
    end of this file, the first ‘0’ figures minutes and the second ‘0’ figures hours.

  12. Set folder access
  13. chmod 777 /var/www/html/astercc/upload

  14. Testing: browse to https://localhost/astercc
  15. browse to https://localhost/astercc

    or https://YOUR-WEB-SERVER-ADDRESS/astercc

    login with admin/admin

  16. Set your first booth
    • go Reseller and add a reseller
    • go Group add a group belong to the reseller
    • go Clid add some clid for this group, then the account in asterisk with the clid would be billing as a user in this group
    • go Account add a account, usertype could be groupadmin and belongs to the group you just added
    • go Rate to Customer and add some rate for the group, if you dont select reseller or group, the rate could be the default rate all all resellers/groups
    • login as groupadmin account, then you should see some box as the attachments.
    • try make a call using the ip phone with the clid, you could see the calling and billing message in the box

simple asterCRM installation guide for asterisk

By | asterCRM | 32 Comments

for asterCRM 0.047beta

    1. Download asterCRM package from sf.net, unzip it and put all files/folders to your WEBroot folder

cd /usr/src wget https://nchc.dl.sourceforge.net/sourceforge/asterisk-crm/astercrm-0.047beta.zip unzip astercrm-0.047beta.zip mv ./astercrm-0.047beta /var/www/html/astercrm It is highly advised that the whole eventsdaemon directory be moved to a more secure location like /opt and out of the WEB root directory (in step 2)

    1. Create the directories and move eventsdaemon scripts:

in 0.047 beta, there’re several daemon scripts in the package:

  • astercc, asterccd, asterccdaemon are for users who would use astercc to catch asterisk call records
  • eventdog.sh, eventsdaemon.pl are for users who would use eventsdaemon to catch asterisk AMI events

Users could choose either method to use,  dialer.pl is for scheduler calls, but it’s not fully tested in 0.047beta yet mkdir -p /opt/asterisk/scripts/eventsdaemon mv /var/www/html/astercrm/eventsdaemon/* /opt/asterisk/scripts/eventsdaemon chmod +x /opt/asterisk/scripts/eventsdaemon/eventsdaemon.pl chmod +x /opt/asterisk/scripts/eventsdaemon/eventdog.sh chmod +x /opt/asterisk/scripts/eventsdaemon/astercc chmod +x /opt/asterisk/scripts/eventsdaemon/asterccd chmod +x /opt/asterisk/scripts/eventsdaemon/asterccdaemon

    1. Create the MySQL database and tables, asterCRM requires mysql 4.1 or above

mysqladmin -uyourmysqluser -pyourmysqlpasswd create astercrm mysql -uyourmysqluser -pyourmysqlpasswd astercrm </var/www/html/astercrm/sql/astercrm.sql here we create the database named astercrm, you could use whatever db name you want use your configration to replace “yourmysqluser” and “yourmysqlpasswd”

    1. Update /etc/asterisk/manager.conf to enable Manager connections
[general] enabled = yes port = 5038 bindaddr = 0.0.0.0 ;displayconnects = yes ;the following line could be changed by yourself [asterccdaemon] secret = myasterccdaemon read = system,call,log,verbose,command,agent,user write = system,call,log,verbose,command,agent,user deny=0.0.0.0/0.0.0.0 ; only allow local access, if you want to run asterCRM on another server ; use your asterCRM ip to replace 127.0.0.1 or add a new line permit=127.0.0.1/255.255.255.0

    1. Modify astercrm.conf.php to fit your configuration

Mainly first you need set database connectoin parameters in section [database] so that you can login, then u can set other parameters via web pages.

    1. Start Asterisk and daemons you use

There are two daemon modes you can choose, eventsdaemon mode or astercc mode.

  • using eventsdaemon.pl (eventtype = event in astercrm.conf.php)

open eventsdaemon.pl using some editor, then modify for database setting and AMI setting. try start the eventsdaemon.pl using /opt/asterisk/scripts/eventsdaemon/eventsdaemon.pl if you could read: “Message: Authentication accepted” congratulations, your eventsdaemon works well use ctrl + c to exit or else, please check your database/AMI configration in eventsdaemon.pl then start eventsdaemon as a daemon: /opt/asterisk/scripts/eventsdaemon/eventsdaemon.pl -d At some point, for better performance, it may be desirable to delete old events from database, you can check eventsdaemon.pl for parameter “log_life”, which is for such purpose. Also we provide a “watch dog”, it would help you restart eventsdaemon when it’s down, like asterisk restart. Add this line to your start-up file /opt/asterisk/scripts/eventsdaemon/eventdog.sh so that everytime your server start, eventsdaemon would be loaded

  • using astercc (eventtype = curcdr in astercrm.conf.php)

modify /opt/asterisk/scripts/eventsdaemon/astercc.conf to fit your configuration try start astercc using /opt/asterisk/scripts/eventsdaemon/astercc if you could read like following line: “Connecting to mysql database on 127.0.0.1: Database connection successful. Connecting to asterisk on 127.0.0.1 port 5038: Asterisk socket connection successful. Check asterisk username & secret: Success Monitor Start: …(some log message)…” congratulations, your astercc works well then use ctrl + c to exit or else, please check your database/AMI configration in astercc.conf then start astercc as a daemon: /opt/asterisk/scripts/eventsdaemon/astercc -d Start up astercc daemons when system startup: Note: This option can only fit to redhat-release system. If you want astercc daemons to start automatically when you boot your machine, you need to : cp /opt/asterisk/scripts/eventsdaemon/asterccd /etc/rc.d/init.d chmod 755 /etc/rc.d/init.d/asterccd chkconfig –add asterccd Advice: Configure your astercc restart once everyday, it’s not necessary, but it ‘s good for your astercc operation. for example: you want to restart astercc at 0’clock everyday,just do the following line as root. crontab -e add a line: 0 0 * * * /etc/rc.d/init.d/asterccd restart end of this file, the first “0” figures minutes and the second “0” figures hours. a asterCC installation guid could be found here.

    1. Set file&folder access

set upload foler permission, so that you can upload your csv/excel files then import data chmod 777 /var/www/html/astercrm/upload set configratoin file permission, so that you can modify asterCRM perference via web chmod 777 /var/www/html/astercrm/astercrm.conf.php

    1. Test

open your browse, then enter this address https://localhost/astercrm or https://YOUR-WEB-SERVER-ADDRESS/astercrm login with admin/admin

A Sonicwell Product · Also: CXMind AI · WCC Contact Center