[asterisk-dev] More "concise" CLI commands - something we really want?
While browsing the bug tracker today, I found a patch for adding more "concise" commands to the SIP channel. My personal opinion is that I don't like adapting the CLI for machine parsing. If we're about to do that, we might as well convert all CLI listings in one big janitor project. But we already have the manager for that kind of communication - machine-parseable. We could easily write a wrapper for /utils that replaces "asterisk -x" for web applications and other scripts. I propose that we deprecate the existing "concise" commands in trunk, don't accept new ones and refer users and developers to our lovely AMI solution. /O ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
On Thu, Nov 15, 2007 at 12:43:40PM +0100, Johansson Olle E wrote: > While browsing the bug tracker today, I found a patch for adding more > "concise" commands to the SIP channel. > > My personal opinion is that I don't like adapting the CLI for machine > parsing. If we're about to do that, we might > as well convert all CLI listings in one big janitor project. But we > already have the manager for that kind of > communication - machine-parseable. We could easily write a wrapper > for /utils that replaces "asterisk -x" > for web applications and other scripts. > > I propose that we deprecate the existing "concise" commands in trunk, > don't accept new ones and refer > users and developers to our lovely AMI solution. I have two potential issues with this: 1. "concise" tend to better fit in a 80-column terminal (such as the Linux console). 2. asterisk -rx "just works" if you're a local root. manager requires extra setup. As for (2), I consider what Debian did for mysql - add an extra account on install-time who can connect from localhost only. The password for it is written in a separate mysql client file that only root can read: # cat /etc/mysql/debian.cnf # Automatically generated for Debian scripts. DO NOT TOUCH! [client] host = localhost user = debian-sys-maint password = socket = /var/run/mysqld/mysqld.sock [mysql_upgrade] user = debian-sys-maint password = socket = /var/run/mysqld/mysqld.sock basedir = /usr So, what would be the equivalent for the manager interface? Quite implementation-dependent. It's quite tricky to even assure a specific account will be injected into manager.conf . -- Tzafrir Cohen icq#16849755 jabber:[EMAIL PROTECTED] +972-50-7952406 mailto:[EMAIL PROTECTED] http://www.xorcom.com iax:[EMAIL PROTECTED]/tzafrir ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
Tzafrir Cohen ha scritto: > 2. asterisk -rx "just works" if you're a local root. manager requires > extra setup. I've replaced rasterisk with a manager script that return just the output. Instead with the CLI it return also other bogus messages that are not the direct output of the command i executed. ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
On Thu, Nov 15, 2007 at 01:49:18PM +0100, Olle E Johansson wrote: > > 15 nov 2007 kl. 13.22 Tzafrir Cohen wrote: > > 1. "concise" tend to better fit in a 80-column terminal (such as the > > Linux console). > That won't be the case with other listings - we have much more > information > than what fits. The normal listings try to handle that by cutting off > data. Or provide different formatting or whatever. There are a number of methods for doing that. A problem here is that the Asterisk server cannot ask for settings of the client terminal (e.g: COLUMNS). > > I think it's simple to enable manager. We just need to provide a good > script that outputs the data in many different ways, maybe using awk > or something classy? This implies that you have a manager account set up properly and securely in a default Asterisk installation. I rather like the usage of file permissions on a socket for granitng permissions. Doing the same with IP sockets is not as straight-forward. Furthermore, there's an explicit login process. If someone comes up with a nice readline (or similar) based interactive client that connects to Asterisk and Just Works (completion included) I would re-consider this. I do find the inclusion of the CLI in Asterisk as rather non-elegant (yeah, I know, this is just ranting with no code attached to it) -- Tzafrir Cohen icq#16849755 jabber:[EMAIL PROTECTED] +972-50-7952406 mailto:[EMAIL PROTECTED] http://www.xorcom.com iax:[EMAIL PROTECTED]/tzafrir ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] Reverse decrement of call counter
On Thursday 15 November 2007 03:56:26 Rizwan Hisham wrote: > As you can see in the code which i mentioned in my last email that for > decrementing the call-limit value they are actually incrementing it, and > some how it is called reverse decrementing. I need to know What is the > reason for doing that. Under what circumstances this IF condition gets > executed? An annotation of the code reveals its history. If the code has grown stale, then certainly it could be removed. http://svn.digium.com/view/asterisk/trunk/channels/chan_sip.c?view=annotate > Since nobody has answered my questions lately, i need to know y. Am i > asking too difficult questions or too vague questions? You're asking the wrong questions. What you're essentially asking is why someone who wrote the code, who rarely has the time to respond to posts on any list, let alone this one, wrote a particular comment almost 4 years ago and expecting a reply. My best guess is that the code was detecting whether the call counter was incremented in the first place, since it was going to be decremented later, and incrementing it to account for that unconditional decrement. It has probably been fixed since, and this code is artifact of the old implementation. If removing that code fixes the issue, I think the matter is closed. Post a patch to the bugtracker and be done with it. -- Tilghman ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
[asterisk-dev] Audiohooks-1.4
I am having the same chanspy crash as others are having reported in bugs. I am attempting to run a MixMonitor against a SIP to SIP channel and getting a Seg Fault 11 in channel.c:3587 because app_mixmonitor.c:169 is sending over a chan pointer to address 0. Since this is off the main branches, do I still open a bugs report on it? Here is a quick backtrace (gdb) bt #0 ast_bridged_channel (chan=0x0) at channel.c:3587 #1 0xb58e56b0 in mixmonitor_thread (obj=0x8245968) at app_mixmonitor.c:169 #2 0x080f87c0 in dummy_start (data=0x8231090) at utils.c:843 #3 0xb7f3d240 in start_thread () from /lib/tls/i686/cmov/libpthread.so.0 #4 0xb702c4ae in clone () from /lib/tls/i686/cmov/libc.so.6 The last verbose line is -- Executing [EMAIL PROTECTED]:12] BackGround("SIP/X.X.X.X-b653bf90", "main-menu/greeting") in new stack Tony Plack ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] Audiohooks-1.4
- Original Message - From: Tony Plack [mailto:[EMAIL PROTECTED] To: Ast Dev List [mailto:[EMAIL PROTECTED] Sent: Thu, 15 Nov 2007 10:48:47 -0400 Subject: [asterisk-dev] Audiohooks-1.4 > I am having the same chanspy crash as others are having reported in bugs. > > I am attempting to run a MixMonitor against a SIP to SIP channel and getting > a Seg Fault 11 in channel.c:3587 because app_mixmonitor.c:169 is sending > over a chan pointer to address 0. > > Since this is off the main branches, do I still open a bugs report on it? > Just add a note to one of the existing bugs. Joshua Colp Software Developer Digium, Inc. ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
[asterisk-dev] implementing struct ast_channel with astobj2 ?
is there any work going on for implementing struct ast_channel with astobj2? I am running in a problem with the video extensions that i think already came out in some other channel driver, and would be completely solved implementing ast_channel using refcounted structures. In this specific case, there is a thread handling video that needs to access part of the struct ast_channel, and grab a lock on it. During hangup, the hangup handler is called with the channel locked, so the only way to synchronize the handler and the video thread is release the lock and wait for the thread to terminate. If we don't synchronize, the channel is destroyed when the hangup handler completes, and the video thread will access a non existing structure. cheers luigi ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
[asterisk-dev] Need help regarding G.729 Codec purchase
Hi All, I want to purchase commercial license of G.729 Codec through Digium. Can anyone help me for the same and tell me the price of it. Thanx in advance. -- Regards Lokesh Agrawal --- "Dream is not what you see in sleep, is the the thing which does not let you sleep" --- ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
On Thu, 2007-11-15 at 08:35 -0700, Corey Edwards wrote: > On Thu, 2007-11-15 at 15:23 +0200, Tzafrir Cohen wrote: > > On Thu, Nov 15, 2007 at 01:49:18PM +0100, Olle E Johansson wrote: > > > > > > 15 nov 2007 kl. 13.22 Tzafrir Cohen wrote: > > > > > > 1. "concise" tend to better fit in a 80-column terminal (such as the > > > > Linux console). > > > That won't be the case with other listings - we have much more > > > information > > > than what fits. The normal listings try to handle that by cutting off > > > data. > > > > Or provide different formatting or whatever. There are a number of > > methods for doing that. A problem here is that the Asterisk server > > cannot ask for settings of the client terminal (e.g: COLUMNS). > > I created the patch because it shows the entire call ID. When I found > 'concise' it was one of those "oh cool!" moments. I really like it. > > > > I think it's simple to enable manager. We just need to provide a good > > > script that outputs the data in many different ways, maybe using awk > > > or something classy? > > > > This implies that you have a manager account set up properly and > > securely in a default Asterisk installation. > > Exactly. I don't have manager set up and really haven't played with it > much. Like many users I am familiar with the CLI. I find value in being > able to see the untruncated call data without having to switch gears or > learn something new. TMTOWTDI and all that. TMTOWTDI is fine and all until you must maintain many ways of doing the same thing. > That said, the CLI also does tab complete on the call ID so that solves > my problem too. I certainly will survive without this patch, but I > definitely would use it if it was there. This begs the question of what exactly are you doing that you would use tab completion and therefore it seems you are on the CLI and not scripting it. So far as I have followed this thread, the idea is that concise is being used for programming scripts to do things that should be using the AMI interface. If your interaction needs the full callid or some other field for normal work on the console, then maybe you have a good case for "fixing" the output of a different command. -- Steven Critchfield <[EMAIL PROTECTED]> ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
15 nov 2007 kl. 15.51 skrev Russell Bryant: > Johansson Olle E wrote: >> I propose that we deprecate the existing "concise" commands in trunk, >> don't accept new ones and refer >> users and developers to our lovely AMI solution. > > I agree with you here, as well. Seems like we've reached consensus somehow. I will close the bug report. Is there someone out there that can make a cool perl/bash/awk/ruby script that can replace asterisk -rx show channels concise ??? /O ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
Johansson Olle E wrote: > I propose that we deprecate the existing "concise" commands in trunk, > don't accept new ones and refer > users and developers to our lovely AMI solution. I agree with you here, as well. -- Russell Bryant Senior Software Engineer Open Source Team Lead Digium, Inc. ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] More "concise" CLI commands - something we really want?
Olle E Johansson wrote: > 15 nov 2007 kl. 13.22 skrev Tzafrir Cohen: > > >> On Thu, Nov 15, 2007 at 12:43:40PM +0100, Johansson Olle E wrote: >> >>> While browsing the bug tracker today, I found a patch for adding more >>> "concise" commands to the SIP channel. >>> >>> My personal opinion is that I don't like adapting the CLI for machine >>> parsing. If we're about to do that, we might >>> as well convert all CLI listings in one big janitor project. But we >>> already have the manager for that kind of >>> communication - machine-parseable. We could easily write a wrapper >>> for /utils that replaces "asterisk -x" >>> for web applications and other scripts. >>> >>> I propose that we deprecate the existing "concise" commands in trunk, >>> don't accept new ones and refer >>> users and developers to our lovely AMI solution. >>> >> I have two potential issues with this: >> >> 1. "concise" tend to better fit in a 80-column terminal (such as the >> Linux console). >> > That won't be the case with other listings - we have much more > information > than what fits. The normal listings try to handle that by cutting off > data. > > I think it's simple to enable manager. We just need to provide a good > script that outputs the data in many different ways, maybe using awk > or something classy? > > /O > > I'm going to agree with Olle here. I think there should really be only one way / format to present information from the CLI and everything else should be driven through interfaces designed to deliver multiple formats (eg AMI). -- Bird's The Word Technologies, Inc. http://www.btwtech.com/ ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
[asterisk-dev] Issue #10659
Hi, Looking at this and the commit for it, and having disabled it to fix an issue with a system that we have, I want to ask - are you sure people don't want single-channel unanswered events? What if the call started but got hung-up before the dialplan was able go find the destination and do Dial() - in that case the CDR is lost, and it's in fact very important in some setups :) signature.asc Description: Това е цифрово подписана част от писмото ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] Need help regarding G.729 Codec purchase
Um... http://store.digium.com/productview.php?category_id=5&product_code=8G729CODEC&main_category_id=5 On Nov 15, 2007 10:59 AM, Lokesh Agrawal <[EMAIL PROTECTED]> wrote: > Hi All, > > I want to purchase commercial license of G.729 Codec through Digium. Can > anyone help me for the same and tell me the price of it. > > Thanx in advance. > > > -- > Regards > Lokesh Agrawal > > > --- > "Dream is not what you see in sleep, is the the thing which does not let > you sleep" > --- > > ___ > --Bandwidth and Colocation Provided by http://www.api-digital.com-- > > asterisk-dev mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-dev > ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
Re: [asterisk-dev] Provisional cross-connect?
On Nov 14, 2007 9:21 PM, Alex Balashov <[EMAIL PROTECTED]> wrote: >The call is going out on a PRI in this case. > >The question I asked was rather theoretical; what we are trying to do > concretely is use the automatic dial-out functionality > (/var/spool/asterisk/outgoing) to play a message to a callee. The problem > is that we have to have some sense of whether the callee has answered > first (yes, there are going to be other issues like tone detection, etc. - > we are just aiming for a simple pickup for now). If I understand your situation correctly, its possible that the issue you're facing has more to do with how the information in the call files are processed than perhaps how PRIs and SIP channels are handled in asterisk[1]. Perhaps you could try creating a call file which first initiates the call out the PRI first and then connects the answered line to a point in the dialplan where the announcements are played? Something like: ---8<--- Channel: Zap/g1/ MaxRetries: 0 RetryTime: 60 WaitTime: 90 Context: outbound-announcement Extension: s Priority: 1 --->8--- Hope that helps in some way. Gerald [1] In my simple setup whereby I have a Cisco 7960 registered on an Asterisk box with PRI lines connected, the Cisco phone never says "connected" until the far end answers... ___ --Bandwidth and Colocation Provided by http://www.api-digital.com-- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev