Problem with start and connection to Asterisk

Hi ALL,

I’m a newbie at Asterisk/VoIP and I need your guys advice. I have Asterisk 13.6.0 and FreePBX 12.0.76.2. It worked I could receive and make calls, but I wanted to receive and send faxes as well, so I decided to install spandsp module. Because I had installed Asterisk-FreePBX from source codes, I rebuilt my Asterisk for adding the module I need. After that my Asterisk crushed. I’m not able to proper start to it and even proper finish. When I do asterisk -rvvvv I’ve got common error message :

[root@voipserv Wed Jan 04 19:10:57 asterisk]# asterisk -rvvvv
Unable to connect to remote asterisk (does /var/run/asterisk/asterisk.ctl exist?)
[root@voipserv Wed Jan 04 19:18:53 asterisk]#

During the start of Asterisk I got next warning and errors:

Asterisk Dynamic Loader Starting:
[Jan 4 19:10:56] NOTICE[24492]: cdr.c:4162 cdr_toggle_runtime_options: CDR simple logging enabled.
Asterisk PBX Core Initializing
Asterisk Dynamic Loader Starting:
[Jan 4 19:10:56] NOTICE[24492]: loader.c:1364 load_modules: 300 modules will be loaded.
[Jan 4 19:10:56] WARNING[24492]: loader.c:553 load_dynamic_module: Error loading module ‘res_ari_events.so’: /usr/lib64/asterisk/modules/res_ari_events.so: undefined symbol: stasis_app_register_all
[Jan 4 19:10:56] WARNING[24492]: loader.c:553 load_dynamic_module: Error loading module ‘res_monitor.so’: /usr/lib64/asterisk/modules/res_monitor.so: undefined symbol: __ast_beep_stop

[Jan 4 19:10:57] WARNING[24492]: res_phoneprov.c:1229 get_defaults: Unable to find a valid server address or name.

[Jan 4 19:10:57] NOTICE[24492]: chan_skinny.c:8409 config_load: Configuring skinny from skinny.conf

[Jan 4 19:10:57] NOTICE[24492]: confbridge/conf_config_parser.c:2073 verify_default_profiles: Adding default_menu menu to app_confbridge

[Jan 4 19:10:57] NOTICE[24492]: cel_custom.c:95 load_config: No mappings found in cel_custom.conf. Not logging CEL to custom CSVs.

[Jan 4 19:10:57] WARNING[24492]: pbx.c:7386 ast_register_application2: Already have an application ‘SendFAX’
[Jan 4 19:10:57] WARNING[24492]: pbx.c:7386 ast_register_application2: Already have an application ‘ReceiveFAX’

FreePBX web page also cannot to connect to Asterisk

Could you give me advice, please, what should I do/read/check?

Thank you in advance,
Ivan

Remove all the pre-existing modules before you do make install.

You appear to have more than one module that implements fax, and the chances are that you are loading one that was compiled for the old configuration.

If it still crashes, google “asterisk wiki backtrace” for how to get debugging information on a crash.

Thank you David! When you say “remove pre-existing modules” does it mean I need to go to Asterisk make menu and delete these module there?

Before doing the “make install” step of Asterisk you need to clear out the modules directory, if it is in the default location it would be “rm -rf /usr/lib/asterisk/modules”. The “make install” also warns you at the end if you have modules in the directory that should not be there.

Thanks a lot Jcolp!

It helped. My modules located in /usr/lib64/asterisk/modules. When I deleted and rebuilt Asterisk them it’s up. Now I have another trouble. :slight_smile: My FreePBX does not want to connect to Asterisk which is understandable, I lost all my config files. Does anyone could help the stupid newbie :slight_smile: what config file I should change to merry FreePBX and Asterisk?

Thank you in advance!
Ivan

Hello guys,

I have strange problem. My PBX is not able to log in to the Asterisk. In the log file /var/log/asterisk/freepbx.log I have next:

