You can use MySQL's own config edit

Source: Internet
Author: User
Tags chmod

Normally, a generic database password can be written in the user's home directory. MY.CNF then set chmod 600, which is generally more secure.

But if you do not want to give people know the user name and the actual password, but also want to use, you can use the MySQL own config edit.

Mysql_config_editorset--user=root--password

At this time, a user's home directory will appear with an encrypted later. MYLOGIN.CNF, Permissions 600

Direct view will find that the password is encrypted and called:

Mysql_config_editorprint--all

can see summary

Call MySQL directly to password-free login mysql_config_editor settings default server

If you need (2881064151) to set up multiple servers, you can use the--login-path parameter

Mysql_config_editorset--login-path=dev-slave--user=root--password--host=ip-of-server--port=3308

When linking, use the

MySQL--login-path=dev-mysql

This method does not say how safe, mainly after encryption, the naked eye is invisible.

Remember,. my.cnf and. Mylogin.cnf must chmod 600

You can use MySQL's own config edit

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.