Data Preparations
- Deploy MySQL on a physical machine, start it, and log in to the database.
- Assume that the IP address of the MySQL server is 192.168.200.56 and the port is 3306. You need to create three databases dbtest1, dbtest2, and dbtest3, and two tables tb1 and tb2.
- Create dbtest1.
1 2 3
drop database if exists dbtest1; create database dbtest1; use dbtest1;
- Create tb1 on dbtest1.
1 2 3
create table tb1( id int not null, gmt datetime);
- Create dbtest2.
1 2 3
drop database if exists dbtest2; create database dbtest2; use dbtest2;
- Create tb2 on dbtest2.
1 2 3
create table tb2( id int not null, val varchar(256));
- Create dbtest3.
1 2 3
drop database if exists dbtest3; create database dbtest3; use dbtest3;
- Create tb2 on dbtest3.
1 2 3
create table tb2( id int not null, val varchar(256));
- Create dbtest1.
- Log out of the database.
\q
Parent topic: Running Cobar