[2017-Jan-11 17:36:24] [PHP-NOTICE] (/var/www/html/admin/functions.inc.php:254) - Undefined index: data
[2017-Jan-11 17:36:24] [PHP-NOTICE] (/var/www/html/admin/functions.inc.php:258) - Undefined index: data
[2017-Jan-11 17:36:24] [PHP-NOTICE] (/var/www/html/admin/functions.inc.php:254) - Undefined index: data
[2017-Jan-11 17:36:24] [PHP-NOTICE] (/var/www/html/admin/functions.inc.php:258) - Undefined index: data
[2017-Jan-11 17:36:24] [FATAL] (libraries/utility.functions.php:470) - retreive_conf failed to get engine information and cannot configure up a softwitch with out it. Error: ERROR-UNABLE-TO-PARSE
[2017-Jan-11 17:36:24] [CRITICAL] (BMO/Notifications.class.php:493) - [NOTIFICATION]-[freepbx]-[RCONFFAIL] - retrieve_conf failed, config not applied (Reload failed because retrieve_conf encountered an error: 1)

Could you help me, please?

Thank you in advance,
Ivan

Found solution for this.

I need to add into /var/lib/asterisk/bin/retrieve_conf next:

$engineinfo[‘engine’]=“asterisk”;
$engineinfo[‘version’]=“13.6.0”;
Just after $engineinfo = engine_getinfo();

But now I have another error. :slight_smile:

Error: Did not receive valid response from server
XHR response code: 200 XHR responseText: undefined jQuery status: parsererror

and in the /valog/asterisk/freepbx.log I have

[2017-Jan-11 18:23:31] [PHP-NOTICE] (/var/www/html/admin/config.php:210) - Undefined variable: active_modules
[2017-Jan-11 18:23:31] [PHP-NOTICE] (/var/www/html/admin/views/menu.php:88) - Undefined variable: menu
[2017-Jan-11 18:23:31] [PHP-WARNING] (/var/www/html/admin/views/menu.php:88) - Invalid argument supplied for foreach()
[2017-Jan-11 18:23:31] [PHP-WARNING] (/var/www/html/admin/views/menu.php:146) - uksort() expects parameter 1 to be array, null given
[2017-Jan-11 18:23:31] [PHP-WARNING] (/var/www/html/admin/views/menu.php:147) - implode(): Argument must be an array

Do you have any ideas?

Thank you!
Ivan

This doesn’t appear to be part of Asterisk.

I did next:

amportal admin auth_none

and after that I was able to connect to FreePBX. I implemented all config files via Free PBX and I got
chan_sip.c:4181 __sip_reliable_xmit: Serious Network Trouble; __sip_xmit returns error for pkt data

As far as I understand the problem in config files? I tried to check network traffic, because this is “serious network problem”. Routing, firewall - OK. nmap could reach gateway of provider. where I can have problem?

I have an empty sip.conf but have sip_additional.conf where I have next:

[100]
deny=0.0.0.0/0.0.0.0
secret=secret123
dtmfmode=rfc2833
canreinvite=no
context=from-internal
host=dynamic
trustrpid=yes
mediaencryption=no
sendrpid=no
type=friend
nat=no
port=5060
qualify=yes
qualifyfreq=60
transport=udp,tcp,tls
avpf=no
force_avp=no
icesupport=no
encryption=no
callgroup=1
pickupgroup=1
dial=SIP/100
mailbox=100@default
permit=0.0.0.0/0.0.0.0
callerid=First <100>
callcounter=yes
faxdetect=no

[101]
deny=0.0.0.0/0.0.0.0
secret=secret123
dtmfmode=rfc2833
canreinvite=no
context=from-internal
host=dynamic
trustrpid=yes
mediaencryption=no
sendrpid=no
type=friend
nat=no
port=5060
qualify=yes
qualifyfreq=60
transport=udp,tcp,tls
avpf=no
force_avp=no
icesupport=no
encryption=no
callgroup=1
pickupgroup=1
dial=SIP/101
permit=0.0.0.0/0.0.0.0
callerid=Second <101>
callcounter=yes

[TPG]
disallow=all
host=111.10.9.8
type=friend
port=5060
insecure=invite,port
allow=alaw
context=from-trunk
qualify=yes
directmedia=no

Could you tell me, please, where I have problem?

Thank you

FreePBX peer support is provided on http://community.freepbx.org/

1 Like