Re: [Asterisk-Users] OH323 channel in asterisk 1.2 ...Ouch ... error while writing audio data!

2005-11-27 Thread Rafael R. GV
/var/log/asterisk/full.1 output:

Nov 26 21:25:39 VERBOSE[14215] logger.c: [chan_oh323.so]Nov 26
21:25:39 WARNING[14215] loader.c: /usr/lib/asterisk/modules/chan_oh3
23.so: undefined symbol: _ZNK8PChannel7IsClassEPKc
Nov 26 21:25:39 WARNING[14215] loader.c: Loading module chan_oh323.so failed!

thanks
rafael


On 11/27/05, Adam Rybak [EMAIL PROTECTED] wrote:
You should have more info in full log messages, look to this file and sendoutput.AdamCytowanie Rafael R. GV [EMAIL PROTECTED]:
 Hello I am trying to compile oh323, oh323-0.6.5 wont compile with asterisk 1.2libraries, must be oh323-0.7.3, now I have compiled this version but when reload asterisk i have this error:
 [chan_oh323.so]Ouch ... error while writing audio data: : Broken pipe Any idea??? -- rrgv___
--Bandwidth and Colocation provided by Easynews.com --Asterisk-Users mailing listTo UNSUBSCRIBE or update options visit: 
http://lists.digium.com/mailman/listinfo/asterisk-users-- rrgv
___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] OH323 channel in asterisk 1.2 ...Ouch ... error while writing audio data!

2005-11-26 Thread Rafael R. GV
Hello 
I am trying to compile oh323, oh323-0.6.5 wont compile with asterisk
1.2 libraries, must be oh323-0.7.3, now I have compiled this version
but when reload asterisk i have this error:

[chan_oh323.so]Ouch ... error while writing audio data: : Broken pipe

Any idea???-- rrgv

___
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [Asterisk-Users] Help with 2billing please.

2005-11-25 Thread Rafael R. GV
Hi
edit your a2billing.conf and set debug level to 3, try again and send us your debug to see what happend.

rafael

On 11/25/05, Jose M. Ramirez [EMAIL PROTECTED] wrote:







Hi list, all. Please, I need help. Although 
already I installed a2billing, simply I cannot initiate its execution. 
Only appears this: 

-- Executing Answer(SIP/20-456d, ) in new 
stack
-- Executing Wait(SIP/20-456d, 2) in new 
stack
-- Executing DeadAGI(SIP/20-456d, a2billing.php) in new 
stack
-- Launched AGI Script 
/var/lib/asterisk/agi-bin/a2billing.php
-- AGI Script a2billing.php completed, returning 
0
-- Executing Wait(SIP/20-456d, 2) in new 
stack
-- Executing Hangup(SIP/20-456d, ) in new 
stack
== Spawn extension (from-internal, 1, 5) exited non-zero on 
'SIP/20-456d'
-- Executing Macro(SIP/20-456d, hangupcall) in new 
stack
-- Executing ResetCDR(SIP/20-456d, w) in new 
stack
-- Executing NoCDR(SIP/20-456d, ) in new 
stack
-- Executing Wait(SIP/20-456d, 5) in new 
stack
-- Executing Hangup(SIP/20-456d, ) in new 
stack
== Spawn extension (macro-hangupcall, s, 4) exited non-zero on 
'SIP/20-456d' in macro 'hangupcall'
== Spawn extension (from-internal, h, 1) exited non-zero on 
'SIP/20-456d'

and I cannot happen of there. That lack is it 
or that I am making incorrect?

Regards.

___--Bandwidth and Colocation sponsored by Easynews.com --
Asterisk-Users mailing listAsterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-usersTo UNSUBSCRIBE or update options visit:  
http://lists.digium.com/mailman/listinfo/asterisk-users-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] A2billing warnings with new Asterisk 1.2

2005-11-19 Thread Rafael R. GV
yes! it works very well now, I used this to re-compile php with pcntl:

./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
--with-mysql-sock=/tmp --with-pgsql=/usr/local/pgsql/ --with-zlib
--with-gd --enable-pcntl

thank you again Vahan

