Solved

MySQL Connection through a SmoothWall Firewall

Posted on 2004-09-30
4
363 Views
Last Modified: 2006-11-17
Hello Experts,
I have opened a port on our SmoothWall firewall to connect to a MySQL box from outside of the firewall.
When the expected IP address comes in the firewall forwards it to the MySQL box.
I keep getting a unable to connect error.  I am using PHP and here is my code

$hostname = "firewall IP address";
$username = "username";
$database_CAB = "database";
$password_CAB = "password";
$CON = mysql_pconnect($hostname, $username, $password) or trigger_error(mysql_error(),E_USER_ERROR);
mysql_select_db($database, $CON);

If I need to post this in another section like PHP or Firewall, please let me know.
Any help would be greatly appreciated.
Thanks
Chad
0
Comment
Question by:ChadMarsh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 13

Accepted Solution

by:
cLFlaVA earned 500 total points
ID: 12191954
are you declaring the server/port like this:

    $hostname = "servername:port";
0
 
LVL 2

Author Comment

by:ChadMarsh
ID: 12191984
Thank you..Always something simple.
0
 
LVL 13

Expert Comment

by:cLFlaVA
ID: 12192053
lol - glad to help, I originally avoided this question because the title scared me.  Next time dumb it down a bit :)

Maybe something like "I can't get a connection".
0
 
LVL 2

Author Comment

by:ChadMarsh
ID: 12192069
OK thanks for the tip.
0

Featured Post

Guide to Performance: Optimization & Monitoring

Nowadays, monitoring is a mixture of tools, systems, and codes—making it a very complex process. And with this complexity, comes variables for failure. Get DZone’s new Guide to Performance to learn how to proactively find these variables and solve them before a disruption occurs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction In this article, I will by showing a nice little trick for MySQL similar to that of my previous EE Article for SQLite (http://www.sqlite.org/), A SQLite Tidbit: Quick Numbers Table Generation (http://www.experts-exchange.com/A_3570.htm…
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question