Multiple server Connection Problem

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Multiple server Connection Problem

Postby xxttxxtt » Wed Aug 02, 2006 2:51 pm

Hi, first off I would like to thank you guys for the great help you guys give.

I have a seperate mysql/php setup and a asterisk/vicidial. I been getting connection problems. Dont know wheres it coming from.

New mail for root@VICI has arrived:
----
From: root@VICI.dhol.com
Subject: cron: /home/cron/AST_conf_update.pl
problem connecting to "67.52.187.22", port 5038: Connection refused at /home/cron/AST_conf_update.pl line 144

----

New mail for root@VICI has arrived:
----
From: root@VICI.dhol.com
Subject: cron: /home/cron/AST_conf_update.pl
problem connecting to "67.52.187.22", port 5038: Connection refused at /home/cron/AST_conf_update.pl line 144

----

New mail for root@VICI has arrived:
----
From: root@VICI.dhol.com
Subject: cron: /home/cron/AST_vm_update.pl
problem connecting to "67.52.187.22", port 5038: Connection refused at /home/cron/AST_vm_update.pl line 144

----

New mail for root@VICI has arrived:
----
From: root@VICI.dhol.com
Subject: cron: /home/cron/AST_vm_update.pl
problem connecting to "67.52.187.22", port 5038: Connection refused at /home/cron/AST_vm_update.pl line 144

This is what I get on the screen of asterisk/vicidial server.
Please help I been working on this for days now. Thanks
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby mflorell » Wed Aug 02, 2006 3:07 pm

check that your manager.conf is enabled and that the entries are in it as per the SCRATCH_INSTALL.

Check that your AST_SERVER_conf.pl server_ip is set correctly and matches the servers table entry.
mflorell
Site Admin
 
Posts: 18338
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby xxttxxtt » Wed Aug 02, 2006 3:54 pm

This is what my manager.conf reads:

[general]
enabled = yes
port = 5038
bindaddr = 0.0.0.0
[cron]
secret = 1234
read = system,call,log,verbose,command,agent,user
write = system,call,log,verbose,command,agent,user
[updatecron]
secret = 1234
read = command
write = command
[listencron]
secret = 1234
read = system,call,log,verbose,command,agent,user
write = command
[sendcron]
secret = 1234
read = command
write = system,call,log,verbose,command,agent,user


this is AST_SERVER_conf.pl:: IP hidden for security reasons

#!/usr/bin/perl

# AST_SERVER_conf.pl
#
# Copyright (C) 2006 Matt Florell <vicidial@gmail.com> LICENSE: GPLv2
#

# Customized Variables
$server_ip = '**.52.187.yy'; # Asterisk server IP
$DB_server = '**.52.187.xx'; # MySQL server IP
$DB_database = 'asterisk'; # MySQL database name
$DB_user = 'cron'; # MySQL user
$DB_pass = '1234'; # MySQL pass
$DB_port = '3306'; # MySQL connection port

$LOGfile = '/home/cron/LOG_AST_update.log';
$telnetlog = '/home/cron/telnetlog.log';
$MSLOGfile = '/home/cron/MSLOG_AST_update.log';
$MStelnetlog = '/home/cron/MStelnetlog.log';
$LILOGfile = '/home/cron/LILOG_AST_update.log';
$LItelnetlog = '/home/cron/LItelnetlog.log';
$KHLOGfile = '/home/cron/KHLOG_AST_update.log';
$VDADLOGfile = '/home/cron/VDLOG_AST_update.log';

return 1;
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby marvin » Wed Aug 02, 2006 4:14 pm

try explicitly adding


[general]
enabled = yes
port = 5038
bindaddr = 0.0.0.0
permit=<mysql-php IP>/ <mysql-php subnet>
marvin
 
Posts: 69
Joined: Wed Jun 21, 2006 1:35 am
Location: Cebu, Philippines

Postby xxttxxtt » Wed Aug 02, 2006 4:29 pm

Didnt work im getting :


Connected to Asterisk 1.2.10 currently running on VICI (pid = 2268)
Verbosity is at least 21
-- Remote UNIX connection
VICI*CLI>
New mail for root@VICI has arrived:
----
From: root@VICI.dhol.com
Subject: cron: /home/cron/AST_vm_update.pl
problem connecting to "67.52.187.22", port 5038: Connection refused at /home/cron/AST_vm_update.pl line 144

----

New mail for root@VICI has arrived:
----
From: root@VICI.dhol.com
Subject: cron: /home/cron/AST_conf_update.pl
problem connecting to "67.52.187.22", port 5038: Connection refused at /home/cron/AST_conf_update.pl line 144

----
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby mflorell » Wed Aug 02, 2006 4:34 pm

Since these are both public IP addresses you don't have them connected through a local LAN on a NAT do you?

Are either of these behind a firewall of any kind?
mflorell
Site Admin
 
Posts: 18338
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby xxttxxtt » Wed Aug 02, 2006 4:43 pm

no theyre not connected behind a firewall.
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby mflorell » Wed Aug 02, 2006 9:43 pm

Please post the results of "ifconfig"

try changing server_ip in all tables and configurations to localhost or 127.0.0.1
mflorell
Site Admin
 
Posts: 18338
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby xxttxxtt » Wed Aug 02, 2006 10:27 pm

ifconfig
eth0 Link encap:Ethernet HWaddr 00:16:EC:9F:75:45
inet addr:67.52.187.25 Bcast:67.52.187.31 Mask:255.255.255.240
inet6 addr: fe80::216:ecff:fe9f:7545/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:122578 errors:0 dropped:0 overruns:0 frame:0
TX packets:168007 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:16948844 (16.1 Mb) TX bytes:21817917 (20.8 Mb)
Interrupt:201

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:9905 errors:0 dropped:0 overruns:0 frame:0
TX packets:9905 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:976288 (953.4 Kb) TX bytes:976288 (953.4 Kb)
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby xxttxxtt » Fri Aug 04, 2006 10:46 pm

this is what i get now

New mail for root@VICI-2 has arrived:
----
From: root@VICI-2.dhol.com
Subject: cron: /home/cron/AST_conf_update.pl
Couldn't connect to 67.52.187.22:3306/tcp: IO::Socket::INET: connect: Connection refused at /home/cron/AST_conf_update.pl line 82

----

New mail for root@VICI-2 has arrived:
----
From: root@VICI-2.dhol.com
Subject: cron: /home/cron/AST_VDhopper.pl -q
Couldn't connect to 67.52.187.22:3306/tcp: IO::Socket::INET: connect: Connection refused at /home/cron/AST_VDhopper.pl line 141




Can Someone explain what is the proper steps to configure this how come its refusing my connection.
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby mflorell » Sat Aug 05, 2006 12:01 am

That means that the script cannot connect to the database. Check that the database is running on that server and that the proper grant priveledges have been set.
mflorell
Site Admin
 
Posts: 18338
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby xxttxxtt » Sat Aug 05, 2006 12:21 am

the only way i can access the database is like this:

/usr/local/mysql/bin/mysql -h 67.52.187.22 -u cron -p asterisk

Will it affect the program
xxttxxtt
 
Posts: 25
Joined: Sun Jul 16, 2006 12:28 am

Postby mflorell » Sat Aug 05, 2006 12:31 am

Do you have your db_user and db_pass set correctly in the AST_SERVER_conf.pl and servers table?
mflorell
Site Admin
 
Posts: 18338
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida


Return to Support

Who is online

Users browsing this forum: Google [Bot] and 68 guests