Unable to connect to remote asterisk

Get help with installing, upgrading and running Asterisk.

Moderators: muppetmaster, Moderator, Support

Unable to connect to remote asterisk

Postby peter59 » Mon Dec 21, 2015 2:48 am

Hello,

I have a problem related to the Asterisk CLI, when I enter "asterisk -rvvvvvvvvvvvvvv", it cannot display the Asterisk CLI and instaed, I have this message "Unable to connect to remote asterisk (does /var/run/asterisk.ctl exist?)."

When I check with "locate asterisk.ctl", it is indeed in the repertory "/var/run/".

So after searching I have found we can enter "ps -A | grep asterisk" in order to find an asterisk "ghost" running and then kill it, and I have found:
Code: Select all
1474 ?        00:00:14 asterisk
1615 pts/3    00:00:13 asterisk
31411 ?        00:00:00 safe_asterisk
31414 ?        01:08:53 asterisk


I don't know if it's the case and which one of these I should kill?
Otherwise, is there an other way to fix my problem?

Thank you in advance!
peter59
Newsterisk
 
Posts: 42
Joined: Thu Oct 15, 2015 8:05 am

Re: Unable to connect to remote asterisk

Postby david55 » Mon Dec 21, 2015 4:12 am

Probably the most common cause if this is a permissions problem, rather than a ghost Asterisk, but the Asterisk with the large CPU time is clearly the real Asterisk.

Also, before trying to kill it, try "service asterisk stop".
david55
Moves Like Spencer
 
Posts: 12570
Joined: Fri Sep 26, 2008 5:03 am

Re: Unable to connect to remote asterisk

Postby rootmedia » Mon Dec 21, 2015 8:57 am

asterisk should not run more than once on the system
Code: Select all
root@SRV-B:/etc/asterisk# ps ax | grep asterisk
29625 ?        Ssl    0:06 /usr/sbin/asterisk -p -U asterisk
29626 ?        S      0:00 astcanary /var/run/asterisk/alt.asterisk.canary.tweet.tweet.tweet 29625
29739 pts/0    S+     0:00 grep --color=auto asterisk


Try Restarting asterisk on the system and try again
Brent HIggs
CEO & Founder at
Image
https://root.media
rootmedia
Newsterisk
 
Posts: 9
Joined: Thu Dec 17, 2015 12:57 am
Location: Vancouver, BC

Re: Unable to connect to remote asterisk

Postby peter59 » Mon Dec 21, 2015 9:43 am

Even though I restart Asterisk, I have the same problem, but I can access to the CLI by taping "asterisk -cvvvvvv".
peter59
Newsterisk
 
Posts: 42
Joined: Thu Oct 15, 2015 8:05 am


Return to Asterisk Support

Who is online

Users browsing this forum: No registered users and 1 guest