Question How do I perform a complete uninstall of the Altiris AClient agent?
How do I perform a complete uninstall of the Altiris AClient agent?
The suggested method for removing the AClient from a system is to run the following line from a DOS command prompt:
C:\program files\altiris\aclient\aclient.exe /remove /silent
However, removing the AClient with the switches "/remove /silent" will not remove the AClient directory. It will remove the AClntUser.exe, disable the AClient service and disable the Windows alkernel driver.
For a complete removal of AClient, registry entries and AClient related files, run the following script directly on the target computer: (Note: Depending on computer or network settings and policies, this script may not function correctly in all environments.)
Start /Wait "" "C:\program files\altiris\aclient\aclient.exe" /remove /silent
DEL /s /q "C:\WINDOWS\system32\drivers\AlKernel.sys"
DEL /s /q "C:\WINDOWS\Temp\alsmb.exe"
RD /s /q "C:\Program files\Altiris\AClient\"
REG DELETE HKLM\SYSTEM\CurrentControlSet\Services\AClient /f
REG DELETE HKLM\SYSTEM\CurrentControlSet\Enum\Root\LEGACY_ACLIENT /f
REG DELETE HKLM\SYSTEM\ControlSet001\Enum\Root\LEGACY_ACLIENT /f
REG DELETE HKLM\SYSTEM\ControlSet001\Services\AClient /f
REG DELETE HKLM\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\AuthorizedApplications\List /f /v "C:\Program Files\Altiris\AClient\AClntUsr.EXE"
REG DELETE HKLM\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\AuthorizedApplications\List /f /v "C:\Program Files\Altiris\AClient\AClntUsr.EXE"
Note: Some command lines are purposely redundant to verify entries have been removed by the initial AClient uninstall process.
To run this script using a Deployment Server job:
1) Save the above script as a batch file on the Deployment Server eXpress share, with the name of RemoveAC.bat.
2) In a Deployment Server job, create a Copy File To task to copy this batch file to the root of the destination hard drive (usually C:\).
3) Create a Run Script task as the second task in the same job, with the following lines in the section for "Run this script":
schtasks /CREATE /TR "C:\RemoveAC.bat" /SC ONCE /TN "AClientOut" /ST 00:00:00 /RU SYSTEM
schtasks /RUN /TN "AClientOut"
When this job is run, the script is copied to the root of the target computer and a Windows Task Scheduler event is run to execute the batch file locally.
Note: You may be able to use a Copy File To task (as described above) to uninstall the Altiris AClient. However this operation is dependent on computer, network and domain policies or settings. Altiris cannot guarantee that this task will be successful in all environments.