2.3.3.1 MySQL Installer Initial SetupMySQL安装程序初始设置

When you download MySQL Installer for the first time, a setup wizard guides you through the initial installation of MySQL products.当您第一次下载MySQL安装程序时,安装向导会引导您完成MySQL产品的初始安装。As the following figure shows, the initial setup is a one-time activity in the overall process.如下图所示,初始设置是整个过程中的一次性活动。MySQL Installer detects existing MySQL products installed on the host during its initial setup and adds them to the list of products to be managed.MySQL安装程序在初始设置期间检测主机上安装的现有MySQL产品,并将它们添加到要管理的产品列表中。

Figure 2.7 MySQL Installer Process OverviewMySQL安装程序进程概述

MySQL Installer process. Non-repeating steps: download MySQL Installer; perform the initial setup. Repeating steps: install products (download products, run .msi files, configuration, and install complete); manage products and update the MySQL Installer catalog.

MySQL Installer extracts configuration files (described later) to the hard drive of the host during the initial setup. Although MySQL Installer is a 32-bit application, it can install both 32-bit and 64-bit binaries.MySQL安装程序在初始设置期间将配置文件(稍后描述)提取到主机的硬盘驱动器中。虽然MySQL安装程序是一个32位应用程序,但它可以安装32位和64位二进制文件。

The initial setup adds a link to the Start menu under the MySQL group. 初始设置在MySQL组下添加一个到“开始”菜单的链接。Click Start, All Programs, MySQL, MySQL Installer to open MySQL Installer.单击“开始”、“所有程序”、“MySQL”、“MySQL安装程序”,打开MySQL安装程序。

Choosing a Setup Type选择安装类型

During the initial setup, you are prompted to select the MySQL products to be installed on the host.在初始设置过程中,系统会提示您选择要安装在主机上的MySQL产品。One alternative is to use a predetermined setup type that matches your setup requirements.一种选择是使用与您的设置要求相匹配的预定设置类型。By default, both GA and pre-release products are included in the download and installation with the Developer Default, Client only, and Full setup types. 默认情况下,GA和预发布产品都包含在下载和安装中,具有“开发人员默认设置”、“仅限客户端”和“完全设置”类型。Select the Only install GA products option to restrict the product set to include GA products only when using these setup types.选择“仅安装GA产品”选项以限制产品集仅在使用这些设置类型时包含GA产品。

Choosing one of the following setup types determines the initial installation only and does not limit your ability to install or update MySQL products for Windows later:选择以下安装类型之一仅决定初始安装,不会限制您以后安装或更新适用于Windows的MySQL产品的能力:

  • Developer Default开发者默认: Install the following products that compliment application development with MySQL::安装以下产品,以配合MySQL的应用程序开发:

  • Server only: Only install the MySQL server. This setup type installs the general availability (GA) or development release server that you selected when you downloaded MySQL Installer. It uses the default installation and data paths.:仅安装MySQL服务器。此安装类型安装您在下载MySQL安装程序时选择的一般可用性(GA)或开发发布服务器。它使用默认的安装和数据路径。

  • Client only: Only install the most recent MySQL applications and MySQL connectors.:仅安装最新的MySQL应用程序和MySQL连接器。This setup type is similar to the Developer Default type, except that it does not include MySQL server or the client programs typically bundled with the server, such as mysql or mysqladmin.此设置类型类似于Developer Default类型,只是它不包括MySQL服务器或通常与服务器捆绑的客户端程序,如mysqlmysqladmin

  • Full: Install all available MySQL products.:安装所有可用的MySQL产品。

  • Custom: The custom setup type enables you to filter and select individual MySQL products from the MySQL Installer catalog.:自定义设置类型使您能够从MySQL安装程序目录中筛选和选择单个MySQL产品。

    Note注意

    For MySQL Server versions 8.0.20 (and earlier), 5.7, and 5.6, the account you use to run MySQL Installer may not have adequate permission to install the server data files and this can interrupt the installation because the ExecSecureObjects MSI action cannot be executed.对于MySQL Server版本8.0.20(及更早版本)、5.7和5.6,用于运行MySQL安装程序的帐户可能没有足够的权限安装服务器数据文件,这可能会中断安装,因为无法执行ExecSecureObjects MSI操作。To proceed, deselect the Server data files feature before attempting to install the server again. 要继续,请在尝试再次安装服务器之前取消选择服务器数据文件功能。For help, see Product Features To Install).有关帮助,请参阅要安装的产品功能)。

    The Server data files check box was removed from the feature tree for MySQL Server 8.0.21 (and higher).MySQL Server 8.0.21(及更高版本)的功能树中删除了“服务器数据文件”复选框。

    Use the Custom setup type to install:使用Custom安装类型安装:

    • A product or product version that is not available from the usual download locations. 无法从通常的下载位置获得的产品或产品版本。The catalog contains all product releases, including the other releases between pre-release (or development) and GA.目录包含所有产品版本,包括预发布(或开发)和GA之间的其他版本。

    • An instance of MySQL server using an alternative installation path, data path, or both.MySQL服务器的一个实例,使用备用安装路径或数据路径,或两者兼而有之。For instructions on how to adjust the paths, see Section 2.3.3.2, “Setting Alternative Server Paths with MySQL Installer”.有关如何调整路径的说明,请参阅第2.3.3.2节,“使用MySQL安装程序设置备用服务器路径”

    • Two or more MySQL server versions on the same host at the same time (for example, 5.6, 5.7, and 8.0).同一主机上同时存在两个或多个MySQL服务器版本(例如5.6、5.7和8.0)。

    • A specific combination of products and features not offered as a predetermine setup type. For example, you can install a single product, such as MySQL Workbench, instead of installing all client applications for Windows.未作为预先确定的设置类型提供的产品和功能的特定组合。例如,您可以安装单个产品,如MySQL Workbench,而不是为Windows安装所有客户端应用程序。

