When migrating a MySQL database, you sometimes need to migrate the users and permissions in the source database. For this migration, we can obtain user-related information from the mysql. user table.
When migrating a MySQL database, you sometimes
1. commands for starting MySql in Linux:Mysqladmin start/ECT/init. d/MySQL start (the installation path of MySQL is earlier)
2. Command for restarting MySql in Linux:Mysqladmin restart/ECT/init. d/MySQL restart (the installation path of MySQL is
Oracle SecureFiles was introduced in Oracle 11g. It has some advantages that traditional large objects (which have been renamed BasicFile LOB) do not have. Oracle SecureFile LOB supports Smart Data Compression. It is a deduplication method that
First you need to download: mysql-connector-odbc-3.51.25-0.i386.rpm this is the client tool for connecting to mysql mysql-5.0.45.tar.gz Mysql database. Download as follows:
Wget http://tlbb-server-make.googlecode.com/files/mysql-5.0.45.tar.gz
Install MySQL1. Download the MySQL Installation FileThe following two files are required to install MYSQL:
MySQL-server-5.1.7-0.i386.rpm To: http://dev.mysql.com/downloads/mysql/5.1.html, open this webpage and click"Linux x86 generic RPM
Install MySQL1. Download the MySQL Installation FileThe following two files are required to install MYSQL:MySQL-server-5.1.7-0.i386.rpm
To download the above two RPM files, locate the "server" and "client programs" items and find the items
Experimental Environment] platform centos6.4IP allocation 192.168.30.101 node1 mysql-proxy192.168.30.102 node2 mysql master node 192.168.30.103 node3 mysql slave Node
192.168.30.104 node4 client
Note:1. mysql5.52 has been compiled and installed on
Install and configure mariadb in centos7, centos7mariadb
Open hosts
Http://mirrors.aliyun.com/mariadb/yum/10.3/centos7-amd64/
Create a daily vip and qq1100009519 for The Source thunder instance, and access 58jiasu.com through the vpn for
Create user [username] identified by [Password] Create a new user
Grant permission 1. Permission 2... to grant the user the permission to create a user
Ex: grant create session to [username] at this time, you can only connect to the database
MySQL tutorial add a remote user or allow remote access to three ways
Log in with the root user, and then:
Grant all privileges the username @ "%" identified by "password" *.* to create;
Flush privileges; * Refresh the content just now *
Format:
MySQL defaults to only local logins, and the following actions allow users to have remote permissions, taking root as an example.
in command state
First, allow users to log on at any IP, and have all the permissions of all databases:
Grant all
First, the MySQL user's basic description:
1.1 Basic structure of the userUsers of MySQL: User name @ host
Username: within 16 charactersHost: Can be host name, IP address, network address, etc.Host Name: Www.111cn.net,localhost
ip:192.168.0.1
Add user
Native access Permissions:mysql> GRANT all privileges on *.* to ' username' @ ' localhost '
-> identified by ' password ' with GRANT OPTION;Remote access permission:mysql> GRANT all privileges in *.* to ' username ' @ '% '
-> identified
1. Grant statement
Format: Grant Select on database. * To User name @ login host identified by "password"
Description
(1) Grant all grants all permissions
(2) All tables in the Demo.* database demo
(3) NewUser user name
(4) @localhost MySQL
When migrating to MySQL databases, it is sometimes necessary to migrate users and permissions within the source database. For this migration we can get the user's relevant permissions from the Mysql.user table to generate the corresponding SQL
1, start mariadb
Install complete mariadb, start mariadb First, two commands can be
Systemctl Start mariadb
Or
Service MARIADB Start
Setting up Boot
Systemctl Enable MARIADB
Or:
Chkconfig mariadb on
2, the next MARIADB related to the simple
MySQL installed after good, there will be a database named MySQL, the user's table is user,mysql database user management is around this table, of course, there are some tables, such as: Tables_priv,procs_priv,clumns_priv, INFORMATION_SCHEMA
Copy Code code as follows:
# VI Mysqlusers.txt
Create Database Dataname;
Grant all privileges on dataname.* to username@localhost identified by ' password ';
Flush privileges;
#/usr/local/mysql/bin/mysql-u root-p Password
1. The system defaults to several users:
sys--– Network management user with the highest database administration privileges
system--Local Admin user with permissions secondary to SYS
Scott ——-a normal user and is locked (not available) by default
By
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.