rafael
On 11/19/05, Vahan Yerkanian [EMAIL PROTECTED] wrote:
Rafael R. GV wrote: Hi I have this 3 warnings running a2billling with asterisk new version: a2billing.php|2: -- AGI Script Executing Application: (SetLanguage) Options: (en)
 Nov 18 12:06:19 WARNING[17440]: pbx.c:5435 pbx_builtin_setlanguage: SetLanguage is deprecated, please use Set(LANGUAGE()=language) instead. a2billing.php|2: UPDATE cc_card SET inuse=inuse+1 WHERE username='7938971'
This will change in the coming versions, I hope. Nov 18 12:06:29 WARNING[17440]: file.c:583 ast_readaudio_callback: Failed to write frame -- Playing 'prepaid-enter-dest' (language 'en')
 a2billing.php|2: RES DTMF : -1 a2billing.php|2: DESTINATION :: -1 a2billing.php|2: APPLY_RULES DESTINATION :: -1 Nov 18 12:06:29 WARNING[17440]: file.c:583 ast_readaudio_callback:
 Failed to write frame == Spawn extension (default, 19546387993, 2) exited non-zero on 'SIP/46836-08e03d40' The last two warnings appears every time I hungup and I this non-standard stop of the application causes that the card remains in
 'in-use'  0 status.   rafaelThese two indicate that one leg of call is non-existent (you hangup).The issue with 'in-use' goes away if you add PCNTL module to your phpcli version.
HTH,Vahan-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] Large Implementation

2005-11-18 Thread Rafael R. GV
http://www.voip-info.org/wiki/view/Asterisk+at+largeOn 11/17/05, Dario M. Colombo 
[EMAIL PROTECTED] wrote:Hi, somebody has implemented Asterisk in one organizacion with amount of
extenciones in the order of 20.000?Thanks.--Ing. Darío ColomboIngeniería de RedDepartamento Ingeniería de ComunicacionesAFIP
___--Bandwidth and Colocation sponsored by Easynews.com --Asterisk-Users mailing list
Asterisk-Users@lists.digium.comhttp://lists.digium.com/mailman/listinfo/asterisk-usersTo UNSUBSCRIBE or update options visit: 
http://lists.digium.com/mailman/listinfo/asterisk-users-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[Asterisk-Users] A2billing warnings with new Asterisk 1.2

2005-11-18 Thread Rafael R. GV
Hi
I have this 3 warnings running a2billling with asterisk new version:

 a2billing.php|2: 
 -- AGI Script Executing Application: (SetLanguage) Options: (en)
Nov 18 12:06:19 WARNING[17440]: pbx.c:5435 pbx_builtin_setlanguage:
SetLanguage is deprecated, please use Set(LANGUAGE()=language) instead.
 a2billing.php|2: UPDATE cc_card SET inuse=inuse+1 WHERE username='7938971'


Nov 18 12:06:29 WARNING[17440]: file.c:583 ast_readaudio_callback: Failed to write frame
 -- Playing 'prepaid-enter-dest' (language 'en')
 a2billing.php|2: RES DTMF : -1
 a2billing.php|2: DESTINATION :: -1
 a2billing.php|2: APPLY_RULES DESTINATION :: -1

Nov 18 12:06:29 WARNING[17440]: file.c:583 ast_readaudio_callback: Failed to write frame
 == Spawn extension (default, 19546387993, 2) exited non-zero on 'SIP/46836-08e03d40'
The last two warnings appears every time I hungup and I this
non-standard stop of the application causes that the card remains in
'in-use'  0 status.

rafael



___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] SER authenitification failure on ASTERISK

2005-11-16 Thread Rafael R. GV
try insecure=very (needed if we want to allow incoming SER calls to bypass authentication) and type=friend in [sip_proxy]

rafael

On 11/16/05, Juraj Varchol [EMAIL PROTECTED] wrote:
Hey guys,

I'm quite new in this SER/Asterisk environment and I'm having some
problems with authentification. Now i'm running SER and Asterisk on 2
boxes. It is working according to the scheme

SIP user -- SER Server  Asterisk -IAX users/PSTN/...


