Hi, thanks. I will wait for it then.
Bests, pierlu
On Fri, Apr 2, 2010 at 3:42 PM, Jan Willamowius <jan@xxxxxxxxxxxxxx> wrote:
Hi,
the register and unregister events will be available starting with GnuGk
2.3.2 (which is only available as a development version through the CVS
currently).
Regards,
Jan
--
pierlu wrote:
> I set up Gnugk 2.3.1 and set the gk.ini to write to a Mysql database on
> registration/unregistration of endpoints. I already used SQLAcct to store
> endpoint calls (mostly copying hte module form the manual tho), so i thought
> it would be easy to set up. But for some reasons it seem like it's not that
> easy.
>
> In gk.ini I entered the following lines (as you can see on SQLAccount i
> added the register and unregister events as well as I added the queries in
> the SQLAcct:
>
> ---------------gatekeeper.ini---------------------
>
> *[Gatekeeper::Acct]*
> SQLAcct=optional;start,stop,update,*register,unregister
> *FileAcct=sufficient;stop
>
> *[FileAcct]*
> DetailFile=c:\gk\calls.log
> StandardCDRFormat=0
> CDRString=%g|%n|%d|%c|%s|%u|%{gkip}|%{CallId}|%{ConfId}|%{setup-time}|%{connect-time}|%{disconnect-time}|%{caller-ip}|%{caller-port}|%{callee-ip}|%{callee-port}|%{src-info}|%{dest-info}|%{Calling-Station-Id}|%{Called-Station-Id}|%{Dialed-Number}
> Rotate=daily
> RotateTime=23:59
>
> *[SQLAcct]*
> Driver=MySQL
> Host=xx.xx.xx.xx:xxxx
> Database=db
> Username=user
> Password=password
> StartQuery= insert into cdr (gatekeeper_name, call_number, call_duration,
> disconnect_cause, acct_session_id, h323_id, gkip, CallId, ConfId,
> setup_time, connect_time, disconnect_time, caller_ip, caller_port,
> callee_ip, callee_port, src_info, dest_info, Calling_Station_Id,
> Called_Station_Id, Dialed_Number) values ('%g', '%n', %d, %c, '%s', '%u',
> '%{gkip}', '%{CallId}', '%{ConfId}', '%{setup-time}', NULL, NULL,
> '%{caller-ip}', '%{caller-port}', '%{callee-ip}', '%{callee-port}',
> '%{src-info}', '%{dest-info}', '%{Calling-Station-Id}',
> '%{Called-Station-Id}', '%{Dialed-Number}')
> StartQueryAlt= insert into cdr (gatekeeper_name, call_number, call_duration,
> disconnect_cause, acct_session_id, h323_id, gkip, CallId, ConfID,
> setup_time, connect_time, disconnect_time, caller_ip, caller_port,
> callee_ip, callee_port, src_info, dest_info, Calling_Station_Id,
> Called_Station_Id, Dialed_Number) values ('%g', '%n', %d, %c, '%s', '%u',
> '%{gkip}', '%{CallId}', '%{ConfID}', '%{setup-time}', '%{connect-time}',
> '%{disconnect-time}', '%{caller-ip}', '%{caller-port}', '%{callee-ip}',
> '%{callee-port}', '%{src-info}', '%{dest-info}', '%{Calling-Station-Id}',
> '%{Called-Station-Id}', '%{Dialed-Number}')
> UpdateQuery= update cdr set call_duration=%d,
> connect_time='%{connect-time}' where gatekeeper_name='%g' and
> acct_session_id='%s'
> StopQuery= update cdr set call_duration=%d, connect_time='%{connect-time}',
> disconnect_cause=%c, disconnect_time='%{disconnect-time}' where
> gatekeeper_name='%g' and acct_session_id='%s'
> StopQueryAlt= insert into cdr (gatekeeper_name, call_number, call_duration,
> disconnect_cause, acct_session_id, h323_id, gkip, CallId, ConfID,
> setup_time, connect_time, disconnect_time, caller_ip, caller_port,
> callee_ip, callee_port, src_info, dest_info, Calling_Station_Id,
> Called_Station_Id, Dialed_Number) values ('%g STOP Alt', '%n', %d, %c, '%s',
> '%u', '%{gkip}', '%{CallId}', '%{ConfID}', '%{setup-time}',
> '%{connect-time}', '%{disconnect-time}', '%{caller-ip}', '%{caller-port}',
> '%{callee-ip}', '%{callee-port}', '%{src-info}', '%{dest-info}',
> '%{Calling-Station-Id}', '%{Called-Station-Id}', '%{Dialed-Number}')
> *RegisterQuery*= insert into registrazioni(H323ID, registrato, giorno, ora)
> VALUES ('%u', 'y', NOW(), NOW())
> *UnregisterQuery*= insert into registrazioni(H323ID, registrato, giorno,
> ora) VALUES ('%u', 'n', NOW(), NOW())
> TimestampFormat=MySQL
>
> --------------------[end gatekeeper.ini]--------------------
>
> BUT when Gnugk starts the -ttttt output reads like follows and it seems to
> skip the Register and Unregister query lines
>
> ----------------------
> 2010/04/02 14:51:00.171 1 gkacct.cxx(202) *GKACCT Created module
> SQLAcct with event mask 7
> *2010/04/02 14:51:00.171 4 sqlacct.cxx(144) *GKACCT SQLAcct start query
> *: insert into cdr (gatekeeper_name, call_number, call_duration,
> disconnect_cause, acct_session_id, h323_id, gkip, CallId, ConfId,
> setup_time, connect_time, disconnect_time, caller_ip, caller_port,
> callee_ip, callee_port, src_info, dest_info, Calling_Station_Id,
> Called_Station_Id, Dialed_Number) values ('%g', '%n', %d, %c, '%s', '%u',
> '%{gkip}', '%{CallId}', '%{ConfId}', '%{setup-time}', NULL, NULL,
> '%{caller-ip}', '%{caller-port}', '%{callee-ip}', '%{callee-port}',
> '%{src-info}', '%{dest-info}', '%{Calling-Station-Id}',
> '%{Called-Station-Id}', '%{Dialed-Number}')
> 2010/04/02 14:51:00.171 4 sqlacct.cxx(148) *GKACCT SQLAcct alternative
> start query*: insert into cdr (gatekeeper_name, call_number, call_duration,
> disconnect_cause, acct_session_id, h323_id, gkip, CallId, ConfID,
> setup_time, connect_time, disconnect_time, caller_ip, caller_port,
> callee_ip, callee_port, src_info, dest_info, Calling_Station_Id,
> Called_Station_Id, Dialed_Number) values ('%g', '%n', %d, %c, '%s', '%u',
> '%{gkip}', '%{CallId}', '%{ConfID}', '%{setup-time}', '%{connect-time}',
> '%{disconnect-time}', '%{caller-ip}', '%{caller-port}', '%{callee-ip}',
> '%{callee-port}', '%{src-info}', '%{dest-info}', '%{Calling-Station-Id}',
> '%{Called-Station-Id}', '%{Dialed-Number}')
> 2010/04/02 14:51:00.187 4 sqlacct.cxx(160) *GKACCT SQLAcct update query
> *: update cdr set call_duration=%d, connect_time='%{connect-time}' where
> gatekeeper_name='%g' and acct_session_id='%s'
> 2010/04/02 14:51:00.187 4 sqlacct.cxx(172) *GKACCT SQLAcct stop
> query:*update cdr set call_duration=%d,
> connect_time='%{connect-time}',
> disconnect_cause=%c, disconnect_time='%{disconnect-time}' where
> gatekeeper_name='%g' and acct_session_id='%s'
> 2010/04/02 14:51:00.187 4 sqlacct.cxx(177) *GKACCT SQLAcct alternative
> stop query:* insert into cdr (gatekeeper_name, call_number, call_duration,
> disconnect_cause, acct_session_id, h323_id, gkip, CallId, ConfID,
> setup_time, connect_time, disconnect_time, caller_ip, caller_port,
> callee_ip, callee_port, src_info, dest_info, Calling_Station_Id,
> Called_Station_Id, Dialed_Number) values ('%g STOP Alt', '%n', %d, %c, '%s',
> '%u', '%{gkip}', '%{CallId}', '%{ConfID}', '%{setup-time}',
> '%{connect-time}', '%{disconnect-time}', '%{caller-ip}', '%{caller-port}',
> '%{callee-ip}', '%{callee-port}', '%{src-info}', '%{dest-info}',
> '%{Calling-Station-Id}', '%{Called-Station-Id}', '%{Dialed-Number}')
> 2010/04/02 14:51:00.203 5 gksql_mysql.cxx(373) SQLAcct MySQL connection to
> user@xxxxxxxxxxxxxxx[db] *established successfully*
> 2010/04/02 14:51:00.203 3 gksql.cxx(169) SQLAcct Database connection
> pool created: user@xxxxxxxxxxxxxxx[db]
> 2010/04/02 14:51:00.203 5 gksql.cxx(173) SQLAcct Connection pool: 1
> SQL connections created, 0 failed
> 2010/04/02 14:51:00.203 1 gkacct.cxx(202) GKACCT Created module
> FileAcct with event mask 2
> 2010/04/02 14:51:00.218 2 gkacct.cxx(626) GKACCT FileAcct CDR file:
> c:\gk\calls.log
> 2010/04/02 14:51:00.218 5 gkacct.cxx(667) GKACCT FileAcct daily
> rotation enabled (first rotation sheduled at Fri, 02 Apr 2010 23:59:00 +0200
> 2010/04/02 14:51:00.218 2 Routing.cxx(751) VQueue (CTI) Virtual queues
> disabled - no virtual queues configured
> 2010/04/02 14:51:00.218 2 singleton.cxx(25) Create instance:
> Routing::Analyzer(8)
> 2010/04/02 14:51:00.218 2 gkacct.cxx(1047) GKACCT Successfully logged
> event 8
> 2010/04/02 14:51:00.218 5 job.cxx(364) JOB Worker threads: 9 total
> - 9 busy, 0 idle
> 2010/04/02 14:51:00.218 5 job.cxx(170) JOB Worker 248 started
> 2010/04/02 14:51:00.218 5 job.cxx(190) JOB Starting Job
> HouseKeeping at Worker thread 248
>
> --------------------------------
>
>
> When i start Gnugk I start it like this on a Windows 2003 machine
>
> C:\gk>gnugk -ttttt -o c:\gklog.txt -c c:\gk\gatekeeper.ini
> GNU Gatekeeper with ID 'GNUgk2' started
> Gatekeeper(GNU) Version(2.3.1)
> Ext(pthreads=0,radius=1,mysql=1,pgsql=0,firebird=0,odbc=1,sqlite=0,large_fdset=0,crypto/ssl=1,h46018=1,h46023=1)
> Build(Nov 26 2009, 14:05:00) Sys(Server 2003 i586 (Model=3 Stepping=4)
> v5.2.3790)
>
>
> What's wrong with my configuration?
>
> thanks for any help,
>
> pierlu
Jan Willamowius, jan@xxxxxxxxxxxxxx, http://www.gnugk.org/
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________________
Posting: mailto:Openh323gk-users@xxxxxxxxxxxxxxxxxxxxx
Archive: http://sourceforge.net/mailarchive/forum.php?forum_name=openh323gk-users
Unsubscribe: http://lists.sourceforge.net/lists/listinfo/openh323gk-users
Homepage: http://www.gnugk.org/
------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev
_______________________________________________________ Posting: mailto:Openh323gk-users@xxxxxxxxxxxxxxxxxxxxx Archive: http://sourceforge.net/mailarchive/forum.php?forum_name=openh323gk-users Unsubscribe: http://lists.sourceforge.net/lists/listinfo/openh323gk-users Homepage: http://www.gnugk.org/