Remove a device
Removing a host has two halves: taking it out of the portal, and uninstalling the agent from the host. The portal can do both at once.
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.
In the same dialog, leave Also uninstall the agent ticked and choose Remove and uninstall. Each host removes its agent the next time it checks in (within a minute when it is online) and then leaves the portal; a host that is offline does it when it comes back. Follow it on the job page the portal opens.
The option is greyed out for agents too old to remove themselves: upgrade them first on Agents, or uninstall them on the host as below.
To bring the host back later, install the agent again with a new enrollment token.
2. Uninstall the agent on the host (when the portal cannot)
Without the option above, removing a device in the portal does not uninstall the agent. The installer removes it for you. Run it the same way you installed, with the uninstall option, as root or in an elevated PowerShell:
# Linux
curl -fsSL -A remediforge-installer https://YOUR-PORTAL/install.sh | sudo sh -s -- --uninstall
# macOS
curl -fsSL -A remediforge-installer https://YOUR-PORTAL/install-macos.sh | sudo sh -s -- --uninstallThe installer program is downloaded for this, so a host that reaches RemediForge
only through the site's patch cache adds --server https://YOUR-PORTAL --via-cache https://YOUR-CACHE to the command, as when installing.
# Windows
$env:REMEDIFORGE_UNINSTALL='1'
iwr -useb -UserAgent 'remediforge-installer' https://YOUR-PORTAL/install.ps1 | iexOr by hand:
Linux (installed with the installer)
sudo systemctl disable --now remediforge-agent
sudo rm -f /etc/systemd/system/remediforge-agent.service
sudo systemctl daemon-reload
sudo rm -rf /opt/remediforge /etc/remediforge /var/lib/remediforgeLinux (installed from a package)
sudo apt remove remediforge-agent # Debian or Ubuntu
sudo dnf remove remediforge-agent # RHEL family
sudo rm -rf /var/lib/remediforge # the host's credentialWindows
In an elevated PowerShell:
Stop-Service RemediForgeAgent
sc.exe delete RemediForgeAgent
Remove-Item -Recurse -Force "$env:ProgramFiles\RemediForge", "$env:ProgramData\RemediForge"The Windows app updater, if the agent installed it, stays; remove it separately if you do not want it.
macOS
sudo launchctl bootout system/com.remediforge.agent
sudo rm -f /Library/LaunchDaemons/com.remediforge.agent.plist
sudo rm -rf /opt/remediforge /etc/remediforge /var/lib/remediforge /var/log/remediforge-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.