SIP calls are managed by SER Server and the rest is forwarded to
Asterisk for further processing. Also acording to dialing plan on
Asterisk, calls to SIP users are fwd to SER Server where are
redirected to their actual location.

Outgoing calls to SER Server are set up:

**extensions.conf**

exten = _77.,1,Dial(SIP/${EXTEN:[EMAIL PROTECTED],10)
exten = _77.,2,Hangup

**sip.conf** - where only for outgoing calls is set up context


[sip_proxy-out]
type=peer
username= asterisk_user-name_on_SER_Server
secret=asterisk_passwd_on_SER_Server
allow=all
host=SER_Server_IP or URL

 this way it does work even sometimes UA on SER shows as incoming

call from asterisk_user-name_on_SER_Server instead of callerID from

Asterisk ... but that would not be such a problem
... also is important to mention that
asterisk_user-name_on_SER_Server is registred on SER Server. (* if

there is better way how to deal with it i would b very glad to at
least get pointed the right direction ... ;))

THE PROBLEM comes the other way when SER users want to call
extension that is managed by ASTERISK.
I get error message in both cases that r described at the end. I'm
looking for some solution that would not include registering all SER
users on Asterisk or just omit authentification for all users coming
from SER_Server

Thanx in advance,

Juraj

**error message**

Nov 16 19:13:53
 NOTICE[9339]: chan_sip.c:7355 handle_request: Failed
to authenticate user sip:[EMAIL PROTECTED]:5060
;tag=93af6721-13c4-437b76e2-5f0d59d-2fee


*both options i tried but no luck
**
my setup on SER Server is

**ser.cfg**

if (uri=~^sip:[4-9]*@(IP_SER_SERVER|(proxy\.)?URL_SER_SERVER)) {

 rewritehostport(IP_ASTERISK_SERVER:5060);

 forward(uri:host, uri:port);

 break;
 };
...

**extensions.cong** --- i tried to redirect incoming call right away
to normal dialing plan...
[inpbx]
...
exten = 456,2,Dial(IAX2/User_1,15)
exten = 456,3,Voicemail([EMAIL PROTECTED])
...
exten = 456,6,Hangup
...
exten = 567,2,Dial(IAX2/User_2,15)

exten = 567,6,Hangup
...


OR modification 2 ... when we want to reach Asterisk Server must by

dialed prefix (for example 44_) + extensions by SIP user.


**extension.conf**
[default]
exten = _44.,1,Dial(SIP/${EXTEN:[EMAIL PROTECTED],15,rm) 
;here i strip
it from the extension
exten = _44.,2,Hangup

**sip.conf**

[sip_proxy]
type=friend
context=inpbx
;insecure=very
host=URL_SER_SERVER
;[EMAIL PROTECTED]

___--Bandwidth and Colocation sponsored by Easynews.com --
Asterisk-Users mailing listAsterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-usersTo UNSUBSCRIBE or update options visit:  
http://lists.digium.com/mailman/listinfo/asterisk-users-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[Asterisk-Users] A2billing questions

2005-11-15 Thread Rafael R. GV
Hello

1.- I am testing a2billing in a SER-Asterisk implementation but using
Mysql versions 4.1.15 and 5.0.15 because I want to integrate its cdr
with some tables from Ser database, the a2billing-mysql-schema does not
work properly in mysql-5 and in 4.1.15 works well but now I found this
issue related to cdr´s: I can see cdr records in 'call' table from
mysql console but they don't appear in a2bill web
interface, I only can see records of current date ...not sure if its a
mysql 4.x incompatibility so now I´ve installed postgres to verify, let
me now if someone has same problem.

2.- How can I generate invoices in PDF format?, a2billing has the
option but it doesnt work for me... do I have to install some aditional
software?

3.- I am using caller-id authentication for calls originated in SER but
I would like to know if its possible to auto create a card each time a
new callerID is found? I´ve already tried with cid_auto_create_card
options without success and I think it only works when there is no
caller-id present, please confirm that.


thanks
Rafael









___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] A2billing questions

2005-11-15 Thread Rafael R. GV

 issue related to cdr´s: I can see cdr records in 'call' table from mysql console but they don't appear in a2bill web interface, I only can see
 records of current date ...not sure if its a mysql 4.x incompatibility so now I´ve installed postgres to verify, let me now if someone has same problem.Make sure your cdr table is called 'calls' and not 'call'. This causes a