Path Conflicts路径冲突

When the default installation or data folder (required by MySQL server) for a product to be installed already exists on the host, the wizard displays the Path Conflict step to identify each conflict and enable you to take action to avoid having files in the existing folder overwritten by the new installation. 当主机上已经存在要安装的产品的默认安装或数据文件夹(MySQL服务器所需)时,向导会显示“路径冲突”步骤,以识别每个冲突,并使您能够采取措施避免新安装覆盖现有文件夹中的文件。You see this step in the initial setup only when MySQL Installer detects a conflict.只有当MySQL安装程序检测到冲突时,才能在初始设置中看到此步骤。

To resolve the path conflict, do one of the following:要解决路径冲突,请执行以下操作之一:

  • Select a product from the list to display the conflict options.从列表中选择一个产品以显示冲突选项。A warning symbol indicates which path is in conflict. 警告符号表示哪条路径存在冲突。Use the browse button to choose a new path and then click Next.使用浏览按钮选择新路径,然后单击“下一步”。

  • Click Back to choose a different setup type or product version, if applicable. 单击“上一步”选择不同的安装类型或产品版本(如果适用)。The Custom setup type enables you to select individual product versions.Custom设置类型使您能够选择各个产品版本。

  • Click Next to ignore the conflict and overwrite files in the existing folder.单击“下一步”可忽略冲突并覆盖现有文件夹中的文件。

  • Delete the existing product. Click Cancel to stop the initial setup and close MySQL Installer. 删除现有产品。单击“取消”停止初始设置并关闭MySQL安装程序。Open MySQL Installer again from the Start menu and delete the installed product from the host using the Delete operation from the MySQL Installer dashboard.从「开始」菜单再次打开MySQL安装程序,并使用MySQL安装程序面板中的delete操作从主机中删除已安装的产品。

Check Requirements检查要求

MySQL Installer uses entries in the package-rules.xml file to determine whether the prerequisite software for each product is installed on the host. When the requirements check fails, MySQL Installer displays the Check Requirements step to help you update the host.MySQL安装程序使用package-rules.xml文件中的条目来确定主机上是否安装了每个产品的必备软件。当需求检查失败时,MySQL安装程序会显示“检查需求”步骤,以帮助您更新主机。Requirements are evaluated each time you download a new product (or version) for installation. The following figure identifies and describes the key areas of this step.每次下载新产品(或版本)进行安装时,都会评估需求。下图确定并描述了此步骤的关键领域。

Figure 2.8 Check Requirements图2.8 检查要求

MySQL Installer check-requirements before any requirements are downloaded and installed.

