[Freeswitch-users] mod_gsmopen - deadlock tty

Luiz Fernando Softov fernando at softov.com.br
Fri Sep 25 20:24:47 MSD 2015


I'm using a USB with power supply.

But sometimes it's just happen. Sometimes user remove and plug modem again.

I can't use Debian, because our system depends of FreeBSD, and we have a
lot of source (daemons) running, based, on that platform. And we use
kqueue, I think Debian don't have kqueue, it's like epool, but better, much
better.

Anyway, I don't That it's a kernel problem, because, since I have another
daemon, attached in ttyx.0 (mod_gsmopen attach to ttyx.3), and when modem
power off or "reset", only ttyx.3 still locked.

I'm trying to read the source to figure what's happening, but it's hard to
read, not because the source is difficult, but because isn't organized.

I'm thinking in rewrite the module, but if in future someone change
something in original module I will need to check my source.
There is another thing, I don't know how things like apr_thread works, and
what functions like switch_sleep(1000000) do and why using that.

Today I make some alterations where the module make a lock, LOKKA, there is
some functions who don't have unlock, and another who only have unlock,
sometimes two unlocks. So I will wait to see what will happen.

Now, here it's 3:00 am, and I'm going to sleep, almost 19 hours awake up,
trying to debug this module and another things.


Maybe you or someone have a time, to chat, or reply some e-mails, or maybe
here, to explain some questions about the source (module)?

There's some lines marked with TODO, why?
And there is another version of this module?
Which the maximum number of modems that you already usage?

2015-09-25 7:53 GMT-04:00 Giovanni Maruzzelli <gmaruzz at gmail.com>:

