how to export mysql database using command line in ubuntu
how to export mysql database using command line in ubuntu
Learn about how to export mysql database using command line in ubuntu, we have the largest and most updated how to export mysql database using command line in ubuntu information on alibabacloud.com
This article mainly introduces someMySQL databaseOfCommand LineSome Common commands, including starting and stopping services, user logon, user management, and use of commonly used batch processing commands. Let's take a look at them.
Start and Stop
MySql: www.mysql.org
First, start and stop the mysql Service
Net stop mysql
Net start mysql
Second, log on to mysql
Mysql-u user name-p User Password
Mysql-uroot-p. After you press enter, you are prompted to enter the password, enter 12345,
Mysqldump usage database export mysqldump
BitsCN.com
Mysqldump usage database export
The mysqldump client can be used to dump databases or collect databases for backup or transfer data to another SQL Server (not necessarily a MySQL server ). Dump
The example of this article summarizes the various operation commands used by MySQL. Share to everyone for your reference, specific as follows:
MySQL installation directory
Database directory
/var/lib/mysql/
Configuration file
/usr/share/mysql (
When using MySQL DATA, you will always encounter Import and Export situations. Therefore, it is very important to correctly import and export data! The following method is used in the work:
When using MySQL DATA, you will always encounter Import and
MySQL Database Import and Export
When using MySQL DATA, you will always encounter Import and Export situations. Therefore, it is very important to correctly import and export data! The following method is used in the work:
Import:
Import data
MySQL installation directoryDatabase directory:/var/lib/mysql/Configuration file:/usr/share/mysql (mysql.server command and configuration file)Related commands:/usr/bin (mysqladmin mysqldump, etc. order)Startup script:/etc/init.d/mysql (Directory of
Share Mysql commands,
1. Connect to Mysql
Format: mysql-h host address-u user name-p User Password
1. Connect to MYSQL on the local machine.
First, open the DOS window, enter the mysql \ bin directory, type the mysql-u root-p command, and press
To use a database:
Link MySQL server
Select Database
Increase and deletion of data sheets
Close the database
ExitQuitExit\qCommon operations\c Cancel the unfinished operation.\g instead of TerminatorDatabase operations:Show
Some enterprises use the default option when installing MySQL, which leads to data insecurity, and the server also faces the risk of intrusion, and may suffer performance problems in a short time. This article provides the best way to ensure MySQL
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.