Home > Database > Mysql Tutorial > Starting and stopping the MySQL server

Starting and stopping the MySQL server

WBOY
Release: 2023-09-04 21:01:02
forward
1002 people have browsed it

启动和停止 MySQL 服务器

Let us know how to start and stop MySQL server on Linux and Windows -

Linux – Starting and Stopping Server

in Linux On, starting and stopping can be done from the command line as follows -

/etc/init.d/mysqld start
/etc/init.d/mysqld stop
Copy after login

/etc/init.d/mysqld restart
Copy after login

Linux – Service Command

Some Linux types also Provide service command -

service mysqld start
Copy after login

##

service mysqld stop

Copy after login
service mysqld restart
Copy after login

(or)

service mysql start
Copy after login

##
service mysql stop
Copy after login

service mysql restart
Copy after login

Windows – Starting and Stopping Server

Let’s learn how to do this on Windows –

    Open the Run window Enter "services.msc" using Win key R
  • Now search for the MySQL service installed based on the version.
  • Click the Stop, Start or Restart service option.
  • Otherwise, users can start/stop MySQL from the command prompt. It can be done as follows -
C:\> "C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqld"
Copy after login

C:\> "C:\Program Files\MySQL\MySQL Server 8.0\bin\mysqladmin" −u root shutdown
Copy after login

The above is the detailed content of Starting and stopping the MySQL server. For more information, please follow other related articles on the PHP Chinese website!

source:tutorialspoint.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template