- 概述
- 要求
- 安装
- 安装后
- 集群管理
- 监控和警示
- 迁移和升级
- 特定于产品的配置
- 最佳实践和维护
- 故障排除
预迁移步骤
为确保您成功地将独立平台安装迁移到 Automation Suite,请务必执行以下部分中描述的步骤。预迁移步骤是必需的。
步骤 1:保存 Identity Server 配置数据
确保保存以下 Identity Server 配置数据:
主机管理员用户名和密码
保存主机管理员用户名和密码。
令牌签名证书
Identity Server 使用 .pfx 证书对 OAuth 令牌进行签名。如果您在独立部署中使用自己的令牌,则需要将其转换为 .pfx,并在 Automation Suite 集群的相应密码中进行更新。
如果您决定在 Automation Suite 部署中使用相同的签名证书,也可以在初始集群设置期间执行此步骤:kubectl edit secret identity-token-signing-certificate -n uipath。
SAML 证书
SAML 身份提供程序配置使用证书存储来读取客户端和服务器证书。您需要在 Automation Suite 集群的相应密码 (kubectl edit secret identity-saml-certificates -n uipath) 中更新先前在独立部署中使用的任何证书。
Identity Server 应用程序设置
保存以下 Identity Server 应用程序设置:
appsetting.production.json中的DatabaseProtectionSettings,位于独立部署的/identity文件夹中。DatabaseProtectionSettings.EncryptionKey2021设置用于加密静态敏感数据。您必须在迁移后阶段在 Automation Suite 部署中复制此值:kubectl edit secret identity-generated-secrets -n uipath。
导出证书
如果您使用的是 Azure 密钥保险库或 Windows 证书存储,请将证书导出为 .pfx 格式。
步骤 2:创建组织-租户对
对于独立部署中的每个租户,在 Automation Suite 环境中创建一个组织-租户对。
示例:如果在独立 Orchestrator 中有一个名为租户 1 的租户,则需要在 Automation Suite 中创建一个名为租户 1 的组织,并在该组织中也创建一个名为租户 1 的租户。创建租户后,请确保为该租户启用 Orchestrator 服务。
系统会自动为每个组织创建一个“默认”租户。您不必将其删除,但需要添加另一个名称与您的组织完全相同的租户。例如,在上一个示例中,创建组织租户 1 时,该组织中最终也会有一个名为默认的租户。最后一步是将另一个名为租户 1 的租户添加到该组织。然后,您可以继续创建下一个组织-租户对。
步骤 3:保存连接字符串和租户名称
保存以下信息以供进一步使用:
- 独立部署中 Orchestrator 数据库的连接字符串;
- Automation Suite 部署中 AutomationSuite_Platform 数据库的连接字符串;
- 独立部署中的租户名称;您可以在 Orchestrator 用户界面中查找,或使用 Orchestrator 租户表中的
TenancyName列进行查找; - Insights 连接字符串。
步骤 4:准备 Orchestrator
迁移概述
要将 Orchestrator 从独立安装迁移到 Automation Suite,您必须从独立安装中收集设置和各种文件,并将其应用于 Automation Suite 安装。
虽然在安装时只能配置部分设置,但所有设置都应可用于安装后配置。
- 如要在安装时配置设置,请将其添加到
cluster_config.json文件中; - 在安装完成后更新设置取决于设置的作用域,以及某个功能是否可用于通过 app-of-apps 参数进行配置。
You can store custom files that are needed inside the Orchestrator pods, such as assemblies or other storage files, in the built-in Ceph object store. The storage files are stored in a bucket for each tenant. The plugins are stored in the uipath bucket under orchestrator/plugins/nlog or orchestrator/plugins/securestore.
您可以按如下方式添加自定义配置:
- 通过编辑 ArgoCD 中的应用程序参数(参数覆盖);
- 通过编辑 Kubernetes 配置映射
orchestrator-customconfig中命名空间uipath中的文件。
正在准备 web.config
大多数 web.config 设置没有等效项,或者在 Automation Suite 中使用其他机制实现。
您确实需要配置以下选项:
security.requestFiltering.requestLimits.maxAllowedContentLength
security.requestFiltering.requestLimits.maxAllowedContentLength
记下此设置的值以备后用。决定是否需要在 Automation Suite 中对其进行配置。其默认值为 300MiB。
准备应用程序设置
您可能需要迁移在 UiPath.Orchestrator.dll.config 配置文件的 appSettings 或 secureAppSettings 部分中进行的自定义更改。您可以将自定义 appSettings 和 secureAppSettings 添加到 orchestrator-customconfig 配置映射。
在 UiPath.Orchestrator.dll.config 配置文件的 appSettings 部分中,标识所有已修改或添加的设置。将这些设置保存在 .json 文件中,以便在后续步骤中使用。
您可以使用 Orchestrator CLI 保护配置选项解密任何受保护的应用程序配置部分。您只需使用已更改或添加且在 Automation Suite 中仍然相关的设置。
You can create the appsettings.json file as shown in the following example:
{
"ExampleSetting.Enabled": true,
"ExampleSetting.Type": "BasicExample",
"ExampleSetting.Count": 3
}
{
"ExampleSetting.Enabled": true,
"ExampleSetting.Type": "BasicExample",
"ExampleSetting.Count": 3
}
准备存储
Decide what you need for the storage migration and if your current storage configuration stays the same or if you would instead let Automation Suite manage the storage for you. Automation Suite offers the option to store the blobs in Ceph, which can be used in all Orchestrator pods. In the case of a migration, you must copy the existing files to the current blob storage.
如果您在本地文件夹中使用文件系统类型的存储,请将数据从存储文件夹复制到 Automation Suite 节点上的文件夹。然后,通过使用 S3 实用程序(例如 s3cmd),您可以将数据复制到 Orchestrator。如果您使用的是 Ceph,则无需其他配置,因为这是默认选项。
如果要将文件系统与 Windows 网络共享一起使用,则需要在 ArgoCD Orchestrator 应用程序中配置存储。通过 Storage.Location 键,从当前的 Orchestrator 配置中检索与 Windows 网络共享的连接数据。由于 Automation Suite 在 Linux 计算机上运行,因此您不能依赖集成身份验证来访问网络共享,而是需要可以访问它的帐户的凭据。
目前,仅支持使用 SMB 协议的网络共享。不支持使用 NFS 的网络共享。
如果您使用 Azure、AWS 或 Minio 等远程存储选项,请确保将 Storage.Location 和 Storage.Type 设置添加到 appsettings.json 中。
准备 NLog
您可以对 NLog 进行以下自定义:
- 更改现有目标
- 添加新目标
- 添加 NLog 扩展程序
查看配置文件的 NLog 部分,并构建 NLog 自定义配置。要在 Elasticsearch 中启用机器人日志存储,您可以提供用户名、密码和 URI 作为 Automation Suite 参数,然后系统会自动配置目标。要为机器人日志启用自定义方案,您需要手动配置目标。
如果需要 NLog 扩展程序,请创建一个包含所有扩展程序及其依赖项的文件夹。
For example, the folder could be named nlogextensions. By default, Orchestrator loads the following extensions, so you do not need to include them in the folder or the NLog configuration:
NLog.Targets.ElasticSearch
UiPath.Orchestrator.Logs.Elasticsearch
Microsoft.ApplicationInsights.NLogTarget
NLog.Extensions.AzureEventHub
NLog.Targets.ElasticSearch
UiPath.Orchestrator.Logs.Elasticsearch
Microsoft.ApplicationInsights.NLogTarget
NLog.Extensions.AzureEventHub
创建包含以下标准部分的 nlog.custom.config 文件:扩展程序、目标和规则。
扩展程序部分是使用 assemblyFile 指定扩展程序集的一系列项目,以及程序集相对于 nlogextensions 文件夹的路径。
Orchestrator 定义了为常见用例配置或部分配置的 NLog 目标和规则。当需要自定义这些目标时,您只需在 NLog 配置中包括修改后的属性。您无法从预定义配置中删除现有属性,但可以更改它们。在 Orchestrator Pod 中,默认包含的目标定义在 /opt/app-root/app/nlog.config.json 位置。
Example: nlog.custom.config file that writes logs to Azure Blob:
{ "NLog": {
"extensions": [
{ "assemblyFile": "NLog.Extensions.AzureBlobStorage.dll" }
],
"targets": {
"azureBlob": {
"type": "AzureBlobStorage",
"connectionString": "DefaultEndpointsProtocol=https;AccountName=test;AccountKey=key;EndpointSuffix=core.windows.net",
"container": "orchestratorlogs",
"blobName": "${date:format=yyyy-MM-dd hh.mm}",
"layout": {
"type": "JsonLayout",
"includeAllProperties": true,
"Attributes": [
{"name": "ts","layout": "${longdate}"},
{"name": "level","layout": "${level:upperCase=true}"},
{"name": "logger","layout": "${logger}"},
{"name": "message","layout": "${message}"},
{"name": "exception","layout": "${onexception:${ui-pretty-exception}}"}
]
}
}
},
"rules": { "70_Final": { "writeTo": "stdout,azureBlob" } }
}
}
{ "NLog": {
"extensions": [
{ "assemblyFile": "NLog.Extensions.AzureBlobStorage.dll" }
],
"targets": {
"azureBlob": {
"type": "AzureBlobStorage",
"connectionString": "DefaultEndpointsProtocol=https;AccountName=test;AccountKey=key;EndpointSuffix=core.windows.net",
"container": "orchestratorlogs",
"blobName": "${date:format=yyyy-MM-dd hh.mm}",
"layout": {
"type": "JsonLayout",
"includeAllProperties": true,
"Attributes": [
{"name": "ts","layout": "${longdate}"},
{"name": "level","layout": "${level:upperCase=true}"},
{"name": "logger","layout": "${logger}"},
{"name": "message","layout": "${message}"},
{"name": "exception","layout": "${onexception:${ui-pretty-exception}}"}
]
}
}
},
"rules": { "70_Final": { "writeTo": "stdout,azureBlob" } }
}
}
To overwrite robot logs target, replace 70_final with 20_robot_primary in the above example .
扩展程序文件夹 nlogextensions 将复制到对象存储库中众所周知的插件位置。Orchestrator 配置程序工具可以自动执行此操作,同时还可以更新 NLog 配置。脚本会自动更改 nlog.custom.config,以便为扩展程序数组中的每个程序集文件添加 /var/orchestrator/plugins/nlog/ 前缀(如果尚未添加前缀)。
准备凭据存储
您可以将凭据存储的自定义插件迁移到 Automation Suite。为此,请更新配置映射中的配置,并将插件程序集复制到相应的对象存储桶。
- 插件必须在 Linux 上运行。
- 除
/tmp外,插件不得写入任何存储空间。
以下凭据存储插件会自动部署到 Automation Suite 中的 Orchestrator:
UiPath.Orchestrator.AzureKeyVault.SecureStore.dllUiPath.Orchestrator.SecureStore.CyberArkCCP.dll
Automation Suite 不支持 CyberArk AIM,因此您无法迁移它。我们建议迁移到 CyberArkCCP 凭据存储。
如果您使用任何其他凭据存储插件,请将其复制到文件夹中,例如 securestoreplugins。
在 appsettings.json 文件中添加凭据存储设置,如下所示:
- 要禁用默认插件,请在
appsettings.json中添加具有空字符串值的配置Plugins.SecureStores.Default; - 将所有自定义插件添加到
Plugins.SecureStores设置中,并在appsettings.json中用;分隔; - 添加任何自定义插件设置,如下所示:
Plugins.SecureStores.<<FriendlyName>>.<<SettingName>>。
将 securestoreplugins 插件文件夹复制到对象存储库中众所周知的插件位置。
Plugins.SecureStores 中的程序集从此文件夹加载。
Plugins.SecureStore.Default 中的程序集从 Orchestrator 应用程序文件夹中的插件文件夹加载。
准备加密密钥
默认情况下,Orchestrator 在安装时会生成一个加密密钥,用于数据库中的敏感信息。如果要在新的 Orchestrator 部署中重用数据库,则必须迁移此密钥。
在配置的 secureAppSettings 部分中,检索 EncryptionKey 的值并将其安全存储以备后用。
为每个租户准备加密密钥
加密密钥证书安装在 Windows 证书存储中。您必须向 Automation Suite 环境提供证书,以便 Orchestrator Pod 可以使用该证书。
Automation Suite 中不再需要 CertificatesStoreLocation 和 Azure.KeyVault.CertificateThumbprint 设置,但您可以根据需要使用 CertificatePassword。
采取以下步骤:
- 查看 appSettings 并获取
AzureKeyVault.*设置。 - 存储
Azure.KeyVault.VaultAddress、Azure.KeyVault.ClientId和Azure.KeyVault.DirectoryId以备后用。 - 检索证书,必要时检索证书密码。