reserved word conflict in mysql 5.0.15, not sure about mysql4. Enablelogging in asterisk and raise the debug level from asterisk cli to seewhat's happening with the INSERT query.

Hi Vahan
at 1:25am I have just verified that all my cdr records disappear
from web interface despite that they are present in a2billing database,
its weird... same problem even using postgres or mysql 4 as I mentioned
previously, dont know why the web interface just shows cdr logs for
current date and hide yesterdays, any idea?


 2.- How can I generate invoices in PDF format?, a2billing has the option
 but it doesnt work for me... do I have to install some aditional software?Probably you're missing the tools for creating the pdf files. Pdflib etc.
yes, Google show me lots of php pdf libraries but just to be sure, which of those libraries Areski recomend for a2billing?

 3.- I am using caller-id authentication for calls originated in SER but
 I would like to know if its possible to auto create a card each time a new callerID is found? I´ve already tried with cid_auto_create_card options without success and I think it only works when there is no
 caller-id present, please confirm that.To my experience, this feature is currently not working. Mr. Areski isaware of the problem and promised to look into it.Regards,Vahan
thank you 

Rafael
-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] A2billing questions

2005-11-15 Thread Rafael R. GV
On 11/16/05, Rafael R. GV [EMAIL PROTECTED] wrote:

 issue related to cdr´s: I can see cdr records in 'call' table from mysql
 console but they don't appear in a2bill web interface, I only can see
 records of current date ...not sure if its a mysql 4.x incompatibility so now I´ve installed postgres to verify, let me now if someone has same problem.Make sure your cdr table is called 'calls' and not 'call'. This causes a
reserved word conflict in mysql 5.0.15, not sure about mysql4. Enablelogging in asterisk and raise the debug level from asterisk cli to seewhat's happening with the INSERT query.

Hi Vahan
at 1:25am I have just verified that all my cdr records disappear
from web interface despite that they are present in a2billing database,
its weird... same problem even using postgres or mysql 4 as I mentioned
previously, dont know why the web interface just shows cdr logs for
current date and hide yesterdays, any idea?

Nooo :-))) I was so ... , I forget to mark a date option and then press Search , sorry about that, it was always working :-)


 2.- How can I generate invoices in PDF format?, a2billing has the option
 but it doesnt work for me... do I have to install some aditional software?Probably you're missing the tools for creating the pdf files. Pdflib etc.
yes, Google show me lots of php pdf libraries but just to be sure, which of those libraries Areski recomend for a2billing?

 3.- I am using caller-id authentication for calls originated in SER but

 I would like to know if its possible to auto create a card each time a new callerID is found? I´ve already tried with cid_auto_create_card options without success and I think it only works when there is no
 caller-id present, please confirm that.To my experience, this feature is currently not working. Mr. Areski isaware of the problem and promised to look into it.Regards,Vahan

thank you 

Rafael
-- rrgv

-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] A2billing with Mysql-5.0.15

2005-11-13 Thread Rafael R. GV
thanks Vahan
you are right, I have changed 'call t1' for 'calls t1' in balance.php
and invoices.php files and then tried to create a new table named
'calls' but mysql 5 has changed syntax for 'TIMESTAMP DEFAULT' and this
is the error:

mysql CREATE TABLE calls (
 - id BIGINT NOT NULL AUTO_INCREMENT,
 - sessionid CHAR(40) NOT NULL,
 - uniqueid CHAR(30) NOT NULL,
 - username CHAR(40) NOT NULL,
 - nasipaddress CHAR(30),
 - starttime TIMESTAMP DEFAULT 'now()' NOT NULL,
 - stoptime TIMESTAMP,
 - sessiontime INT,
 - calledstation CHAR(30),
 - startdelay INT,
 - stopdelay INT,
 - terminatecause CHAR(20),
 - usertariff CHAR(20),
 - calledprovider CHAR(20),
 - calledcountry CHAR(30),
 - calledsub CHAR(20),
 - calledrate float,
 - sessionbill float,
 - destination CHAR(40),
 - id_tariffgroup INT,
 - id_tariffplan INT,
 - id_ratecard INT,
 - id_trunk INT,
 - sipiax INT DEFAULT '0',
 - src CHAR(40),
 - PRIMARY KEY (id)
 - );