Description of Check Requirements Elements检查要求要素说明
  1. Shows the current step in the initial setup. Steps in this list may change slightly depending on the products already installed on the host, the availability of prerequisite software, and the products to be installed on the host.显示初始设置中的当前步骤。此列表中的步骤可能会略有变化,具体取决于主机上已安装的产品、必备软件的可用性以及要安装在主机上的产品。

  2. Lists all pending installation requirements by product and indicates the status as follows:按产品列出所有挂起的安装要求,并指示状态如下:

    • A blank space in the Status column means that MySQL Installer can attempt to download and install the required software for you.“状态”列中的空白表示MySQL安装程序可以尝试下载并安装所需的软件。

    • The word Manual in the Status column means that you must satisfy the requirement manually. Select each product in the list to see its requirement details.“状态”列中的“手动”一词表示必须手动满足要求。选择列表中的每个产品以查看其需求详细信息。

  3. Describes the requirement in detail to assist you with each manual resolution. When possible, a download URL is provided. After you download and install the required software, click Check to verify that the requirement has been met.详细描述该要求,以帮助您完成每个手动解决方案。如果可能,会提供下载URL。下载并安装所需软件后,单击“检查”以验证是否满足要求。

  4. Provides the following set operations to proceed:提供以下设置操作以继续:

    • Back上一步Return to the previous step. This action enables you to select a different the setup type.返回上一步。此操作使您能够选择不同的设置类型。

    • Execute执行Have MySQL Installer attempt to download and install the required software for all items without a manual status. 让MySQL安装程序尝试下载并安装所有项目所需的软件,而无需手动状态。Manual requirements are resolved by you and verified by clicking Check.手动要求由您解决,并通过单击“检查”进行验证。

    • Next下一步Do not execute the request to apply the requirements automatically and proceed to the installation without including the products that fail the check requirements step.不要执行自动应用要求的请求,在不包括未通过检查要求步骤的产品的情况下继续安装。

    • Cancel取消Stop the installation of MySQL products. Because MySQL Installer is already installed, the initial setup begins again when you open MySQL Installer from the Start menu and click Add from the dashboard. 停止MySQL产品的安装。由于MySQL安装程序已经安装,当您从“开始”菜单打开MySQL安装程序并从面板中单击“添加”时,初始安装程序将再次开始。For a description of the available management operations, see Product Catalog.有关可用管理操作的描述,请参阅产品目录

MySQL Installer Configuration FilesMySQL安装程序配置文件

All MySQL Installer files are located within the C:\Program Files (x86) and C:\ProgramData folders. 所有MySQL安装程序文件都位于C:\Program files(x86)C:\ProgramData文件夹中。The following table describes the files and folders that define MySQL Installer as a standalone application.下表介绍了将MySQL安装程序定义为独立应用程序的文件和文件夹。

Note注意

Installed MySQL products are neither altered nor removed when you update or uninstall MySQL Installer.当您更新或卸载MySQL安装程序时,已安装的MySQL产品既不会更改也不会删除。

Table 2.5 MySQL Installer Configuration Files表2.5 MySQL安装程序配置文件

File or Folder文件或文件夹Description描述Folder Hierarchy文件夹层次结构
MySQL Installer for WindowsThis folder contains all of the files needed to run MySQL Installer and MySQLInstallerConsole.exe, a command-line program with similar functionality.此文件夹包含运行MySQL安装程序和MySQLInstallerConsole.exe(一个具有类似功能的命令行程序)所需的所有文件。C:\Program Files (x86)
TemplatesThe Templates folder has one file for each version of MySQL server. Templates文件夹对于MySQL服务器的每个版本都有一个文件。Template files contain keys and formulas to calculate some values dynamically.模板文件包含用于动态计算某些值的键和公式。C:\ProgramData\MySQL\MySQL Installer for Windows\Manifest
package-rules.xml

This file contains the prerequisites for every product to be installed.此文件包含要安装的每个产品的先决条件。

C:\ProgramData\MySQL\MySQL Installer for Windows\Manifest
produts.xml

The products file (or product catalog) contains a list of all products available for download.products文件(或产品目录)包含可供下载的所有产品的列表。

C:\ProgramData\MySQL\MySQL Installer for Windows\Manifest
Product Cache

The Product Cache folder contains all standalone .msi files bundled with the full package or downloaded afterward.Product Cache文件夹包含与完整软件包捆绑或随后下载的所有独立.msi文件。

C:\ProgramData\MySQL\MySQL Installer for Windows