Dual MySQL environment under MAC Environment Unified and CentOS under MySQL forgot password processing

Source: Internet
Author: User

/1 "Mac system local MySQL comes with the environment

A. The MySQL command could not be found at first because the MySQL soft connection

Default installation directory/usr/local

MySQL (purple) is a shortcut to mysql-5.7.18-macos10.12-x86_64

Create soft Connect ln-s mysql-5.7.18-macos10.12-x86_64 MySQL (:-S software soft)

Remove soft connection rm-rf MySQL ( delete all files in current directory )

Soft Links:

1. Soft links, in the form of a path exists. Similar to shortcuts in the Windows operating system
2. Soft links can cross file system, hard links can not
3. Soft links can link to a nonexistent file name
4. Soft links can be linked to the directory

Hard Links:

1. Hard link, in the form of a copy of the file. But does not occupy the actual space.
2. Do not allow the creation of hard links to the directory
3. Hard links can only be created in the same file system

2. Turn off MySQL on the MAC system itself

If you report this mistake,

$mysql-U root-p

Enter Password:

ERROR 2002 (HY000): Can ' t connect to local MySQL server through socket '/tmp/mysql.sock ' (2)

Just didn't turn on MySQL.

2 "

Dual MySQL environment under MAC Environment Unified and CentOS under MySQL forgot password processing

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.