ERROR 1067 (42000): Invalid default value for 'starttime'



I have to do some research in mysql 5 manual but I prefer to use PostgreSQL :-)

rafael

On 11/13/05, Vahan Yerkanian [EMAIL PROTECTED] wrote:
Rafael R. GV wrote: Hi I was using a2billing with mysql-4.1.12 and php-5.0.4 very successfully (thanks to areski for this great project and its invaluable assistance to solve some issues in my last installation...) now I´ve upgraded mysql
 to last release 5.0.15 and, without changes in 'mya2billing' database I am able to make calls, create and seecreated cards, etc,but I get this errors when invoke CDR´s in both admin or user interfase:
 *Database error:* Invalid SQL: SELECT t1.starttime, t1.src, t1.calledstation, t1.destination, t1.sessiontime, t1.username, t1.terminatecause, t1.sipiax, t1.calledrate, t1.sessionbill FROM call t1
 WHERE UNIX_TIMESTAMP(t1.starttime) = UNIX_TIMESTAMP('2005-11-12') ORDER BY t1.starttime DESC LIMIT 0,25MySQL 5.0.15 introduces stored functions and procedures that are invokedby 'call()'. A2Billing uses 'call' for the name of the cdr table. Find
all occurencies of 'call t1' or ' call ' in A2Billing's sql queries andreplace them to 'calls t1' and ' calls '. Don't forget to rename 'call'table to 'calls'. In short, latest A2Billing doesn't work on mysql
5.0.15 / PHP5 out of box.On the side note, MySQL doesn't support more than 1 entry with defaultvalue of DEFAULT now() NOT NULL in one table.regards,Vahan___
--Bandwidth and Colocation sponsored by Easynews.com --Asterisk-Users mailing listAsterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-usersTo UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] A2billing with Mysql-5.0.15

2005-11-13 Thread Rafael R. GV
Thank you
this is what I made to solve it:

1.- create table 'calls' using:  starttime TIMESTAMP DEFAULT
now() NOT NULL,  (it can be starttime TIMESTAMP DEFAULT
CURRENT_TIMESTAMP NOT NULL, too) :

CREATE TABLE calls (
 id BIGINT NOT NULL AUTO_INCREMENT,
 sessionid CHAR(40) NOT NULL,
 uniqueid CHAR(30) NOT NULL,
 username CHAR(40) NOT NULL,
 nasipaddress CHAR(30),
 starttime TIMESTAMP DEFAULT now() NOT NULL,
 stoptime TIMESTAMP,
 sessiontime INT,
 calledstation CHAR(30),
 startdelay INT,
 stopdelay INT,
 terminatecause CHAR(20),
 usertariff CHAR(20),
 calledprovider CHAR(20),
 calledcountry CHAR(30),
 calledsub CHAR(20),
 calledrate float,
 sessionbill float,
 destination CHAR(40),
 id_tariffgroup INT,
 id_tariffplan INT,
 id_ratecard INT,
 id_trunk INT,
 sipiax INT DEFAULT '0',
 src CHAR(40),
 PRIMARY KEY (id)
);


2.- Change value FG_TABLE_NAME=call t1 for FG_TABLE_NAME=calls t1 in following files:

A2Billing_UI/Public/call-log-customers.php
A2Billing_UI/Public/invoices.php
A2BCustomer_UI/balance.php
A2BCustomer_UI/invoices.php


3.- Change value INSERT INTO call for INSERT INTO calls in following files:

/var/lib/asterisk/agi-bin/libs_a2billing/db_php_lib/Class.RateEngine.php
/var/lib/asterisk/agi-bin/libs_a2billing/Class.A2Billing.php/wwwroot/A2BCustomer_UI/lib/Class.A2Billing.php
/wwwroot/A2Billing_UI/lib/Class.A2Billing.php

now it works...

rafael