> if you found problems, please open a jira issue, with all info to
> replicate the problem, as explained in gsmopen page.
>
> It would be useful for us developers, and to me personally, being the
> person in charge of gsmopen.
>
> Thanks in advance,
>
> -giovanni
>
> Sincerely,
>
> Giovanni Maruzzelli
> Cell : +39-347-2665618
>
> On Fri, Sep 25, 2015 at 1:44 PM, Shabbir abbasi <shabbirabbasi92 at gmail.com
> > wrote:
>
>> mod_gsmopen  needs more development  work, i have tested it sometimes ago
>> and found it is not useable , so now i am using  asterisk with chan_dongle
>> better then gsmopen without usb HUB
>>
>> On Fri, Sep 25, 2015 at 11:11 AM, Giovanni Maruzzelli <gmaruzz at gmail.com>
>> wrote:
>>
>>> This seems to be a kernel problem.
>>>
>>> To have the most success chances: use a USB hub with power supply (eg, a
>>> USB hub that get electrical power from the wall socket).
>>> Also, use the reference.platform, debian 8 jessie, instead of freebsd.
>>>
>>> -goovanni
>>>
>>> sent from my mobile,
>>> Giovanni Maruzzelli
>>> cell: +39 347 266 56 18
>>> On Sep 25, 2015 7:19 AM, "Luiz Fernando Softov" <fernando at softov.com.br>
>>> wrote:
>>>
>>>> Hi,
>>>>
>>>> I'm using freeswitch 1.15 in Freebsd 10.1, with mod_gsmopen
>>>>
>>>> FreeSWITCH Version 1.5.15b+git~20150407T231134Z~d55c4a053b~64bit (git
>>>> d55c4a0 2015-04-07 23:11:34Z 64bit), whats happen, its the same with
>>>> another versions like, 1.6, 1.4.19, etc
>>>>
>>>> After sometime running freeswitch, i have this TTYs.
>>>>
>>>> crw-------   1 root  wheel      0x8e Sep 24 15:30 ttyU1.3
>>>> crw-------   1 root  wheel      0x8f Sep 24 15:30 ttyU1.3.init
>>>> crw-------   1 root  wheel      0x90 Sep 24 15:30 ttyU1.3.lock
>>>> crw-------   1 root  wheel      0x8e Sep 24 15:30 ttyU2.3
>>>> crw-------   1 root  wheel      0x8f Sep 24 15:30 ttyU2.3.init
>>>> crw-------   1 root  wheel      0x90 Sep 24 15:30 ttyU2.3.lock
>>>> crw-------   1 root  wheel      0x8e Sep 24 15:30 ttyU3.3
>>>> crw-------   1 root  wheel      0x8f Sep 24 15:30 ttyU3.3.init
>>>> crw-------   1 root  wheel      0x90 Sep 24 15:30 ttyU3.3.lock
>>>> crw-------   1 root  wheel      0x76 Sep 25 00:46 ttyU4.0
>>>> crw-------   1 root  wheel      0x77 Sep 24 22:28 ttyU4.0.init
>>>> crw-------   1 root  wheel      0x78 Sep 24 22:28 ttyU4.0.lock
>>>> crw-------   1 root  wheel      0x7c Sep 24 22:28 ttyU4.1
>>>> crw-------   1 root  wheel      0x7d Sep 24 22:28 ttyU4.1.init
>>>> crw-------   1 root  wheel      0x7e Sep 24 22:28 ttyU4.1.lock
>>>> crw-------   1 root  wheel      0x82 Sep 24 22:28 ttyU4.2
>>>> crw-------   1 root  wheel      0x83 Sep 24 22:28 ttyU4.2.init
>>>> crw-------   1 root  wheel      0x84 Sep 24 22:28 ttyU4.2.lock
>>>> crw-------   1 root  wheel      0x8e Sep 24 22:28 ttyU4.3
>>>> crw-------   1 root  wheel      0x8f Sep 24 22:28 ttyU4.3.init
>>>> crw-------   1 root  wheel      0x90 Sep 24 22:28 ttyU4.3.lock
>>>> crw-------   1 root  wheel      0xa8 Sep 25 00:46 ttyU5.0
>>>> crw-------   1 root  wheel      0xa9 Sep 24 22:28 ttyU5.0.init
>>>> crw-------   1 root  wheel      0xaa Sep 24 22:28 ttyU5.0.lock
>>>> crw-------   1 root  wheel      0xae Sep 24 22:28 ttyU5.1
>>>> crw-------   1 root  wheel      0xaf Sep 24 22:28 ttyU5.1.init
>>>> crw-------   1 root  wheel      0xb6 Sep 24 22:28 ttyU5.1.lock
>>>> crw-------   1 root  wheel      0xba Sep 24 22:28 ttyU5.2
>>>> crw-------   1 root  wheel      0xbb Sep 24 22:28 ttyU5.2.init
>>>> crw-------   1 root  wheel      0xbc Sep 24 22:28 ttyU5.2.lock
>>>> crw-------   1 root  wheel      0xc0 Sep 24 22:28 ttyU5.3
>>>> crw-------   1 root  wheel      0xc1 Sep 24 22:28 ttyU5.3.init
>>>> crw-------   1 root  wheel      0xc2 Sep 24 22:28 ttyU5.3.lock
>>>>
>>>> As you can see, ttyU1.3, ttyU2.3, ttyU3.3 are USB deadlocks
>>>>
>>>> I try to unload mod_gsmopen, but i receive a message that is in use
>>>> so i kill freeswitch, then ttyU1.3, ttyU2.3, ttyU3.3, are free and
>>>> disappear (as well .init and .lock)
>>>>
>>>> I try to figure out whats happening, with logs, alarms, but i can't.
>>>> Someone have the same problem, or know the solution?
>>>>
>>>>
>>>> ps.
>>>> Reading the list, i realize that few members use the module, or don't
>>>> have problems.
>>>> If i am correct, is there any other way to use GSM modems or GSM, which
>>>> is low cost?
>>>> Is there anyone who can guide me in some things about the code or tips?
>>>>
>>>> ps 2.
>>>> sorry about my english
>>>>
>>>> --
>>>> Luiz Fernando Softov
>>>> http://www.softov.com.br
>>>> fernando at softov.com.br
>>>>
>>>>
>>>> _________________________________________________________________________
>>>> Professional FreeSWITCH Consulting Services:
>>>> consulting at freeswitch.org
>>>> http://www.freeswitchsolutions.com
>>>>
>>>> Official FreeSWITCH Sites
>>>> http://www.freeswitch.org
>>>> http://confluence.freeswitch.org
>>>> http://www.cluecon.com
>>>>
>>>> FreeSWITCH-users mailing list
>>>> FreeSWITCH-users at lists.freeswitch.org
>>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>>> UNSUBSCRIBE:
>>>> http://lists.freeswitch.org/mailman/options/freeswitch-users
>>>> http://www.freeswitch.org
>>>>
>>>
>>> _________________________________________________________________________
>>> Professional FreeSWITCH Consulting Services:
>>> consulting at freeswitch.org
>>> http://www.freeswitchsolutions.com
>>>
>>> Official FreeSWITCH Sites
>>> http://www.freeswitch.org
>>> http://confluence.freeswitch.org
>>> http://www.cluecon.com
>>>
>>> FreeSWITCH-users mailing list
>>> FreeSWITCH-users at lists.freeswitch.org
>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> http://www.freeswitch.org
>>>
>>
>>
>> _________________________________________________________________________
>> Professional FreeSWITCH Consulting Services:
>> consulting at freeswitch.org
>> http://www.freeswitchsolutions.com
>>
>> Official FreeSWITCH Sites
>> http://www.freeswitch.org
>> http://confluence.freeswitch.org
>> http://www.cluecon.com
>>
>> FreeSWITCH-users mailing list
>> FreeSWITCH-users at lists.freeswitch.org
>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>> http://www.freeswitch.org
>>
>
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>



-- 
Luiz Fernando Softov
http://www.softov.com.br
fernando at softov.com.br
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20150925/e7ce789e/attachment-0001.html 


Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list