Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Installation/Configuration

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 3rd November 2012, 10:27
simonb simonb is offline
Junior Member
 
Join Date: Aug 2011
Posts: 13
Thanks: 1
Thanked 3 Times in 2 Posts
Default Adding remote access to a MySQL database does nothing

(ISPConfig Version: 3.0.4.6 on Ubuntu 10.04)

I need to make a MySQL database accessible to a remote server on the LAN. ISPConfig is running on 192.168.108.129.

I check the "Remote Access" checkbox and enter the IP of the remote server, 192.168.108.140, in the "Remote Access IP" textbox.

I set the bind address in /etc/mysql/my.cnf
Code:
bind-address            = 0.0.0.0
I open port 3306 on the firewall for the remote server. Port 3306 appears open if I test it with nmap on the remote server. So far so good.

However I can't access the database from the remote server.
Code:
mysql -h 192.168.108.129 c3songs -u c3songs -p 
Enter password: 
ERROR 1130 (HY000): Host '192.168.108.140' is not allowed to connect to this MySQL server
If I log into mysql as root on the ISPConfig server then there doesn't appear to be a c3songs user created for the 192.168.108.140 address.

Code:
mysql> select Host,User from mysql.user;
+--------------------+------------------+
| Host               | User             |
+--------------------+------------------+
| 127.0.0.1          | root             |
| ispconfig.example.com | root             |
...(abbreviated, other users listed here)
| localhost          | c3songs          |
... (abbreviated, other users listed here)
| localhost          | ispconfig        |
| localhost          | root             |
+--------------------+------------------+
19 rows in set (0.00 sec)
Is ISPConfig doing anything to enable remote access? I can't see any evidence of it in the database unless I am missing something.

If I set the logging level to debug and run server.sh at the command line I see the following related output when I enable external dB access...

Code:
03.11.2012-09:35 - DEBUG - Found 1 changes, starting update process.
/usr/bin/fail2ban-client
/sbin/iptables
/sbin/ip6tables
03.11.2012-09:35 - DEBUG - Calling function 'db_update' from plugin 'mysql_clientdb_plugin' raised by event 'database_update'.
03.11.2012-09:35 - DEBUG - Changing MySQL remote access privileges for database: c3songs
03.11.2012-09:35 - DEBUG - Processed datalog_id 254
If I add permissions manually then I can access the database from the remote server. But shouldn't ISPConfig be doing that for me?

This works...
Code:
GRANT ALL PRIVILEGES ON c3songs.* To 'c3songs'@'192.168.108.140' IDENTIFIED BY '*****';

Last edited by simonb; 3rd November 2012 at 10:54.
Reply With Quote
Sponsored Links
  #2  
Old 4th November 2012, 14:18
till till is online now
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,446
Thanks: 813
Thanked 5,213 Times in 4,088 Posts
Default

Most likely the mysql root password has been changed in mysql without changing it in ispconfig so that ispconfig is not able to alter the mysql user. Check that the mysql root password is correct in the file /usr/local/ispconfig/server/lib/mysql_clientdb.conf
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 4th November 2012, 14:23
simonb simonb is offline
Junior Member
 
Join Date: Aug 2011
Posts: 13
Thanks: 1
Thanked 3 Times in 2 Posts
 
Default

Quote:
Originally Posted by till View Post
Most likely the mysql root password has been changed in mysql without changing it in ispconfig so that ispconfig is not able to alter the mysql user. Check that the mysql root password is correct in the file /usr/local/ispconfig/server/lib/mysql_clientdb.conf
Hi Till,

I just checked the root password in the mysql_clientdb.conf with "mysql -u root -p" and it logged in fine. I haven't changed the mysql root password since installing ispconfig.

Thanks,
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ISPConfig 3 system installation script Mark_NL Tips/Tricks/Mods 12 7th March 2014 06:30
Can't login (w/ remote MySQL) menganito Installation/Configuration 3 16th May 2011 15:43
Strato Server - Restoring with SystemImager popper2001 HOWTO-Related Questions 5 28th July 2007 10:18
Support Ticket and MySQL Remote Access Question lewis_saint Installation/Configuration 3 20th May 2007 23:56
Creating image with Systemimager cuongtim HOWTO-Related Questions 3 18th November 2006 13:55


All times are GMT +2. The time now is 19:06.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.