Tomazi
Tomazi

Reputation: 847

Mysql Flush Host will it delete my data in tables...?

I am trying to connect to my DB on a server with Workbench, it took my a while to learn how to connect through workbench and in a process I blocked because of many connection errors.

I have learned through google and Mysql Documentation Documentation that i need to flash host to unblock the connection chanel

FLUSH HOSTS

I was trying to find out if that command will in any way affect data held in my DB, if it i will remove all the data in tables or remove users from table...?

Am I safe to run this command without emptying my tables...?

Upvotes: 2

Views: 1861

Answers (1)

Rahul
Rahul

Reputation: 77906

Yes, I believe so. Excerpt from Documentation

HOSTS

Empties the host cache. You should flush the host cache if some of your hosts change IP address or if the error message Host 'host_name' is blocked occurs. (See Section B.5.2.6, “Host 'host_name' is blocked”.) When more than max_connect_errors errors occur successively for a given host while connecting to the MySQL server, MySQL assumes that something is wrong and blocks the host from further connection requests. Flushing the host cache enables further connection attempts from the host.

It clearly says that, it clears the host cache and not data stored in user/system database. So, running it should be fine/safe I believe.

Upvotes: 2

Related Questions