Home PC Games Linux Windows Database Network Programming Server Mobile  
           
  Home \ Database \ Ubuntu mysql stop fail to solve the problem     - How to use the Vault secure password storage and API key (Linux)

- CentOS 6.4 install and configure Squid Proxy Server (Linux)

- Linux security-related basics (Linux)

- Depth Java Singleton (Programming)

- Nginx Performance Tuning Guidelines (Server)

- Linux SVN installation and configuration graphic tutorials (Server)

- Linux VMware virtual machine after the cloning of the card can not start to solve (Linux)

- What have we learn from the front-end application Nodejs (Programming)

- Awk include binding capacity larger than the specified size of all files directory (Linux)

- Use rfkill soft-switching and Bluetooth wireless capabilities in Linux (Linux)

- Linux regex sed detailing (Linux)

- MySQL loose index scan (Database)

- Ceph Source Analysis: Network Module (Server)

- Ubuntu 14.04 Configuring cuda-convnet (Linux)

- struts2 completely the wrong way to capture 404 (Programming)

- Java thread pool: ExecutorService, Executors (Programming)

- JIRA 3.6.2 Upgrade from older version to the new version 6.0.8 (Linux)

- Ubuntu How to mount iso file (Linux)

- Ubuntu and Archlinux install Notepadqq 0.50.2 (Linux)

- Linux operating system security tools of the Logs (Linux)

 
         
  Ubuntu mysql stop fail to solve the problem
     
  Add Date : 2018-11-21      
         
         
         
  A recent study MySQL, mysql stop fail encountered a problem where the process of solving the problems encountered and write out, the problem is not how hard, but I did not find the solution to this problem during a line of effective solution to the problem of Chinese web pages, and made a lot of wasted time. Here I write down the settlement process, newcomers hope to solve the same problem to save time. Well, ado, we began to enter the topic.

My operating system environment is Ubuntu 14.04,64 bit MySQL installation process is as follows:



Since the change of MySQL configuration file, you need to restart the MySQL, I'll stop mysql through the following two commands:



Of course, also I tried the Internet said the service mysql stop, then do not use eggs. After searching several times, finally found in an English forum solution. In the layout of the problem, there are many respondents given a "method", is given only one method to solve my problem.

The problem solving process is like this:

1, login as root mysql, execute the following sql statement:

select User from mysql.user

Look in the mysql database user table is not the presence of a file named: debian-sys-maint user, the implementation of the above sql statement returns on my machine results
If your query returns results in the absence of a centralized user debian-sys-maint, then you need to perform the second step, if there is debian-sys-maint user, then you need to perform the third step.

2, the implementation of sql statement: CREATE USER 'debian-sys-maint' @ 'localhost' identified by 'password'

I briefly explain the sql statement: create a debian-sys-maint user called, using the mysql password for the user password, then the value of the password field to specify how we do? You are arbitrarily assigned it? Not worth password fields must be the same file /etc/mysql/debian.cnf the debian-sys-maint password contents /etc/mysql/debian.cnf files on my machine
3, if you perform the second step, then you can successfully stop mysql, the need to perform the third step. The third step of the process as follows:

Value /etc/mysql/debian.cnf the debian-sys-maint first execute the following sql statement to see debian-sys-maint line where the password field corresponding to the password is the same,
Since the mysql password is stored encrypted, so we can not compare the two passwords, because we need two passwords are consistent, so execute the following sql statement:

update user set password = PASSWORD ( "password from /etc/mysql/debian.cnf") where User = 'debian-sys-maint'

Here is the password from /etc/mysql/debian.cnf /etc/mysql/debian.cnf file debian-sys-maint corresponding password, you make no mistake.

So that we can successfully stop mysql up.
     
         
         
         
  More:      
 
- React Native (Programming)
- VNC configuration detailed analysis under Linux (Linux)
- Try to use Lets Encrypt (Linux)
- How to Install Telegram instant messaging software on Ubuntu (Linux)
- Help you make Git Bisect (Linux)
- VMware Workstation virtual machine cloning (Linux)
- Linux iptables: basic principles and rules (Linux)
- Ubuntu 14.04 Docker installation (Linux)
- To build a private Docker registry (Server)
- CentOS 6.7 install Nagios Tutorials (Server)
- CentOS 6.6 install rsync server (Server)
- Linux Shell Scripting Interview Question (Linux)
- Analyzing Linux server architecture is 32-bit / 64-bit (Server)
- CentOS 7 open ports (Linux)
- 3 ways to create a lightweight, durable system of Ubuntu Linux USB disk (Linux)
- Windows 7 hard disk installation notes Debian (Linux)
- Use install_updates upgrade GAMIT / GLOBK (Linux)
- To use iostat display I / O status under Linux (Linux)
- Linux LVM - File system extension (Linux)
- zBackup: A versatile tool to remove duplicate backup (Linux)
     
           
     
  CopyRight 2002-2022 newfreesoft.com, All Rights Reserved.