Required parameter for mysqldump dumping
BitsCN.com
Required and optional parameters for mysqldump dumping
Required parameters for mysqldump dumping:
E.g.
C:/Documents and Settings/zhuolangkeji> mysqldump-uxxxx-pxxx-h 172.26.3.109-P 3306-c-e-B task> c:/task. SQL
-- User,-u
Specify the connection user name.
-- Port,-P
Database connection port number
-- Password,-p
Database connection password
-- Host,-h
Host Information to be exported
Mysqldump-uroot-p -- host = localhost -- all-databases
-- Add-drop-database
Add the drop database statement before each database is created.
Mysqldump-uroot-p -- all-databases -- add-drop-database
-- Complete-insert,-c
Use the complete insert statement (including the column name ). This can improve the insertion efficiency, but may be affected by the max_allowed_packet parameter, resulting in insertion failure.
Mysqldump-uroot-p -- all-databases -- complete-insert
-- Extended-insert,-e
Use the INSERT syntax with multiple VALUES columns. In this way, the exported file is smaller and the import speed is accelerated. Enabled by default
Mysqldump-uroot-p -- all-databases
Mysqldump-uroot-p -- all-databases -- skip-extended-insert (cancel option)
-- Databases,-B
Export several databases. All name parameters following the parameter are considered as the database name.
Mysqldump-uroot-p -- databases test mysql
--------------------
Non-essential parameters for mysqldump dumping:
-- Max_allowed_packet
The maximum length of packets sent and received by the server.
Mysqldump-uroot-p -- host = localhost -- all-databases -- max_allowed_packet = 10240
-- Net_buffer_length
The cache size of TCP/IP and socket connections.
Mysqldump-uroot-p -- host = localhost -- all-databases -- net_buffer_length = 1024
-- No-data,-d
Only the database table structure is exported without exporting any data.
Mysqldump-uroot-p -- host = localhost -- all-databases -- no-data
BitsCN.com