Some problems you may encounter when installing MySQL

Some problems you may encounter when installing MySQL

Question 1:

When entering net start mysql during installation, the error message is:

net is not recognized as an internal or external command, operable.

Solution: Environment variable problem:

First, make sure there is net.exe under C:\Windows\System32.

In the following

My Computer –> Properties –> Advanced –> Add the variable value of the environment variable path: %SystemRoot%\system32

Remember here to add, not delete, the previous path environment variable. Be sure to pay attention!

After the modification is completed, you need to reopen the cmd command line, otherwise it will not take effect.

Question 2:

This problem occurs after solving problem one. The system cannot find the specified file.

**Solution:

Enter the specified path of mysql in the CMD administrator. My path here is D:\mysql5.7\mysql-8.0.22-winx64\bin

1. First, enter mysqld --remove in this path and press Enter.

2. Then enter mysqld --install and press Enter.

3. Finally, enter net start mysql and the MySQL server will start.

This will solve the problem

My solution screenshot is as follows:

Question 3:

Password modification problem: After entering mysql, you want to modify the password, you enter the code command:

set password for root@localhost=password('your new password');

At this time, if the following screenshot error occurs:

The password change failed, and there was an error when you showed databases;

**The reason for this is that when you create a new task environment, you must use alter user to change your password.

set password for root@localhost=password('your new password');

This command changes the password incorrectly, resulting in an error. **The solution is as follows:

Correct code command:

ALTER USER USER() IDENTIFIED BY 'your new password';

My modified screenshot is shown below:

These are some of the problems I encountered. After that, you can exit CMD again, re-enter CMD, follow the correct instructions to enter your MySQL database, and start database operations.

If you still don’t understand something, please leave a message. I will continue to pay attention to everyone’s questions, and work together to discover and solve problems. Come on!

Summarize

This is the end of this article about some difficult problems that you may encounter when installing MySQL. For more information about difficult problems in installing MySQL, please search for previous articles on 123WORDPRESS.COM or continue to browse the related articles below. I hope everyone will support 123WORDPRESS.COM in the future!

You may also be interested in:
  • MySQL installation diagram MySQL graphic installation tutorial (detailed instructions)
  • Installation and configuration of MySQL 5.6 under Windows with screenshots and detailed instructions
  • MySQL 5.6 (Win7 64-bit) download, installation and configuration graphic tutorial
  • MySQL 5.5 installation and configuration method graphic tutorial
  • CentOS 6.4 installation and configuration of LAMP server (Apache+PHP5+MySQL)
  • Install Apache and PHP under Linux; Apache+PHP+MySQL configuration strategy
  • Complete steps to install mysql5.7 on Mac (with pictures and text)
  • Graphic tutorial for installing mysql-5.6.4 under Linux
  • Summary of solutions for the problem that MySQL 5 cannot be started after installation (cannot start service)
  • Graphical method for installing Apache+MySQL+PHP operating environment under Windows

<<:  HTML table markup tutorial (15): table title

>>:  Docker build PHP environment tutorial detailed explanation

Recommend

View the frequently used SQL statements in MySQL (detailed explanation)

#mysql -uroot -p Enter password mysql> show fu...

Vue implements start time and end time range query

This article shares with you how to query the sta...

Use button trigger events to achieve background color flashing effect

To achieve the background color flashing effect, j...

jQuery achieves seamless scrolling of tables

This article example shares the specific code of ...

Build a WebRTC video chat in 5 minutes

In the previous article, I introduced the detaile...

Summary of important mysql log files

Author: Ding Yi Source: https://chengxuzhixin.com...

Introduction to NFS service construction under Centos7

Table of contents 1. Server 2. Client 3. Testing ...

Linux operation and maintenance basic swap partition and lvm management tutorial

Table of contents 1. Swap partition SWAP 1.1 Crea...

Implementation of form submission in html

Form submission code 1. Source code analysis <...

Exploring the Linux Kernel: The Secrets of Kconfig

Get a deep understanding of how the Linux configu...

MySQL service and database management

Table of contents 1. Start and stop service instr...

Html makes a simple and beautiful login page

Let’s take a look first. HTML source code: XML/HT...

Using Apache ab to perform http performance testing

Mac comes with Apache environment Open Terminal a...

Alibaba Cloud domain name and IP binding steps and methods

1 Enter the Alibaba Cloud console, find the domai...