Win2008 R2 mysql 5.5 zip format mysql installation and configuration

Win2008 R2 mysql 5.5 zip format mysql installation and configuration

Win2008 R2 zip format mysql installation and configuration

1. Download the Baidu MySQL 5.6 ZIP 64-bit free installation version and unzip it to the D drive

Second, you can consider modifying the configuration in my.ini character-set-server=utf8 This sentence is the encoding format setting port=.. Port setting

3. Set the environment variable PATH. Add D:\mysql-5.6.20-winx64\bin to the path.

4. Install MySQL service. Be sure to enter the D:\mysql-5.6.20-winx64\bin directory to execute the installation mysqld install

5. Enter the Service Manager to start the MySQL service

6. Enter the database, change the login password of the root account to 1234, then create a MySQL remote connection user, set the maximum permissions and login password.

mysql -u root -p 
GRANT ALL ON *.* TO 'root'@'localhost' IDENTIFIED BY '1234';
GRANT ALL ON *.* TO 'sa'@'%' IDENTIFIED BY '1234' WITH GRANT OPTION;

7. Open the firewall port 3306 Network->Windows Firewall->Advanced Settings->Inbound Rules Then click New Rule in the upper right corner and select "Port" Next, enter port 3306 and add the rule.

Install mysql5.6 in dual instances in windows2008r2 environment

Environment: Windows 2008 R2 Standard Edition

1. By default, a mysql5.6 port is installed, which is 3306

2. Using the msi file to install requires .net4.0 support. Installing .net4.0 reports an error. You can only download a mysql5.6_x64zip package from the official website to your local computer.

Unzip the zip file to E:\mysql-5.6.34-winx64, rename my-default.ini in this path to my.ini and modify the configuration as follows:

**********************************************************
[mysqld]

loose-default-character-set = utf8
character-set-server = utf8
basedir = "E:/mysql-5.6.34-winx64"
datadir = "E:/mysql-5.6.34-winx64/data"
# Enable port 7306 and definitely don't use 3306 by default
port=7306
default-storage-engine=myisam

sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES

[client]

default-character-set = utf8
**********************************************************

Install mysql
Under the administrator cmd command, enter the cd E:\mysql-5.6.34-winx64\bin directory and run mysqld -install to install

Check in the Service Manager whether it can be restarted normally

Add the mysql command to the environment variable:
;E:\mysql-5.6.34-winx64\bin

Restore database command for non-default port 3306:
mysql -P 7306 -uroot -p yunva2<D:\db_20161109\tbl_user.sql

123WORDPRESS.COM editor adds:

Sometimes, in order to add the my.ini configuration file path to the installation version, you can refer to the following method

Modify the registry

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\MySQL

Find ImagePath

"D:\Program Files\MySQL\MySQL Server 5.5\bin\mysqld" --defaults-file="D:\Program Files\MySQL\MySQL Server 5.5\my.ini" MySQL

mysql changes the data file directory and my.ini location.
Requirement: Change the mysql data file directory and my.ini location.

step:

1. To find the location of my.ini, you can check the corresponding properties->executable file path of the MySQL startup item corresponding to the Windows service to obtain the my.ini path.

"D:\MySQL\MySQL Server 5.5\bin\mysqld" --defaults-file="D:\MySQL Data\my.ini" MySQL55

2. Edit the corresponding datadir in my.ini

Before change: datadir="D:\MySQL Data\data\"

After change: datadir="D:\MySQL Data\MySQL Server 5.5\data\"

3. Reorganize the mysql corresponding data file directory (if not, mysql cannot start normally)

4. Find the registry and modify the defaults-file path associated with the MySQL startup item:

KEY_LOCAL_MACHINE/SYSTEM/Services/MySQL55

After the modification, refresh the Windows service and check the MySQL startup item properties -> executable file path again. The results are as follows:

"D:\MySQL\MySQL Server 5.5\bin\mysqld" --defaults-file="D:\MySQL Data\MySQL Server 5.5\my.ini" MySQL

Make sure to move my.ini to the correct directory.

5. Restart mysql and the configuration is successful.

Solution: The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement

At this time we only need
Flush privileges and it will be OK.
mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)

You may also be interested in:
  • mysql5.7.18.zip Installation-free version configuration tutorial (windows)
  • Installation tutorial of MySQL 5.7.17 zip package version under win10
  • MySQL5.6.31 winx64.zip installation and configuration tutorial
  • Detailed installation steps for MySQL 5.7.17 decompressed version (ZIP version)
  • Detailed tutorial on configuring and installing MySQL 5.7 decompressed version (zip) under Winserver2012
  • MySQL 5.6.14 win32 installation method (zip version)

<<:  How to install lua-nginx-module module in Nginx

>>:  Detailed explanation of common for loop in JavaScript statements

Recommend

7 useful new TypeScript features

Table of contents 1. Optional Chaining 2. Null va...

Centos8 (minimum installation) tutorial on how to install Python3.8+pip

After minimizing the installation of Python8, I i...

Docker builds Redis5.0 and mounts data

Table of contents 1. Simple mounting of persisten...

Select web page drop-down list and div layer covering problem

Questions about select elements in HTML have been...

Mysql method to copy a column of data in one table to a column in another table

mysql copy one table column to another table Some...

MySQL InnoDB tablespace encryption example detailed explanation

Preface Starting from MySQL 5.7.11, MySQL support...

Several commonly used methods for centering CSS boxes (summary)

The first one: Using the CSS position property &l...

Linux View File System Type Example Method

How to check the file system type of a partition ...

How to dynamically add ports to Docker without rebuilding the image

Sometimes you may need to modify or add exposed p...

How to set up the terminal to run applications after Ubuntu starts

1. Enter start in the menu bar and click startup ...

Summary of MySQL database and table sharding

During project development, our database data is ...

XHTML tags should be used properly

<br />In previous tutorials of 123WORDPRESS....