In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces the method of Mysql setting user-specified ip address to operate the database, the article is very detailed, has a certain reference value, interested friends must read it!
Mysql sets the way for the user to specify the ip address to operate the database: use the grant function with the syntax [grant priv_type on mysql.user to 'user'@'host' identified by' password' with].
Mysql sets the method for the user to specify the ip address to operate the database:
Syntax:
Grant priv_type on mysql.user to 'user'@'host' identified by' password' with grant option
Priv_type: represents the permission to operate the database
User: represents the database user name
Host: represents the IP address
Password: represents the password set
Refresh user permission table: flush privileges
III. Cases
1. Set all databases, all tables and any ip to connect to the database, authorize the user name ping and set the password to 123456
Grant all on *. * to 'ping'@'%' identified by' 123456
2. The record modification permission of the authorization table cloud gives the connection ip the address 192.168.100.1, the user name ping and the password 123456.
Grant update (name,sex) on cloud to 'ping'@'192.168.100.1' identified by' 123456
4. View database permissions table
Mysql > select * from mysql.user where host='localhost'\ G * * 1. Row * * Host: localhost User: Password: Select_priv: n Insert_priv: n Update_priv: n Delete_ Priv: NCreate_ priv: N Drop_priv: N Reload_priv: N Shutdown_priv: N Process_priv: N File_priv: N Grant_priv: N References_priv: N Index_priv: N Alter_priv: N Show_db_priv: N Super_priv: NCreate_tmp_table _ priv: N Lock_tables_priv: N Execute_priv: N Repl_slave_priv: N Repl_client_priv: N Create_view_priv: N Show_view_priv: N Create_routine_priv: N Alter_routine_priv: N Create_user_priv: N Event_priv: N Trigger_priv: N ssl_type: ssl_cipher : x509_issuer: x509_subject: max_questions: 0 max_updates: 0 max_connections: 0 max_user_connections: 0 is all the contents of the method that Mysql sets the user to specify the ip address to operate the database Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.