Remove a device
Removing a host has two halves: taking it out of the portal, and uninstalling the agent from the host. Do both.
1. Remove it in the portal
On Devices, select the host (or several) and choose Remove device.
- The host leaves the active estate and no longer counts in reports and compliance.
- Its job and audit history stay available.
- Its credential is revoked, so the agent on the host stops after its next attempt to report.
To bring the host back later, install the agent again with a new enrollment token.
Removing a device in the portal does not uninstall the agent from the host. Do that next.
2. Uninstall the agent from the host
Linux (installed with the installer)
sudo systemctl disable --now patchpilot-agent
sudo rm -f /etc/systemd/system/patchpilot-agent.service
sudo systemctl daemon-reload
sudo rm -rf /opt/patchpilot /etc/patchpilot /var/lib/patchpilotLinux (installed from a package)
sudo apt remove patchpilot-agent # Debian or Ubuntu
sudo dnf remove patchpilot-agent # RHEL family
sudo rm -rf /var/lib/patchpilot # the host's credentialWindows
In an elevated PowerShell:
Stop-Service PatchPilotAgent
sc.exe delete PatchPilotAgent
Remove-Item -Recurse -Force "$env:ProgramFiles\PatchPilot", "$env:ProgramData\PatchPilot"winget, if the agent installed it, stays; remove it separately if you do not want it.
macOS (In testing)
sudo launchctl bootout system/com.patchpilot.agent
sudo rm -f /Library/LaunchDaemons/com.patchpilot.agent.plist
sudo rm -rf /opt/patchpilot /etc/patchpilot /var/lib/patchpilot /var/log/patchpilot-agent.logA host that was only switched off
A host that is shut down shows as Offline after three minutes and comes back by itself when it starts again. Remove it only if it is gone for good.