Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have got two NICs configured on a VM - each is tied to a specific network, one is a DMZ, the other is an internal network.

I want MySQL to listen on the internal network only and Apache on the DMZ listening for HTTP and HTTPS. But as soon as I add the second interface I run into trouble. I can hit HTTP on either interface, but can not hit 3306 on the internal network for MySQL.

Here's the config... could someone sanity check this please?

auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static

auto eth1
iface eth1 inet static
share|improve this question
can you ping and log in to from the the 'mysql' nic or is it just the mysql port that is closed? If you cannot ping it, I would think about routing problems (solvable adding static routes on the interface without default gateway). Otherwise it could be indeed that the mysql server only listens on the other interface and you should change my.cnf to change it. – natxo asenjo Sep 23 '10 at 18:04

1 Answer 1

Check bind-address in /etc/mysql/my.cnf - it should have the ip address of the internal card instead of the default

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.