New IP for access_host in mysql.conf how sync to remote database?

defomaz

Verified User
Joined
Jun 26, 2008
Messages
130
Halo,

I use separated database for our directadmin server.

first time I use just single ip block

user=da_admin
passwd=xxxx

access_host=xx.32.%
host=mysql

but Now I need add additional block (access_host1).
user=da_admin
passwd=xxx

access_host=xx.xx.%
access_host1=xx.xx.%
host=mysql

This work for new database, but there is already 100 more database.
How sync new access host ip to old database?


Thank you.
 
Last edited:
Hello,

If you're asking how to edit the mysql.conf file on all servers, setting up ssh rsa keys might make that process faster. There is no DA API to edit the mysql.conf file.
https://help.directadmin.com/item.php?id=516

Once scp is setup, a script could be used to root into each box without using a password, then do a regex or direct copy to adjust the file.

If you're just talking about inserting a new IP for each DB listed in DA, then just use the CMD_API_DATABASE to do that:
https://directadmin.com/features.php?id=503

John
 
Back
Top