# Uninstall BastionXP - Clean Up
If you want to uninstall BastionXP installed in your server and clean up everything follow the below instructions.
This is extremely useful, if you messed up something during your initial trial and wanted to retry everything from the scratch. Follow the instructions below.
# Remove the BastionXP Software Package
Execute the below command to remove the BastionXP software package installed in your server.
# Debian
$ sudo apt remove bastionxp
# RPM
$ sudo rpm -e bastionxp
After you remove the BastionXP software package from your system, you should clean up all the relics left out by the software. These files and folders are not deleted by default by the uninstall command, because it contains some crucial data that you don't want to loose if you uninstall the package by mistake.
Remove these files and folders, if you want to retry everything from the scratch.
# Delete the Working Directory
The default working directory of the bastionxp
application is located at: /var/lib/bastionxp
. It contains all the essential files required by the bastionxp
app for its operations such as: server certificates, server keys, log file, data storage file etc.
Remove the entire working directory to clean up.
$ sudo rm -rf /var/lib/bastionxp
# Delete the Config File
BastionXP uses the config.json
located at /etc/bastionxp/config.json
, by default.
Remove the entire directory to clean up the config file(s).
$ sudo rm -rf /etc/bastionxp