[asterisk-users] Calling GOSUB from Macro on Asterisk 1.8
I know we should not be running an Asterisk so old but this customer really does not want to replace this particular installation. I am having a problem when calling Gosub from a macro. It seems that if I call gosub and return to the macro all Macro related variables like MACRO_EXTEN and ARG are gone. Is that expected or should I look for a problem elsewhere? On the CLI I can see the call enter the macro, the use the GOSUB code and when it returns to try to dial I have something like: Dial(${ARG1}) (where ARG1 is a parameter sent to the macro). I get an error: WARNING[21682] app_dial.c: Dial requires an argument (technology/number) This is because the ARG variable is no longer available after the GOSUB. If I remove the gosub everything works as expected. I know macros are deprecated but they are in use in most of my servers and it will take a while to replace everything. Any pointers? -- Telecomunicaciones Abiertas de México S.A. de C.V. Carlos Chávez +52 (55)8116-9161 -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] AMI not responding correctly
On Wednesday 29 May 2019 at 22:23:48, Jason wrote: > Your output is exactly what I expect (and what I see on other systems) > > The real mystery here is why is the AMI on this system responding > strangely?! Permissions? Corruption? Some asterisk config file setting > I should look at? My first thing to look at would be the /etc/asterisk/manager.conf or /etc/asterisk/manager.d/*.conf stanza for the user you're logging in to AMI as, and also the [general] stanza, to check that "the AMI connection has full read/write permissions" really is true. Antony. > -Original Message- > From: asterisk-users [mailto:asterisk-users-boun...@lists.digium.com] On > Behalf Of Antony Stone Sent: Wednesday, May 29, 2019 4:17 PM > To: Asterisk Users Mailing List - Non-Commercial Discussion > Subject: Re: [asterisk-users] AMI not > responding correctly > > On Wednesday 29 May 2019 at 22:01:11, Jason wrote: > > I am communicating > > How? > > > with Asterisk 13.18.3 over the AMI and issue the command: > > > > ActionID: 11 > > Action: command > > Command: core show calls > > > > And the response I get is: > > > > Response: Follows > > Privilege: Command > > ActionID: 11 > > --END COMMAND- > > What happens if (at pretty much the same time) you run the command "core > show calls" in the Asterisk command console? > > > But where is the call data? > > On my system (Asterisk 13.14.1) I get: > > Action: Command > Command: core show calls > > Response: Follows > Privilege: Command > 0 active calls > 0 calls processed > --END COMMAND-- > > > What is going wrong on this system?I confirmed the AMI connection has > > full read/write permissions. Why is the call data missing from the > > response? > > How are you connecting and what are you using to parse the response? > > Try a simple telnet and see if the result is the same: > > $ telnet localhost 5038 > Trying 127.0.0.1... > Connected to localhost.localdomain. > Escape character is '^]'. > Asterisk Call Manager/2.9.0 > Action: login > Username: myusername > Secret: secretpassword > > Response: Success > Message: Authentication accepted > > Event: FullyBooted > Privilege: system,all > Status: Fully Booted > > Action: Command > Command: core show calls > > Response: Follows > Privilege: Command > 0 active calls > 0 calls processed > --END COMMAND-- > > > Antony. > > Response: Goodbye > Message: Thanks for all the fish. -- How does an Israeli man make beer? Hebrews it. Please reply to the list; please *don't* CC me. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] AMI not responding correctly
I have a C app that communicates with the AMI over a socket. The app works fine (has for years), and it dumps a debug log with all tx/rx traffic. So what I posted is exactly what the AMI is responding with. A telnet session would product the same. I don't have access to the CLI, but I did ask the customer to try that command on the CLI. Your output is exactly what I expect (and what I see on other systems) The real mystery here is why is the AMI on this system responding strangely?! Permissions? Corruption? Some asterisk config file setting I should look at? Jason -Original Message- From: asterisk-users [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Antony Stone Sent: Wednesday, May 29, 2019 4:17 PM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] AMI not responding correctly On Wednesday 29 May 2019 at 22:01:11, Jason wrote: > I am communicating How? > with Asterisk 13.18.3 over the AMI and issue the command: > > ActionID: 11 > Action: command > Command: core show calls > > And the response I get is: > > Response: Follows > Privilege: Command > ActionID: 11 > --END COMMAND- What happens if (at pretty much the same time) you run the command "core show calls" in the Asterisk command console? > But where is the call data? On my system (Asterisk 13.14.1) I get: Action: Command Command: core show calls Response: Follows Privilege: Command 0 active calls 0 calls processed --END COMMAND-- > What is going wrong on this system?I confirmed the AMI connection has > full read/write permissions. Why is the call data missing from the > response? How are you connecting and what are you using to parse the response? Try a simple telnet and see if the result is the same: $ telnet localhost 5038 Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. Asterisk Call Manager/2.9.0 Action: login Username: myusername Secret: secretpassword Response: Success Message: Authentication accepted Event: FullyBooted Privilege: system,all Status: Fully Booted Action: Command Command: core show calls Response: Follows Privilege: Command 0 active calls 0 calls processed --END COMMAND-- Antony. Response: Goodbye Message: Thanks for all the fish. -- 3 logicians walk into a bar. The bartender asks "Do you all want a drink?" The first logician says "I don't know." The second logician says "I don't know." The third logician says "Yes!" Please reply to the list; please *don't* CC me. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] AMI not responding correctly
On Wednesday 29 May 2019 at 22:01:11, Jason wrote: > I am communicating How? > with Asterisk 13.18.3 over the AMI and issue the command: > > ActionID: 11 > Action: command > Command: core show calls > > And the response I get is: > > Response: Follows > Privilege: Command > ActionID: 11 > --END COMMAND- What happens if (at pretty much the same time) you run the command "core show calls" in the Asterisk command console? > But where is the call data? On my system (Asterisk 13.14.1) I get: Action: Command Command: core show calls Response: Follows Privilege: Command 0 active calls 0 calls processed --END COMMAND-- > What is going wrong on this system?I confirmed the AMI connection has > full read/write permissions. Why is the call data missing from the > response? How are you connecting and what are you using to parse the response? Try a simple telnet and see if the result is the same: $ telnet localhost 5038 Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. Asterisk Call Manager/2.9.0 Action: login Username: myusername Secret: secretpassword Response: Success Message: Authentication accepted Event: FullyBooted Privilege: system,all Status: Fully Booted Action: Command Command: core show calls Response: Follows Privilege: Command 0 active calls 0 calls processed --END COMMAND-- Antony. Response: Goodbye Message: Thanks for all the fish. -- 3 logicians walk into a bar. The bartender asks "Do you all want a drink?" The first logician says "I don't know." The second logician says "I don't know." The third logician says "Yes!" Please reply to the list; please *don't* CC me. -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
[asterisk-users] AMI not responding correctly
I am communicating with Asterisk 13.18.3 over the AMI and issue the command: ActionID: 11 Action: command Command: core show calls And the response I get is: Response: Follows Privilege: Command ActionID: 11 --END COMMAND- But where is the call data? What is going wrong on this system?I confirmed the AMI connection has full read/write permissions. Why is the call data missing from the response? Jason -- _ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- Check out the new Asterisk community forum at: https://community.asterisk.org/ New to Asterisk? Start here: https://wiki.asterisk.org/wiki/display/AST/Getting+Started asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users