-
Notifications
You must be signed in to change notification settings - Fork 4
Modify Installation Deb and Uninstalling Docs. #77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,111 +7,109 @@ migration-notes: "Added during 2025 documentation reorganization" | |
|
|
||
| # Uninstalling OpenSPP | ||
|
|
||
| This guide provides detailed instructions for uninstalling OpenSPP from your system. It covers both complete removal, which includes deleting the application, configuration files, and database, as well as a partial uninstallation that keeps your data intact for future use. | ||
| This guide provides instructions for uninstalling OpenSPP from a Debian or Ubuntu system. It covers two main scenarios: | ||
| - **Complete Uninstallation**: Removes the application, configuration, data, and database. | ||
| - **Partial Uninstallation**: Removes the application but keeps your data and configuration for future use. | ||
|
|
||
| ## Before You Begin: Back Up Your Data | ||
|
|
||
| **Warning**: A complete uninstallation is irreversible and will permanently delete your data. Before proceeding, it is strongly recommended to create a full backup of your database and filestore. | ||
|
|
||
| For detailed backup instructions, refer to the {doc}`database_management` guide. | ||
|
Comment on lines
+16
to
+18
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
|
|
||
| ## Complete Uninstallation | ||
|
|
||
| To completely remove OpenSPP from your system: | ||
| Follow these steps to completely remove OpenSPP and all its components from your system. | ||
|
|
||
| ### Step 1: Stop and Disable Services | ||
| ### Step 1: Stop and Disable the OpenSPP Service | ||
|
|
||
| **Stop OpenSPP service** | ||
| ```bash | ||
| # Stop OpenSPP service | ||
| sudo systemctl stop openspp | ||
| ``` | ||
|
|
||
| # Disable service from starting on boot | ||
| **Disable service from starting on boot** | ||
| ```bash | ||
| sudo systemctl disable openspp | ||
|
|
||
| # Remove systemd service file | ||
| sudo rm -f /etc/systemd/system/openspp.service | ||
| sudo rm -f /lib/systemd/system/openspp.service | ||
|
|
||
| # Reload systemd | ||
| sudo systemctl daemon-reload | ||
| ``` | ||
|
|
||
| ### Step 2: Remove OpenSPP Package | ||
|
|
||
| **Remove OpenSPP package** | ||
| ```bash | ||
| # Remove OpenSPP package | ||
| sudo apt-get remove --purge openspp-17-daily | ||
| ``` | ||
|
|
||
| # Remove configuration files | ||
| sudo rm -rf /etc/openspp | ||
|
|
||
| # Remove data directories | ||
| sudo rm -rf /var/lib/openspp | ||
| sudo rm -rf /var/log/openspp | ||
|
|
||
| # Remove binary files | ||
| sudo rm -f /usr/bin/openspp-server | ||
| sudo rm -f /usr/bin/openspp-shell | ||
| **Remove configuration files** | ||
| ```bash | ||
| sudo rm -rf /etc/openspp && sudo rm -rf /var/lib/openspp && sudo rm -rf /var/log/openspp && sudo rm -f /usr/bin/openspp-server && sudo rm -f /usr/bin/openspp-shell | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Combining multiple If keeping it as is, consider adding a comment explaining that the |
||
| ``` | ||
|
|
||
| ### Step 3: Remove PostgreSQL Database (Optional) | ||
|
|
||
| **Warning**: This will permanently delete all OpenSPP data. | ||
|
|
||
|
|
||
| **Drop the OpenSPP database** | ||
| ```bash | ||
| # Drop the OpenSPP database | ||
| sudo -u postgres dropdb openspp_prod | ||
| ``` | ||
|
|
||
| # Remove the OpenSPP PostgreSQL user | ||
| **Remove the OpenSPP PostgreSQL user** | ||
| ```bash | ||
| sudo -u postgres dropuser openspp | ||
| ``` | ||
|
|
||
| ### Step 4: Remove Repository Configuration | ||
|
|
||
| **Remove APT repository configuration** | ||
| ```bash | ||
| # Remove APT repository configuration | ||
| sudo rm -f /etc/apt/sources.list.d/openspp.list | ||
| ``` | ||
|
|
||
| # Remove GPG key (if added) | ||
| **Remove GPG key (if added)** | ||
| ```bash | ||
| sudo apt-key del "OpenSPP Repository" | ||
| ``` | ||
|
|
||
| # Update package list | ||
| **Update package list** | ||
| ```bash | ||
| sudo apt-get update | ||
| ``` | ||
|
|
||
| ### Step 5: Clean Up Dependencies (Optional) | ||
|
|
||
| If you want to remove PostgreSQL as well: | ||
|
|
||
| **Remove PostgreSQL** | ||
| ```bash | ||
| # Remove PostgreSQL | ||
| sudo apt-get remove --purge postgresql postgresql-client postgresql-common | ||
| ``` | ||
|
|
||
| # Remove PostgreSQL data | ||
| sudo rm -rf /var/lib/postgresql | ||
|
|
||
| # Remove PostgreSQL configuration | ||
| sudo rm -rf /etc/postgresql | ||
| **Remove PostgreSQL data and configuration** | ||
| ```bash | ||
| sudo rm -rf /var/lib/postgresql && sudo rm -rf /etc/postgresql | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
| ``` | ||
|
|
||
| ## Partial Uninstallation | ||
|
|
||
| If you want to keep the database but remove the application: | ||
|
|
||
|
|
||
| **Stop and disable OpenSPP service** | ||
| ```bash | ||
| # Stop service | ||
| sudo systemctl stop openspp | ||
| sudo systemctl disable openspp | ||
| ``` | ||
|
|
||
| # Remove package but keep configuration | ||
| **Remove package but keep configuration** | ||
| ```bash | ||
| sudo apt-get remove openspp-17-daily | ||
|
|
||
| # Keep database and filestore for potential reinstallation | ||
| # /var/lib/openspp/ and PostgreSQL database remain intact | ||
| ``` | ||
|
|
||
| ## Reinstall After Uninstallation | ||
| - Keep database and filestore for potential reinstallation | ||
| - var/lib/openspp/ and PostgreSQL database remain intact | ||
|
Comment on lines
+110
to
+111
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
|
|
||
| To reinstall OpenSPP after uninstallation: | ||
| ## Reinstall After Uninstallation | ||
|
|
||
| ```bash | ||
| # Follow the installation steps from the beginning | ||
| # If you kept the database, you can reuse it by: | ||
| # 1. Reinstall OpenSPP | ||
| # 2. Update configuration to point to existing database | ||
| # 3. Start service | ||
| ``` | ||
| To reinstall OpenSPP after uninstallation, follow the {doc}`../getting_started/installation_deb`. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Combining these commands into a single line is good for brevity, but it might make it harder to debug if the
mkdircommand fails. Consider keeping them separate for clarity, especially in documentation.If keeping it as is, consider adding a comment explaining that the
&&operator ensures thatcdonly executes ifmkdiris successful.