From owner-freebsd-hackers@FreeBSD.ORG Mon Feb 21 09:52:18 2005 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 98FA016A4CE for ; Mon, 21 Feb 2005 09:52:18 +0000 (GMT) Received: from marlena.vvi.at (marlena.vvi.at [208.252.225.59]) by mx1.FreeBSD.org (Postfix) with ESMTP id 59BD443D46 for ; Mon, 21 Feb 2005 09:52:18 +0000 (GMT) (envelope-from www@marlena.vvi.at) Received: from marlena.vvi.at (localhost.marlena.vvi.at [127.0.0.1]) by marlena.vvi.at (8.12.10/8.12.9) with ESMTP id j1KDuroH034496; Sun, 20 Feb 2005 05:56:54 -0800 (PST) (envelope-from www@marlena.vvi.at) Received: (from www@localhost) by marlena.vvi.at (8.12.10/8.12.10/Submit) id j1KDul36034495; Sun, 20 Feb 2005 05:56:47 -0800 (PST) (envelope-from www) Date: Sun, 20 Feb 2005 05:56:47 -0800 (PST) Message-Id: <200502201356.j1KDul36034495@marlena.vvi.at> To: mhersant@comcast.net From: "ALeine" cc: freebsd-hackers@freebsd.org Subject: Re: remote connection to mysql X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Feb 2005 09:52:18 -0000 mhersant@comcast.net wrote: > use DBI; > > my $dbh = DBI->connect( > 'dbi:mysql:database@host.org:3306', > 'user', 'passwd', { > RaiseError => 1, AutoCommit => 1 > } > ); > > Yet I continue to receive connection errors. Can't connect to > the MySQL server on 3306 (10061). I'v verified that the server is > listening on the port. I also found some info on google about > Perl DBD::mysql problems. I tried resetting the user's password > with the OLD_PASSWORD option. Nothing works. Can anyone help??? Error code 10061 = connection refused. Are you sure there is no firewall in place blocking access to port 3306? Can you telnet to host.org 3306? If so, you might want to try changing your script like this: use DBI; my $dbh = DBI->connect( 'dbi:mysql:database=;host=;port=3306', 'user', 'passwd', { RaiseError => 1, AutoCommit => 1 } ); Otherwise if you are running 4.10 you might want to use sysctl to set net.inet.ip.portrange.randomized to 0. Use may also want to use sockstat to make sure your script is actually trying to connect to the right IP. ALeine ___________________________________________________________________ WebMail FREE http://mail.austrosearch.net