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-identidade: $agentName - TransportService: FrontEnd;                    Se {($agent)                        desinstalar-transportagent-identidade: $agentName - TransportService: FrontEnd;                    };                    instalação-TransportAgent-nome: $agentName - TransportAgentFactory: $agentFactory - AssemblyPath: $agentAssembly - TransportService: FrontEnd;                    Se ($agent.enabled- ou! $agent) {enable-transportagent-identidade: $agentName - TransportService: FrontEnd};                    conjunto-TransportAgent-prioridade: 2-identidade: $agentName - TransportService: FrontEnd;