agentName = "TenantAttributionAndInboundConnectorAgent"; $agentFactory = "Microsoft.Exchange.Hygiene.TenantAttribution.T ...

$agentName = "TenantAttributionAndInboundConnectorAgent";                    $agentFactory = "Microsoft.Exchange.Hygiene.TenantAttribution.TenantInboundConnectorAgentFactory";                    $agentAssembly = ($RoleInstallPath + "TransportRoles\agents\Hygiene\Microsoft.Exchange.Hygiene.TenantAttribution.TenantInboundConnectorAgent.dll");                    $agent = get-transportagent-удостоверения: $agentName - TransportService: клиентской части;                    Если {($agent)                        Uninstall-transportagent-удостоверения: $agentName - TransportService: клиентской части;                    };                    install-TransportAgent-имя: $agentName - TransportAgentFactory: $agentFactory - путь _ сборки: $agentAssembly - TransportService: клиентской части;                    Если ($agent.enabled- или! $agent) {enable-transportagent-удостоверения: $agentName - TransportService: интерфейсной части};                    SET-TransportAgent-приоритет: 2-удостоверения: $agentName - TransportService: клиентской части;