[Asterisk-Users] problem with cdr_odbc

Pablo Endres epablo at comvoz.com
Wed May 19 08:05:53 MST 2004


I pumped up the verbosity to freetds and found this:

pid: 30035:Received packet @ 11:02:14.897325
0000 aa 82 00 e9 03 00 00 01-0f 37 00 4c 00 69 00 6e |........ .7.L.i.n|
0010 00 65 00 20 00 31 00 3a-00 20 00 4c 00 65 00 6e |.e. .1.: . .L.e.n|
0020 00 67 00 74 00 68 00 20-00 6f 00 72 00 20 00 70 |.g.t.h.  .o.r. .p|
0030 00 72 00 65 00 63 00 69-00 73 00 69 00 6f 00 6e |.r.e.c.i .s.i.o.n|
0040 00 20 00 73 00 70 00 65-00 63 00 69 00 66 00 69 |. .s.p.e .c.i.f.i|
0050 00 63 00 61 00 74 00 69-00 6f 00 6e 00 20 00 30 |.c.a.t.i .o.n. .0|
0060 00 20 00 69 00 73 00 20-00 69 00 6e 00 76 00 61 |. .i.s.  .i.n.v.a|
0070 00 6c 00 69 00 64 00 2e-00 04 53 00 51 00 4c 00 |.l.i.d.. ..S.Q.L.|
0080 31 00 00 01 00 aa 54 00-89 00 00 00 02 0f 20 00 |1.....T. ...... .|
0090 4d 00 75 00 73 00 74 00-20 00 64 00 65 00 63 00 |M.u.s.t.  .d.e.c.|
00a0 6c 00 61 00 72 00 65 00-20 00 74 00 68 00 65 00 |l.a.r.e.  .t.h.e.|
00b0 20 00 76 00 61 00 72 00-69 00 61 00 62 00 6c 00 | .v.a.r. i.a.b.l.|
00c0 65 00 20 00 27 00 40 00-50 00 31 00 27 00 2e 00 |e. .'. at . P.1.'...|
00d0 04 53 00 51 00 4c 00 31-00 00 01 00 aa 6e 00 f4 |.S.Q.L.1 .....n..|
00e0 1f 00 00 01 10 23 00 53-00 74 00 61 00 74 00 65 |.....#.S .t.a.t.e|
00f0 00 6d 00 65 00 6e 00 74-00 28 00 73 00 29 00 20 |.m.e.n.t .(.s.). |
0100 00 63 00 6f 00 75 00 6c-00 64 00 20 00 6e 00 6f |.c.o.u.l .d. .n.o|
0110 00 74 00 20 00 62 00 65-00 20 00 70 00 72 00 65 |.t. .b.e . .p.r.e|
0120 00 70 00 61 00 72 00 65-00 64 00 2e 00 04 53 00 |.p.a.r.e .d....S.|
0130 51 00 4c 00 31 00 0a 73-00 70 00 5f 00 70 00 72 |Q.L.1..s .p._.p.r|
0140 00 65 00 70 00 61 00 72-00 65 00 01 00 79 f4 1f |.e.p.a.r .e...y..|
0150 00 00 ac 09 00 00 01 38-00 00 00 26 04 00 fe 02 |.......8 ...&....|
0160 00 e0 00 00 00 00 00   -                        |.......|

I checked the code on cdr_odbc, but it seems to be setting the value in
the prepared statement.  

Any ideas on what could be wrong?

PD: working with unixODBC & freetds built manualy.  Got everthing
working with isql and perl-DBD-ODBC (compiled against the same
libraries.


On Tue, 2004-05-18 at 10:54, Pablo Endres wrote:
> I'm using freeTDS-0.61.2, also built from RPM.
> 
> Whats the deal with the RPMs? 
> Normally I build RPMS for  ALL my software, it's a lot easyer 
> to upgrade and maintain.  Isn't it a simple package of the build
> code?
> 
> I'll try installing manually to see how it works out.
> 
> 
> On Tue, 2004-05-18 at 10:42, brian wrote:
> > Don't install from RPM or even an RPM you built.  It's going to suffer the
> > same issues no matter what if you keep using an RPM.  Also what FreeTDS
> > version are you using?
> > 
> >   == Spawn extension (default, 999, 4) exited non-zero on 'SIP/10-6e46'
> >        > cdr_odbc: Query Successful!
> > 
> > I'm using it with MySQL and MyODBC without issues.  I wrote cdr_odbc.c using
> > unixODBC 2.2.7 I don't think much as changed since then and current run it
> > on 2.2.8 without any issues.  You need to test using isql to see if you can
> > even connect to the DSN.
> > 
> > bkw
> > 
> > > -----Original Message-----
> > > From: asterisk-users-admin at lists.digium.com [mailto:asterisk-users-
> > > admin at lists.digium.com] On Behalf Of Pablo Endres
> > > Sent: Tuesday, May 18, 2004 9:24 AM
> > > To: asterisk-users at lists.digium.com
> > > Subject: [Asterisk-Users] problem with cdr_odbc
> > >
> > > Hi,
> > >
> > > Has  anyone made a successfull instalation of cdr_odbc??
> > >
> > > I've install unixODBC-2.2.8 (made my own RPM) and then built the module.
> > > I'm trying to send the cdrs to a M$ SQL server.  The sql connection
> > > works because I can do any query via isql.
> > >
> > > When I do the calls I get the following output on the asterisk console:
> > >     -- Executing Hangup("SIP/test1-a5e1", "") in new stack
> > >   == Spawn extension (test, h, 1) exited non-zero on 'SIP/test1-a5e1'
> > >        > cdr_odbc: Connected to SQL1
> > >        > cdr_odbc: Error in Query -1
> > >        > cdr_odbc: Query FAILED Call not logged!
> > >        > cdr_odbc: Connected to SQL1
> > >        > cdr_odbc: Reconnecting to dsn SQL1
> > >        > cdr_odbc: Trying Query again!
> > >        > cdr_odbc: Error in Query -2
> > >        > cdr_odbc: Query FAILED Call not logged!
> > >
> > >
> > > --
> > > Pablo Endres <epablo at comvoz.com>
> > > ComVoz Comunications
> > >
> > > _______________________________________________
> > > Asterisk-Users mailing list
> > > Asterisk-Users at 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 mailing list
> > Asterisk-Users at 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
-- 
Pablo Endres <epablo at comvoz.com>
ComVoz Comunications




More information about the asterisk-users mailing list