在 Azure Stack Hub 上使用 MySQL 数据库Use MySQL databases on Azure Stack Hub

使用 MySQL 资源提供程序在 Azure Stack Hub 上提供 MySQL 数据库。Use the MySQL resource provider to offer MySQL databases on Azure Stack Hub. 部署资源提供程序并将其连接到一个或多个 MySQL 服务器实例后,可以创建以下项:After you deploy the resource provider and connect it to one or more MySQL server instances, you can create:

  • 用于云原生应用的 MySQL 数据库。MySQL databases for cloud-native apps.
  • 用于 Web 应用程序的 MySQL 数据库。MySQL databases for web applications.

安装 MySQL 资源提供程序之前,请考虑以下几个限制:There are several limitations to consider, before installing the MySQL resource provider:

  • 用户只能创建和管理单个数据库。Users can only create and manage individual databases. 最终用户无法访问数据库服务器实例。Database Server instance is not accessible to end users. 这可能会限制与需要访问 master、Temp DB 或动态管理数据库的本地数据库应用程序的兼容性。This may limit compatibility with on-premises database applications that need access to master, Temp DB, or to dynamically manage databases.
  • 你的 Azure Stack Hub 操作员负责部署、更新、保护、配置和维护 MySQL 数据库服务器和主机。Your Azure Stack Hub operator is responsible for deploying, updating, securing, configuring and maintaining the MySQL database servers and hosts. RP 服务不提供任何主机和数据库服务器实例管理功能。The RP service does not provide any host and database server instance management functionality.
  • 不同订阅中不同用户的数据库可以位于同一个数据库服务器实例上。Databases from different users in different subscriptions may be located on the same database server instance. RP 不提供隔离不同主机或数据库服务器实例上的数据库的任何机制。The RP does not provide any mechanism for isolating databases on different hosts or database server instances.
  • RP 不提供关于数据库的租户使用情况的任何报告。The RP does not provide any reporting on tenant usage of databases.

MySQL 资源提供程序适配器体系结构MySQL resource provider adapter architecture

资源提供程序具有以下组件:The resource provider has the following components:

  • MySQL 资源提供程序适配器虚拟机 (VM) ,这是运行提供程序服务的 Windows Server VM。The MySQL resource provider adapter virtual machine (VM), which is a Windows Server VM that's running the provider services.

  • 资源提供程序,它处理请求并访问数据库资源。The resource provider, which processes requests and accesses database resources.

  • 托管 MySQL 服务器的服务器,为称作宿主服务器的数据库提供容量。Servers that host MySQL Server, which provide capacity for databases that are called hosting servers. 你可以自己创建 MySQL 实例,或提供对外部 MySQL 实例的访问权限。You can create MySQL instances yourself, or provide access to external MySQL instances. Azure Stack Hub 快速入门库中有一个示例模板,可以用来:The Azure Stack Hub Quickstart Gallery has an example template that you can use to:

    • 创建 MySQL 服务器。Create a MySQL server for you.
    • 从 Azure 市场下载并部署 MySQL 服务器。Download and deploy a MySQL Server from Azure Marketplace.

Note

必须通过租户订阅创建安装在 Azure Stack Hub 集成系统上的宿主服务器,Hosting servers that are installed on Azure Stack Hub integrated systems must be created from a tenant subscription. 而不能通过默认提供商订阅创建。They can't be created from the default provider subscription. 必须通过用户门户或者使用相应的登录名通过 PowerShell 会话来创建这些服务器。They must be created from the user portal or from a PowerShell session with an appropriate sign-in. 所有宿主服务器都是可计费的 VM,并且必须具有许可证。All hosting servers are billable VMs and must have licenses. 服务管理员可以是租户订阅的所有者。The service administrator can be the owner of the tenant subscription.

所需的特权Required privileges

系统帐户必须拥有以下特权:The system account must have the following privileges:

  • 数据库: 创建、删除Database: create, drop
  • 登录名: 创建、设置、删除、授予、吊销Login: create, set, drop, grant, revoke

后续步骤Next steps

部署 MySQL 资源提供程序Deploy the MySQL resource provider