Skip to main content

Uninstall the Windows Agent

If the Windows agent is installed on your host machine, uninstall the agent before you install another version of the agent.

note

Lacework recommends that you do not downgrade to an earlier version of the agent because it can cause data incompatibility.

To uninstall the agent from your host machine:

  1. Open Add/Remove program on your host.
  2. Select LWDataCollector from the list of programs.
  3. Click Uninstall.
  4. Verify that LWDataCollector does not appear in the list of programs.
  5. Open a PowerShell terminal or the Windows Command Prompt as an administrator and do the following to ensure that the agent service and driver are not running.
    1. Check the state of the agent service by entering the command: C:\Users\Administrator> sc.exe query lwdatacollector
    2. Check the state of the agent driver by entering the command: C:\Users\Administrator> sc.exe query lwdcs

PowerShell Script to Uninstall the Agent

You can also use the following PowerShell script to uninstall the agent.

## Script to uninstall the Lacework Windows agent
$app = Get-WmiObject -Class Win32_Product -Filter "Name like '%Lacework%'"
$app.Uninstall()