PS: mysql-schema does not work properly in mysql 5.0.x because only one
timestamp with default now() in a table its allowed as you told me and
also I´ve found other issue related to auto_increment value:

ERROR 1064 (42000) at line 87: You have an error in your SQL syntax;
check the manual that corresponds to your MySQL server version for the
right syntax to use near 'call (
 id BIGINT NOT NULL AUTO_INCREMENT,
 sessionid CHAR(40) NOT NULL,
' at line 1




On 11/13/05, Vahan Yerkanian [EMAIL PROTECTED] wrote:
Rafael R. GV wrote: thanks Vahan you are right, I have changed 'call t1' for 'calls t1' in balance.php and invoices.php files and then tried to create a new table named 'calls' but mysql 5 has changed syntax for 'TIMESTAMP DEFAULT' and this
 is the error: - starttimeTIMESTAMP DEFAULT 'now()' NOT NULL,this should readstarttime TIMESTAMP DEFAULT now() NOT NULLnow() is a builtin MySQL function and doesn't need to be enclosed in 's.
Also, you can have only one timestamp with default now() in a table...HTH,Vahan-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[Asterisk-Users] A2billing with Mysql-5.0.15

2005-11-12 Thread Rafael R. GV
Hi 
I was using a2billing with mysql-4.1.12 and php-5.0.4 very successfully
(thanks to areski for this great project and its invaluable assistance
to solve some issues in my last installation...) now I´ve upgraded
mysql to last release 5.0.15 and, without changes in 'mya2billing'
database I am able to make calls, create and see created cards,
etc, but I get this errors when invoke CDR´s in both admin or
user interfase:

Database error: Invalid SQL: SELECT t1.starttime, t1.src,
t1.calledstation, t1.destination, t1.sessiontime, t1.username,
t1.terminatecause, t1.sipiax, t1.calledrate, t1.sessionbill FROM call
t1 WHERE UNIX_TIMESTAMP(t1.starttime) =
UNIX_TIMESTAMP('2005-11-12') ORDER BY t1.starttime DESC LIMIT 0,25

