"Connecting to Asterisk Manager..." but never connects

I am setting up a node for a friend 52352 and thought I would be slick and just copy my image to his (same hardware)- I adjusted everything and the node is working but Allmon never connects to the AMI(sp?)
I have checked manager.conf and the allmon2 cfg file many times and they match. I can log into the web interface too. Suggestions? Not sure what I am missing.
Clifford

OMG now my original node is doing the same thing- not sure what happened- file permissions? Ugh- so strange not changed anything on orig node. 48654

1 Like

anybody? suggestions? thx

1 Like

backup, backup, backup! All you need is to copy everything in /etc/asterisk/. We (ASL) even supply a backup service; https://wiki.allstarlink.org/wiki/Backup

When bringup a new node install app_rpt as you would from scratch, rename the asterisk directory, make a new one and copy the backup files to it. Easy and quick.

end lecture

Have you checked manager.conf for the correct bindaddr and permissions? Use the search tool on this site (or google) for settings. If all else fails post you manger.conf (sans password) so we can take a look.

1 Like

I cloned the drive. I do backup both locally and to ASL servers. Cloning was fast. Thx for outlining another way to do it. I have checked allmon.ini and manager.conf many many times I see nothing out of place. bindaddr is fine at 127.0.0.1:5038 and user/pass matches in manager and allmon cfg files.
I can log on to allmon but only displays “Waiting” for a split sec then “Connecting to Asterisk Manager…”

Manager-

bindaddr = 127.0.0.1 ; Local interface only! $
displayconnects = yes
;
; Add a Unix epoch timestamp to events (not action responses)
;
;timestampevents = yes

[admin]
secret = ******** $
read = all,system,call,log,verbose,command,agent,user,config
write = all,system,call,log,verbose,command,agent,user,config

Allmon-

<?php
[Off-site Link]
url=http://google.com
[48654]
host=127.0.0.1:5038
user=admin
passwd=********
nomenu=no
hideNodeURL=yes
;[501]
;system=System1
;host=127.0.0.1:5038
;user=admin
;passwd=********
;nomenu=yes
;hideNodeURL=yes
;[502]
;system=System1
;host=127.0.0.1:5038
;user=admin
;passwd=password2
;nomenu=yes
;hideNodeURL=yes
;[2000]
;system=System2
;host=127.0.0.1:5037
;user=admin
;passwd=password2
;[2000 RTCM]
;system=System2
;rtcmnode=2000
;[Grouped Nodes]
;nodes=500,501,2000
;[2 RTCMs]
;system=System2
;rtcmnode=2000,2001
?>

I don’t think the port is supposed to be specified on the bindaddr.

[general]                                                                       
displaysystemname = yes                                                         
enabled = yes                                                                   
;webenabled = yes                                                               
port = 5038                                                                     
                                                                                
;httptimeout = 60                                                               
; a) httptimeout sets the Max-Age of the http cookie                            
; b) httptimeout is the amount of time the webserver waits                      
;    on a action=waitevent request (actually its httptimeout-10)                
; c) httptimeout is also the amount of time the webserver keeps                 
;    a http session alive after completing a successful action                  
                                                                                
bindaddr = 127.0.0.1   ; Local interface only!                                                           
;displayconnects = yes                                                          
;                                                                               
; Add a Unix epoch timestamp to events (not action responses)                   
;                                                                               
;timestampevents = yes                                                          
                                                                                
[admin]                                                                         
secret = <secret>                                                                  
read = all,system,call,log,verbose,command,agent,user,config                    
write = all,system,call,log,verbose,command,agent,user,config     

It is not. My cfg are as you suggest I posted them right there. The port is defined that way in the allmon cfg by default. Thx.

I can’t read your allmon.ini.php. Please post it by putting 3 backticks (```) on a line by them self. Then, on the next line, paste your config. Then finish it off with 3 more backticks on the line following your config.

done- thx - Clifford

1 Like

See if AMI is alive. Test with telnet…

http://www.jcgonzalez.com/test-asterisk-ami-telnet

1 Like

Neither asterisk CLI nor the root user recognize the command suggested- “telnet localhost 5038”

root@ASL_PI_48654:/etc/asterisk# telnet localhost 5038
bash: telnet: command not found
root@ASL_PI_48654:/etc/asterisk#

1 Like

sudo apt-get install telnet

1 Like

Thanks!

root@ASL_PI_48654:/home/repeater# telnet localhost 5038
Trying ::1…
Trying 127.0.0.1…
Connected to localhost.
Escape character is ‘^]’.
Asterisk Call Manager/1.0

Both nodes are good in this department!
I am able to login successfully on both nodes:

Action: Login
ActionID: 1
Username: admin
Secret: ********

Response: Success
ActionID: 1
Message: Authentication accepted

Also- I have tried to understand what actually requests the login and how the info is generated like “Connecting to Asterisk Manager…” but I have not figured it out. I have looked at page source and try to understand but js is not my forte’.

Try setting a simple password, only letters and numbers. I had a report a while back (post is on here somewhere) that some special character caused AMI login to fail.

My passwords are only letters and numbers. I changed it anyway to no effect. Strange!

Does anyone know what script on the Allmon page requests access to ASM and then what produces the text output? (“Connecting to Asterisk Manager…”)
If I understood what was actually taking place behind the scenes maybe I could solve this problem. I have tried reverse engineering it- but cannot locate the code on the web page or the ASM executable etc.

@kk6qms, Sounds like you’re getting desperate. If you didn’t know I’m the developer of Allmon. Would you like to do a TeamViewer session? I’ll be glad to take a look at your setup.

I just want to solve the problem and give my 77yo friend his node so he can start enjoying it. Ya a TV session would be great as my ISP is dragging their feet getting me in bridge mode so I can get all my port forwarding set up for SSH etc. Sending you my TV info privately- thanks!

Thanks for the help Tim. That was a strange one! Reinstall of Allmon went smoothly.

1 Like