[Resolved Partially] Asterisk 1.4 and Google Talk

my first post! so please be nice to me :smile:

i started playing with asterisk less than a month ago, and have been spending a lot of free time on it, since * is really fascinating. and i’ve been a lurker on the forum and voip-info.org for 3 weeks now. i’ve successfully set up * at home. i use it for outbound/inbound PSTN, 1-800 access and conferencing using meetme.

i read that * 1.4 is compatible with Jabber/Jingle/GTalk and this is really something i’d love to use. so i have * 1.4 running now, and finally figured out how to get chan_gtalk.so loaded . i’ve configured jabber.conf and gtalk.conf as descibed on voip-info.org (voip-info.org/wiki/view/Asterisk+Google+Talk).

i see these messages on the CLI now, and i haven’t been able to get Asterisk-Gtalk connectivity to work.

*CLI>
[Nov 3 22:17:01] WARNING[30878]: res_jabber.c:1504 aji_recv_loop: JABBER: socket read error
*CLI>
JABBER: gtalk_account OUTGOING: <?xml version='1.0'?><stream:stream xmlns:stream=ā€˜http://etherx.jabber.org/streams’ xmlns=ā€˜jabber:client’ to=ā€˜gmail.com’ version=ā€˜1.0’>
*CLI>
JABBER: gtalk_account INCOMING: <?xml version="1.0" encoding="UTF-8"?><stream:stream from=ā€œgmail.comā€ id=ā€œD428120132AB91B7ā€ version=ā€œ1.0ā€ xmlns:stream=ā€œhttp://etherx.jabber.org/streamsā€ xmlns=ā€œjabber:clientā€>
[Nov 3 22:17:01] ERROR[30878]: res_jabber.c:482 aji_act_hook: gnuTLS not installed.
*CLI>
JABBER: gtalk_account INCOMING: stream:featuresX-GOOGLE-TOKEN</stream:features>
*CLI>

*CLI> jabber show connected
Jabber Users and their status:
User: myusername@gmail.com/Talk - Disconnected

Number of users: 1

*CLI> jabber test
Unable to find client ā€˜asterisk’!

these messages just keep appearing every 20s. gnuTLS is installed too, so the error message ā€œgnuTLS not installedā€ does not make sense to me. i checked config.log after running ./configure while building asterisk, and i can see that the check for ā€œgcc -lgnutlsā€ passed.

[root@linux asterisk]# rpm -qi gnutls
Name : gnutls Relocations: (not relocatable)
Version : 1.0.25 Vendor: Red Hat, Inc.
Release : 2.FC4 Build Date: Fri 10 Feb 2006 02:51:42 PM PST
Install Date: Tue 31 Oct 2006 03:21:16 PM PST Build Host: hs20-bc1-7.build.redhat.com
Group : System Environment/Libraries Source RPM: gnutls-1.0.25-2.FC4.src.rpm
Size : 664600 License: LGPL
Signature : DSA/SHA1, Fri 10 Feb 2006 05:10:47 PM PST, Key ID b44269d04f2a6fd2
Packager : Red Hat, Inc. http://bugzilla.redhat.com/bugzilla
URL : gnutls.org/
Summary : A TLS implementation.
Description :
The GNU TLS library implements TLS. Someone needs to fix this description.
[root@linux asterisk]#
[root@linux asterisk]# ls -la /usr/lib/gnutls
lrwxrwxrwx 1 root root 26 Oct 31 15:21 /usr/lib/libgnutls-extra.so.11 -> libgnutls-extra.so.11.1.25
-rwxr-xr-x 1 root root 163832 Feb 10 2006 /usr/lib/libgnutls-extra.so.11.1.25
lrwxrwxrwx 1 root root 28 Oct 31 15:21 /usr/lib/libgnutls-openssl.so.11 -> libgnutls-openssl.so.11.1.25
-rwxr-xr-x 1 root root 26756 Feb 10 2006 /usr/lib/libgnutls-openssl.so.11.1.25
lrwxrwxrwx 1 root root 20 Oct 31 15:22 /usr/lib/libgnutls.so -> libgnutls.so.11.1.25
lrwxrwxrwx 1 root root 20 Oct 31 15:21 /usr/lib/libgnutls.so.11 -> libgnutls.so.11.1.25
-rwxr-xr-x 1 root root 474012 Feb 10 2006 /usr/lib/libgnutls.so.11.1.25
[root@linux asterisk]#

any suggestions on what i could check next?

btw, i have been googling for asterisk 1.4 + google talk, but surprisingly, not many hits except for the voip-info.org link, and those on bugs.digium.com. i thought more people would be using it.

