Delete MySQLsudo apt-get autoremove--purge mysql-server-5.0sudo apt-get remove Mysql-serversudo apt-get autoremove mysql-serversudo apt-get remove Mysql-common//This is importantIn fact, some of the above is superfluous.Clean up residual dataDpkg-l |
View field information for table: DESC table name;
View all information about the table: Show create table table name;
Add PRIMARY KEY constraint: ALTER TABLE name add constraint primary key (Shape: Pk_ table name) primary key table name
MySQL Data backup:1 Data backup method:Way classification:Physical backup: Direct copy of library or corresponding file, file owner/group must be MySQLCp-r/var/lib/mysql Directory/backup file
Mysql> CREATE TABLE tb_test (id int (1) NOT NULL auto_increment primary key,action_id Int (TEN) not Null,error_code int. 0) NOT NULL default 0,desc_key varchar (+) NOT null default ' Audit.log.default ', INDEX (action_id), constraint ' Fk_actionid '
Database version 5.6.16On two servers, there is a database with different names, but all the tables in two databases have the same structure, implementing master-slave replication.The database name for the primary library server is Yoon, and the
there are two in one Taichung MYSQL , the basic one 5.5 ( rpm package) configuration file /etc/my.cnf , not one of the outside 5.6 configuration file /home/app/mysql5.6/my.cnf5.6 Error Reporting2016-01-27 00:09:03 16056 [Note] Innodb:percona XtraDB (
By default, after logging in to MySQL, we can first view system variables through the show variables like commandFor example, we can view the encoding of the database by show VARIABLES like '%character% ' command:We can see that after the
MySQL installation method is not introduced here, there are many tutorials on the internetEnvironment Introduction:A host: win2008_x64+mysql5.7.10 64-bit, ip192.168.7.180B Host: win2008_x64+mysql5.7.10 64-bit, ip192.168.7.1811, first configure the
The following is personal understanding, if there are errors, but also to correct!!Most of MySQL's transactional storage engine is not a simple row-level lock, based on the promotion of concurrency performance considerations, they generally
Generally speaking, the master-slave synchronization is, from the library to the master Library of a location point of backup, and then according to the main library Binlog log and continuously through the increment to perform additions and
1. Integral type
MySQL data type
Meaning (Signed)
tinyint (m)
1 byte range ( -128~127)
smallint (m)
2 byte range ( -32768~32767)
Mediumint (M)
3 byte range ( -8388608~83
Also known as a hash table is improved by direct addressing tables. First look at the direct addressing table the direct addressing is a simple and effective technique when the global U of keywords is compared to the hour. A dynamic collection is
MySQL database password cracking big secretRPM packages are installedRecovery of the database administrator passwordFirst stop the MySQL service,Service MySQL StopService MySQL start--skip-grant-table then start with skip permission mode
1) Reclaim the user's write permissions from the Vault (Update/delete/insert)This method must ensure that the corresponding user on the main library does not change, and if it does change, the user's authorization will be synchronized to the library,
drop database if exists school; Delete if school is presentCREATE DATABASE School; Building a library schoolUse School; Open Library SchoolCREATE TABLE Teacher (//Build tables TeacherID int (3) auto_increment NOT NULL primary key,name Char (TEN) is
The mysqldump command is used to back up the database. The mysqldump command executes under the DOS [Url=file://\\mysql\\bin]\\mysql\\bin[/url] directory. 1) Export the entire database (the export file is present in the Mysql\bin directory by
drop database if exists school; Delete if school is presentCREATE DATABASE School; Building a library schoolUse School; Open Library SchoolCREATE TABLE Teacher (//Build tables TeacherID int (3) auto_increment NOT NULL primary key,name Char (TEN) is
1. Optimize your MySQL query cacheQuerying on the MySQL server enables high-speed query caching. Having the database engine quietly handled in the background is one of the most effective ways to improve performance. When the same query is executed
'The role of this symbol in mysql and the role of mysql
I started to write code yesterday and inserted the data into the mysql database, but I couldn't insert it. I searched online. The final solution was to insert the data in phpmyadmin and
Mycat read/write splitting and Master/Slave Switching
1. Advantages and Disadvantages of database/table sharding and why cannot table sharding become mainstream?Table sharding: it is easy to maintain on a server, similar to Table Partitioning. Its
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service