Skip to content

RFC 3092

Etymology of "Foo"

  • The RFC 3092
  • Projects
    • avelsieve
    • check_process_runtime
    • CloudPress
  • About

Category: MySQL

Re-Assign Host Access Permission For User In MySQL Foo

Posted on February 26, 2014 by peter

Changing the configuration of a VPN can have interesting side effects. In my case I had to open up the host permissions for my MySQL users and databases from a /24 to a /16 network. Should be easy… and it actually is. Here are the SQL commands you have to execute to perform such an update:


update mysql.user set host = '10.42.%' where host = '10.42.42.%;
update mysql.db set host = '10.42.%' where host = '10.42.42.%;
flush privileges;

You can of course go crazy in the where clause and in- or exclude everything you want.

Happy SQL-ing.

Posted in Foo, Linux, MySQL
Proudly powered by WordPress | Theme: micro, developed by DevriX.