thanks, and asterisk rocks!

mani

i had installed iksemel (XML parsing library for Jabber) from an rpm, and i guess it had been compiled without GNUTLS being included. i wrote a test program calling a gnutls function call and it failed.

i downloaded iksemel source, compiled it and ran the same test program again, and this time it returned the int value from the function call that i was expecting.

now, ā€œjabber show connectedā€ shows the google talk account as connected, but i don’t see this buddy online on my other google talk buddy list.

i added an extension in extensions.conf that calls Gtalk/buddy, and as soon as i call this extension, asterisk terminates due to a segmentation fault. it didn’t seem like a core was dumped - i’m still looking for it.

I’ve been having a similar problem, either sending a call to a gtalk user, or sending a call from a gtalk user to a sip client. I’m not having the TLS issue, but the result seems to be the same as Asterisk exits as soon as a call is placed.

I’m inclined to believe this is a bug.

SIP => GTALK


sysmast01CLI> jabber debug
Jabber Debugging Enabled.
– Executing [8005551234@default:1] Dial(ā€œSIP/xxx.xxx.xxx.xxx-08a97020ā€, ā€œgtalk/gtalk_account/xxxxxxxx@gmail.comā€) in new stack
sysmast01
CLI> *** glibc detected *** /usr/sbin/asterisk: munmap_chunk(): invalid pointer: 0xb77cfdd3 ***
======= Backtrace: =========
/lib/libc.so.6(cfree+0x1bb)[0x9b667b]
/usr/lib/asterisk/modules/chan_gtalk.so[0x577de5]
/usr/lib/asterisk/modules/chan_gtalk.so[0x579d64]
/usr/sbin/asterisk(ast_request+0x174)[0x807ad04]
/usr/lib/asterisk/modules/app_dial.so[0x2c64f3]
/usr/lib/asterisk/modules/app_dial.so[0x2cb39b]
/usr/sbin/asterisk[0x80bddc8]
/usr/sbin/asterisk[0x80bfa6c]
/usr/sbin/asterisk[0x80c09ae]
/usr/sbin/asterisk[0x80eadfb]
/lib/libpthread.so.0[0xac03db]
/lib/libc.so.6(clone+0x5e)[0xa1a06e]

GTALK => SIP


sysmast01CLI>
JABBER: gtalk_account INCOMING:
sysmast01
CLI> *** glibc detected *** /usr/sbin/asterisk: munmap_chunk(): invalid pointer: 0xb7e47b73 ***
======= Backtrace: =========
/lib/libc.so.6(cfree+0x1bb)[0x9b667b]
/usr/lib/asterisk/modules/chan_gtalk.so[0x82bde5]
/usr/lib/asterisk/modules/chan_gtalk.so[0x82c436]
/usr/lib/libiksemel.so.3(iks_filter_packet+0x129)[0x278789]
/usr/lib/asterisk/modules/res_jabber.so[0x4000c7]
/usr/lib/libiksemel.so.3[0x276b55]
/usr/lib/libiksemel.so.3(iks_parse+0x5c1)[0x274ad1]
/usr/lib/libiksemel.so.3(iks_recv+0x98)[0x276488]
/usr/lib/asterisk/modules/res_jabber.so[0x3fbd70]
/usr/sbin/asterisk[0x80eadfb]
/lib/libpthread.so.0[0xac03db]
/lib/libc.so.6(clone+0x5e)[0xa1a06e]

Seems to be caused by a bug in chan_gtalk.c.
Se this page and the two patches you can find there:
bugs.digium.com/view.php?id=7764

Patches:
asterisk-gtalk-nofreeafteralloca.patch.txt
asterisk-gtalk-null.patch.txt

Good Luck!

Was getting a similar problem on ubuntu. It keep saying GnuTLS not installed

After much debugging, we checked the config.log for iksemel-1.2
and observed that the following:
checking for libgnutls-config
checking for libgnutls - version >= 0.1.0

were failing

The fix was to download the source for libgnuTLS and issue a recompile

This fixed the gnuTLS not found error and asterisk we were able to log into Gtalk…however, it crashed (core dump) during call establishment as mentioned in this post

the fix for us was to apply all the patches as mentioned here:
bugs.digium.com/view.php?id=7764
for / channels / chan_gtalk.c

We have now a successful configuration of asterisk 1.4 on ubuntu that also does gtalk :smile:

I could really use some help. I can’t even get the module to load. I’m running Ubuntu (2.6.17-10-server) with Asterisk 1.4.1 and iksemel 1.2.

