> But what I wanted to do is:
>
> MySQL 4.0 -> 192.168.0.32 and 127.0.0.1
> MySQL 5.0 -> 192.168.0.33
I'm going to assume you are using some kind of Unix-like platform. When
you connect to localhost, you are actually connecting by default through
a Unix socket file, not TCP/IP, because it is much faster. Thus it is
perfectly possible to do what you outline without having to specify
multiple IPs in the bind-address option. External connections will use
TCP/IP, internal will use a unix socket file.
If you wanted to use -only- the unix socket file to connect to a
particular instance, thus completely disallowing external connections,
you can use the skip-networking option.
I think the clearest description of this is actually:
http://dev.mysql.com/doc/refman/5.0/en/can-not-connect-to-server.html
As you can see, the same concept works on Windows, except through named
pipes.
To verify what type of connection you are using, use the status command.
You'll see a line like:
Connection: Localhost via UNIX socket
-or-
Connection: <somehostname> via TCP/IP
> Or is there another way to only allow certain users to connect from
> localhost?
Of course. Grant privileges only to connect to localhost. See
http://dev.mysql.com/doc/refman/5.0/en/user-account-management.html
Or use skip-networking to turn off TCP/IP for that instance.
> As I think about it, a local TCP forwarder would accept connections on
> localhost, but MySQL won't see that, so this wouldn't work anyway.
Completely unnecessary! You are far better off simply using the default
behaviour of connecting through a socket, not TCP/IP, when connecting
from the same machine.
What you are wanting to do is not that unusual, and I'm confident you'll
find there are ample options to get the setup that works best for you. I
strongly suggest you read up in the manual on how MySQL handles TCP/IP
and local connections.
Eric
--
Eric Braswell
Web Manager MySQL AB
Cupertino, USA
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]