Remove Virtualbox installed via deb packages – Debian 11

Last updated on March 23rd, 2023 at 09:37 am.

Remove Virtualbox installed via deb packages – Debian 11

If you download a .deb package and successfully install an app using sudo dpkg -i thedebpackage.deb, you can uninstall it. It is not as straightforward as using apt. Here is how to uninstall a Debian app installed via a downloaded deb package.

Step 1: Find the name of the package as installed on your system:

dpkg -l | grep virtualbox

The name will usually start with virtualbox -version. ( example : virtualbox-7.0)

Step 2: Run the following to remove it. Replace virtualboxNameHere with the name you got from above.

sudo dpkg -r  virtualboxNameHere

#Eaxmple:

sudo dpkg -r virtualbox-7.0

To remove it plus all its configuration files do:

sudo dpkg --purge virtualboxNameHere

#Example:

sudo dpkg --purge virtualbox-7.0

If a package has dependencies preventing you from uninstalling it, then list all the dependencies plus the package. Delimit each package by a white-space. For example, below is how I removed Libre office 7.4 from Debian:

 sudo dpkg --purge libreoffice7.4 libreoffice7.4-base libreoffice7.4-calc  libreoffice7.4-debian-menus libreoffice7.4-dict-en  libreoffice7.4-dict-es   libreoffice7.4-dict-fr libreoffice7.4-draw libreoffice7.4-en-us libreoffice7.4-impress libreoffice7.4-math  libreoffice7.4-ure  libreoffice7.4-writer

This is how you can remove any package, not just Virtualbox if it was installed via a downloaded deb package.

Bonus : To remove packages installed via apt, you can simply do:

sudo apt remove thepackage

#or remove with dependencies

sudo apt autoremove thepackage

#or remove it with all its configuration files

sudo apt --purge thepackage

2 thoughts on “Remove Virtualbox installed via deb packages – Debian 11”

Comment Here

Need WordPress help? Linux Server help? Talk to us.

  • We are your own WordPress customer service.
  • We set up Linux servers and install or migrate WordPress. Learn more here.
  • We support WooCommerce too.
  • Check out our WordPress customer support plans here or contact us below .

If you have any questions regarding WordPress support, Linux server support or any of our services, feel free to reach out or read more on our services page.

Join this free course:

How to host multiple WordPress
websites on a VPS

Close me!