[code]Connected to Asterisk 1.4.1 currently running on foo(pid = 9371)
Verbosity is at least 3
fooCLI> module load chan_gtalk.so
[Mar 7 10:23:07] WARNING[9407]: loader.c:362 load_dynamic_module: Error loading module ā€˜chan_gtalk.so’: libiksemel.so.3: cannot open shared object file: No such file or directory
[Mar 7 10:23:07] WARNING[9407]: loader.c:614 load_resource: Module ā€˜chan_gtalk.so’ could not be loaded.
foo
CLI>

user@foo:/etc/asterisk# ls /usr/lib/asterisk/modules/ | grep gtalk
chan_gtalk.so
user@foo:/etc/asterisk#

user@foo:/etc/asterisk# ls /etc/asterisk/ | grep gtalk
gtalk.conf
gtalk.conf.old
user@foo:/etc/asterisk#

user@foo:/etc/asterisk# ls /usr/local/lib/ | grep libiks
libiksemel.a
libiksemel.la
libiksemel.so
libiksemel.so.3
libiksemel.so.3.0.0
user@foo:/etc/asterisk#[/code]

Please help as I am losing my mind.

[quote=ā€œsandmanā€]I could really use some help. I can’t even get the module to load. I’m running Ubuntu (2.6.17-10-server) with Asterisk 1.4.1 and iksemel 1.2.

[code]Connected to Asterisk 1.4.1 currently running on foo(pid = 9371)
Verbosity is at least 3
fooCLI> module load chan_gtalk.so
[Mar 7 10:23:07] WARNING[9407]: loader.c:362 load_dynamic_module: Error loading module ā€˜chan_gtalk.so’: libiksemel.so.3: cannot open shared object file: No such file or directory
[Mar 7 10:23:07] WARNING[9407]: loader.c:614 load_resource: Module ā€˜chan_gtalk.so’ could not be loaded.
foo
CLI>

user@foo:/etc/asterisk# ls /usr/lib/asterisk/modules/ | grep gtalk
chan_gtalk.so
user@foo:/etc/asterisk#

user@foo:/etc/asterisk# ls /etc/asterisk/ | grep gtalk
gtalk.conf
gtalk.conf.old
user@foo:/etc/asterisk#

user@foo:/etc/asterisk# ls /usr/local/lib/ | grep libiks
libiksemel.a
libiksemel.la
libiksemel.so
libiksemel.so.3
libiksemel.so.3.0.0
user@foo:/etc/asterisk#[/code]

Please help as I am losing my mind.[/quote]
did u resolve the problem as I am having the same one
when i look at the asterisk logs

Error loading module ā€˜chan_gtalk’: libiksemel.so.3: cannot open shared object file: No such file or directory

Yeah, I resolved my issue. It took a complete reinstall of asterisk and the addons. Some components were not initially installed correctly. If you check yours thoroughly for all the .so files it is calling for, you’ll probably find that you don’t have some of the required components either.

I reinstalled and installed all components under makeselect still no luck. If you could remember any file it asked for i would appreciate

Dude,

The solution is copy
libiksemel.a
libiksemel.la
libiksemel.so
libiksemel.so.3
libiksemel.so.3.0.0

to /usr/lib

Done

Running Man

[quote=ā€œsandmanā€]I could really use some help. I can’t even get the module to load. I’m running Ubuntu (2.6.17-10-server) with Asterisk 1.4.1 and iksemel 1.2.

[code]Connected to Asterisk 1.4.1 currently running on foo(pid = 9371)
Verbosity is at least 3
fooCLI> module load chan_gtalk.so
[Mar 7 10:23:07] WARNING[9407]: loader.c:362 load_dynamic_module: Error loading module ā€˜chan_gtalk.so’: libiksemel.so.3: cannot open shared object file: No such file or directory
[Mar 7 10:23:07] WARNING[9407]: loader.c:614 load_resource: Module ā€˜chan_gtalk.so’ could not be loaded.
foo
CLI>

user@foo:/etc/asterisk# ls /usr/lib/asterisk/modules/ | grep gtalk
chan_gtalk.so
user@foo:/etc/asterisk#

user@foo:/etc/asterisk# ls /etc/asterisk/ | grep gtalk
gtalk.conf
gtalk.conf.old
user@foo:/etc/asterisk#

user@foo:/etc/asterisk# ls /usr/local/lib/ | grep libiks
libiksemel.a
libiksemel.la
libiksemel.so
libiksemel.so.3
libiksemel.so.3.0.0
user@foo:/etc/asterisk#[/code]

Please help as I am losing my mind.[/quote]

Does upgrading from 1.4.5 to 1.4.6 fix this bug?

[color=red]No yet…snif snif snif…

Running Man[/color]