MySQL Error: 1064 (You have an error in your SQL syntax; check
the manual that corresponds to your MySQL server version for the right
syntax to use near 'call t1 WHERE UNIX_TIMESTAMP(t1.starttime) =
UNIX_TIMESTAMP('2005-11-12') ORDE' at line 1)

Database error: Invalid SQL: SELECT substring(t1.starttime,1,10)
AS day, sum(t1.sessiontime) AS calltime, sum(t1.sessionbill) AS cost,
count(*) as nbcall FROM call t1 WHERE UNIX_TIMESTAMP(t1.starttime)
= UNIX_TIMESTAMP('2005-11-12') GROUP BY
substring(t1.starttime,1,10) ORDER BY day

MySQL Error: 1064 (You have an error in your SQL syntax; check
the manual that corresponds to your MySQL server version for the right
syntax to use near 'call t1 WHERE UNIX_TIMESTAMP(t1.starttime) =
UNIX_TIMESTAMP('2005-11-12') GROU' at line 1)

Database error: Invalid SQL: SELECT count(*) FROM call t1 WHERE  UNIX_TIMESTAMP(t1.starttime) = UNIX_TIMESTAMP('2005-11-12')

MySQL Error: 1064 (You have an error in your SQL syntax; check
the manual that corresponds to your MySQL server version for the right
syntax to use near 'call t1 WHERE UNIX_TIMESTAMP(t1.starttime) =
UNIX_TIMESTAMP('2005-11-12')' at line 1)

Database error: next_record called with no query pending.

MySQL Error: 1064 (You have an error in your SQL syntax; check
the manual that corresponds to your MySQL server version for the right
syntax to use near 'call t1 WHERE UNIX_TIMESTAMP(t1.starttime) =
UNIX_TIMESTAMP('2005-11-12')' at line 1)

some advice?

rafael

-- rrgv
___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[Asterisk-Users] Can´t compile asterisk1.2bet a2

2005-11-04 Thread Rafael R. GV
Hi

...
..
.
gcc -shared -Xlinker -x -o chan_modem_bestdata.so chan_modem_bestdata.o
gcc -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes
-Wmissing-declarations -g -Iinclude -I../include -D_REENTRANT
-D_GNU_SOURCE -O6 -march=i686
-DZAPTEL_OPTIMIZATIONS
-fomit-frame-pointer -Wno-missing-prototypes
-Wno-missing-declarations -DZAPATA_PRI -DIAX_TRUNKING -DCRYPTO
-fPIC -c -o chan_agent.o chan_agent.c
chan_agent.c: In function `__login_exec':
chan_agent.c:1684: parse error before `char'
chan_agent.c:1701: `agent_goodbye' undeclared (first use in this function)
chan_agent.c:1701: (Each undeclared identifier is reported only once
chan_agent.c:1701: for each function it appears in.)
chan_agent.c:1708: `tmpoptions' undeclared (first use in this function)
chan_agent.c:1714: `update_cdr' undeclared (first use in this function)
chan_agent.c:1732: `context' undeclared (first use in this function)
chan_agent.c:1737: `play_announcement' undeclared (first use in this function)
chan_agent.c:1864: `filename' undeclared (first use in this function)
make[1]: *** [chan_agent.o] Error 1
make[1]: Leaving directory `/var/root/astbillFiles/asterisk/channels'
make: *** [subdirs] Error 1


any idea???

thanks 
Rafael


___
--Bandwidth and Colocation sponsored by Easynews.com --

Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [Asterisk-Users] ANNOUNCEMENT : A2Billing - AreskiCC V3 new release

2005-10-27 Thread Rafael R. GV
Hi
I´ve just installed a2billing using PHP Version 5.0.4, MySQL version
4.1.12 and Asterisk CVS-v1-0-06/27/05, verified database installation and can see webpage,
login, create cards, etc, but I cant hear anything when I call the extension:

extension.conf
; use 6608600 as access number to enter the calling card system
exten = 6608600,1,Answer
exten = 6608600,2,Wait,2
exten = 6608600,3,DeadAGI(a2billing.php|1)
exten = 6608600,4,Wait,2
exten = 6608600,5,Hangup

DEBUG:: (level2 in a2billing.conf)

*CLI 
*CLI 
*CLI 
*CLI 
 -- Executing Answer(SIP/264-ce26, ) in new stack
 -- Executing Wait(SIP/264-ce26, 2) in new stack
 -- Executing DeadAGI(SIP/264-ce26, a2billing.php|1) in new stack
 -- Launched AGI Script /var/lib/asterisk/agi-bin/a2billing.php
 a2billing.php|1: IDCONFIG : 1 
 a2billing.php|1: 
 a2billing.php|1: A2Billing AGI internal configuration:
 a2billing.php|1: Array
 a2billing.php|1: (
 a2billing.php|1: [debug] = 2
 a2billing.php|1: [logger_enable] = 1
 a2billing.php|1: [log_file] = /tmp/a2billing.log
 a2billing.php|1: [setlanguage_deprecate] = 1
 a2billing.php|1: [say_goodbye] = 
 a2billing.php|1: [play_menulanguage] = 
 a2billing.php|1: [force_language] = EN
 a2billing.php|1: [intro_prompt] = 
 a2billing.php|1: [len_cardnumber] = 10
 a2billing.php|1: [len_voucher] = 15
 a2billing.php|1: [min_credit_2call] = 0
 a2billing.php|1: [use_dnid] = 
 a2billing.php|1: [no_auth_dnid] = Array
 a2billing.php|1: (
 a2billing.php|1: [0] = 2400
 a2billing.php|1: [1] = 2300
 a2billing.php|1: )
 a2billing.php|1: 
 a2billing.php|1: [number_try] = 3
 a2billing.php|1: [say_balance_after_auth] = 1
 a2billing.php|1: [say_balance_after_call] = 
 a2billing.php|1: [say_timetocall] = 1
 a2billing.php|1: [cid_enable] = 1
 a2billing.php|1: [cid_askpincode_ifnot_callerid] = 1
 a2billing.php|1: [cid_auto_create_card] = 
 a2billing.php|1: [cid_auto_create_card_typepaid] = POSTPAY
 a2billing.php|1: [cid_auto_create_card_credit] = 0
 a2billing.php|1: [cid_auto_create_card_credit_limit] = 1000
 a2billing.php|1: [cid_auto_create_card_tariffgroup] = 6
 a2billing.php|1: [sip_iax_friends] = 
 a2billing.php|1: [sip_iax_pstn_direct_call_prefix] = 9
 a2billing.php|1: [sip_iax_pstn_direct_call] = 
 a2billing.php|1: [dialcommand_param] = |30|HL(%timeout%:61000:3)
 a2billing.php|1: [dialcommand_param_sipiax_friend] = |30|HL(360:61000:3)
 a2billing.php|1: [switchdialcommand] = 
 a2billing.php|1: [record_call] = 
 a2billing.php|1: [monitor_formatfile] = gsm
 a2billing.php|1: [base_currency] = usd
 a2billing.php|1: [agi_force_currency] = 
 a2billing.php|1: [currency_association] = Array
 a2billing.php|1: (
 a2billing.php|1: [0] = usd:prepaid-dollar
 a2billing.php|1: [1] = mxn:pesos
 a2billing.php|1: [2] = eur:euro
 a2billing.php|1: [3] = all:credit
 a2billing.php|1: )
 a2billing.php|1: 
 a2billing.php|1: [file_conf_enter_destination] = prepaid-enter-dest
 a2billing.php|1: [file_conf_enter_menulang] = prepaid-menulang2
 a2billing.php|1: [debugshell] = 0
 a2billing.php|1: [currency_association_internal] = Array
 a2billing.php|1: (
 a2billing.php|1: [usd] = prepaid-dollar
 a2billing.php|1: [mxn] = pesos
 a2billing.php|1: [eur] = euro
 a2billing.php|1: [all] = credit
 a2billing.php|1: )
 a2billing.php|1: 
 a2billing.php|1: )
 a2billing.php|1: 
 a2billing.php|1: AGI Request:
 a2billing.php|1: Array
 a2billing.php|1: (
 a2billing.php|1: [agi_request] = a2billing.php
 a2billing.php|1: [agi_channel] = SIP/264-ce26
 a2billing.php|1: [agi_language] = en
 a2billing.php|1: [agi_type] = SIP
 a2billing.php|1: [agi_uniqueid] = 1130449297.8
 a2billing.php|1: [agi_callerid] = Rafo
 a2billing.php|1: [agi_dnid] = 6608600
 a2billing.php|1: [agi_rdnis] = unknown
 a2billing.php|1: [agi_context] = internos
 a2billing.php|1: [agi_extension] = 6608600
 a2billing.php|1: [agi_priority] = 3
 a2billing.php|1: [agi_enhanced] = 0.0
 a2billing.php|1: [agi_accountcode] = 
 a2billing.php|1: )
 a2billing.php|1: 
 a2billing.php|1: 264 ; SIP/264-ce26 ; 1130449297.8 ; ; 6608600
 -- AGI Script a2billing.php completed, returning 0
 -- Executing Wait(SIP/264-ce26, 2) in new stack
 -- Executing Hangup(SIP/264-ce26, ) in new stack
 == Spawn extension (internos, 6608600, 5) exited non-zero on 'SIP/264-ce26'

*CLI 
*CLI 


what I am doing wrong?

thanks
rafael



,On 10/26/05, Areski K [EMAIL PROTECTED]
 wrote:
Dear Friends,Great day for the callingcard-lovers !!!I am pleased to release the version 
3.0 of AreskiCC !!!http://www.areski.net/a2billing/
http://www.voip-info.org/wiki/view/A2Billing
Little unexpected change, we got a new name... bit more serious A2BillingMany many features have been added, lot bugs solved and a bunch of goodenhancements made!The key newest features :

- Full MYSQL support- USE PHP-AGI LIB 2.14- CALLERID SUPPORT AUTHENTICATION- MUSICONHOLD CUSTOMIZATION BY DIALPREFIX- UPLOADING TOOLS TO CONFIGURE MUSICONHOLD- INVOICES PDF / HTML
- ADD NET REPORTING FROM ASTERISK-STAT# calls compare# monthly traffic# daily load- DEFAULT DIALING FOR RATECARD- FAILOVER