进入MySQL控制台。
# cd /opt/mysql/bin
#mysql -uroot -p
按照提示信息输入待连接的MySQL服务器的数据库root用户的密码:
Enter Password:
登录成功后系统显示如下类似信息:
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 4381
Server version: 5.7.24-enterprise-commercial-advanced MySQL Enterprise Server - Advanced Edition (Commercial)
Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql>