Start MySQL through the command line

Source: Internet
Author: User

1) install MySQL Server> mysqld-install
2) Start the MySQL Server> Net start MySQL
3) connect to MySQL> mysql-H localhost-u root-P
Enter Password: biao12
4) use the query statement
Mysql> select version (), current_date ();

5) Open the Data command> Use Database mydb; // The semicolon ";" cannot be omitted.


How to remove MySQL from system error 1067


1. Correct the MySQL path in the Windows directory (Win2000 is WINNT). The default value is C:/MySQL. If the file does not exist, manually create it.

[Mysqld]
# Set basedir to your installation path
Basedir = D:/MySQL
# Set datadir to the *** of your data directory
Datadir = D:/MySQL/Data
[Winmysqladmin]
Server = D: // MySQL/bin/mysqld-nt.exe

2. Start the service again.
D:/www/MySQL/bin> Net start MySQL
If:
MySQL service is starting
MySQL service started successfully
As shown in the prompt, the service is successfully started.

3. Now you can test whether MySQL works properly. Run the following command:
D:/www/MySQL/bin> mysqlshow
D:/www/MySQL/bin> mysqlshow-u root MySQL
D:/www/MySQL/bin> mysqladmin version status proc
D:/www/MySQL/bin> mysqladmin-u root Shutdown
(After this statement is run, the MySQL service is closed. After the service is started again, MySQL can be used)

4. The default username is root and the password is blank. For more information about how to correct the MySQL user name and password, see MySQL.
PS: from the Internet

 

Related Article

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.