Tarefa de Desinstalação do Agente Red Hat Enterprise Linux Server 6
Microsoft.Linux.RHEL.6.Agent.Uninstall.Task (Task)
Element properties:
Member Modules:
Source Code:
<Task ID="Microsoft.Linux.RHEL.6.Agent.Uninstall.Task" Target="Microsoft.Linux.RHEL.6.Computer" Accessibility="Internal" Enabled="true">
<Category>Maintenance</Category>
<WriteAction ID="UninstallAgent" TypeID="Unix!Microsoft.Unix.SSHCommand.UninstallAgent.WriteAction">
<Host/>
<Port/>
<UserName>$RunAs[Name="Unix!Microsoft.Unix.AgentMaintenanceAccount"]/UserName$</UserName>
<Password>$RunAs[Name="Unix!Microsoft.Unix.AgentMaintenanceAccount"]/Password$</Password>
<UninstallCommand>if test -f /opt/microsoft/omsagent/bin/omsadmin.sh; then if test "$(/opt/microsoft/omsagent/bin/omsadmin.sh -l | grep scom | wc -l)" = "1" && test "$(/opt/microsoft/omsagent/bin/omsadmin.sh -l | wc -l)" = "1" || test "$(/opt/microsoft/omsagent/bin/omsadmin.sh -l)" = "No Workspace"; then /opt/microsoft/omsagent/bin/uninstall; else /opt/microsoft/omsagent/bin/omsadmin.sh -x scom; fi; else /opt/microsoft/scx/bin/uninstall; fi</UninstallCommand>
<PackageInstance/>
<TimeoutSeconds>120</TimeoutSeconds>
</WriteAction>
</Task>