Step3: Install and Build MySQL

Last updated: 2019-12-03 18:06:32


This document uses Windows Server 2012 R2 as an example to introduce how to build MySQL 5.5.

SQL Server database is frequently used in Windows system. You need to grand authorization for SQL Server because it is not for free. You can also purchase CDB instances for Tencent Cloud SQLServer database.

Step 1: Download MySQL installer

   Open the browser on the CVM and enter the download URL:

Step 2: Install the application

  1. Run the installation program. Click Next and select I accept the terms in the License Agreement.

  2. Select Typical in Choose Setup Type.

  3. Select Launch the MySQL Instance Configuration Wizard.

Step 3: Configure MySQL

  1. Configure the type of MySQL. Here we use Detailed Configuration as an example.

    • Detailed Configuration is suitable for advanced users that need to have finer control of the CVM configurations.
    • Standard Configuration is suitable for new users that want to launch MySQL quickly without considering the CVM configurations.

    Standard Configuration may be incompatible with your operating system. Detailed Configuration is recommended.

  2. Configure the type of MySQL server. Here we use Developer Machine as an example.

    • Developer Machine represents a typical personal desktop workstation. When multiple desktop applications are running at the same time, the MySQL server is configured to use minimal system resources.
    • Server Machine is a type of server on which MySQL server can run with other applications such as FTP, email and Web servers. The MySQL server is configured to use a moderate portion of the system resources.
    • Dedicated MySQL Server Machine is a type of server on which only MySQL server can run. The MySQL server is configured to use all available system resources.

  3. Configure MySQL database. Here we use Multifunctional Database as an example.

    • Multifunctional Database uses InnoDB and MyISAM storage engines simultaneously, and allocates resources to them equally. You are recommended to select this option if you often use two storage engines simultaneously.
    • Transactional Database Only uses InnoDB and MyISAM storage engines simultaneously, and allocates most server resources to InnoDB storage engine. You are recommended to select this option if you use InnoDB frequently and use MyISAM occasionally.
    • Non-Transactional Database Only does not use InnoDB storage engine, and allocates all server resources to MyISAM storage engine. You are recommended to select this option if you do not use InnoDB.

  4. Configure the InnoDB tablespace for MySQL. Choose default configuration here.

  5. Configure concurrent connection for MySQL. Here we use Decision Support as an example.

    • Decision Support is suitable for situations that do not require a large number of concurrent connections.
    • Online Transaction Processing is suitable when a large number of concurrent connections are required.
    • Manual Setting is suitable when you need to configure the maximum number of concurrent connections manually.

  6. Configure the network options of MySQL. You can enable or disable TCP/IP network and configure the port number for MySQL server connection.

    TCP/IP network is enabled by default.
    Port 3306 is used by default.

  7. Configure MySQL character set. Here we use Standard Character Set as an example.

    • Standard Character Set uses Latin1 as the default server character set.
    • Best Support For Multilingualism uses UTF8 as the server character set.
    • For Manual Selected Default Character Set/Collation, select the character set in the drop-down box as needed.

  8. Configure the service options of MySQL. It is recommended to select both boxes to manage MySQL using command line.

  9. Set the root password.

  10. Complete the configuration. Click Execute to complete the installation.

Step 4: Login Test for MySQL

  1. Click Start on the CVM and click the search icon. Enter cmd to open the administrator command box:

  2. Enter the command mysql -u root -p and press Enter.

  3. Log in to MySQL using the root password you set. The picture below indicates that MySQL has been installed and configured successfully.