Conflict while updating virtualbox
I've never lost my VirtualBox guest OSs or settings when manually upgrading Oracle VirtualBox by manually uninstalling the old version and then downloading the latest version of Oracle VirtualBox and manually installing it by following the steps listed below. Your existing VirtualBox guest OS(s) will not be deleted if the version of Oracle VirtualBox is upgraded. Make sure that you also upgrade the Oracle VM VirtualBox Extension Pack so that it is the same version as whatever version of VirtualBox that is installed.
-
Show the name of the installed virtualbox package.
dpkg -l | grep virtualbox | grep ii
The results of this command should be something like
virtualbox-5.0
-
Uninstall the old version of VirtualBox
sudo dpkg -r virtualbox-5.0 # match the version of virtualbox with the results of step 1.
Download the latest version of Oracle VirtualBox for your Ubuntu release and Oracle VM VirtualBox Extension Pack from the official Oracle VirtualBox website. You might want to compare the SHA256 checksum that is provided on the download webpage to verify the integrity of the downloaded packages.
Change directories using
cd
to the directory containing the Oracle VirtualBox .deb file that you downloaded. In your question this file is named:
virtualbox-5.1_5.1.22-115126~Ubuntu~trusty_amd64.deb-
Install the latest version of Oracle VirtualBox for your Ubuntu release.
sudo dpkg -i virtualbox-5.1_5.1.22-115126~Ubuntu~trusty_amd64.deb
Related videos on Youtube
Make42
Updated on September 18, 2022Comments
-
Make42 over 1 year
I would like to update my virtualbox but get the error message
$ sudo dpkg -i virtualbox-5.1_5.1.22-115126~Ubuntu~trusty_amd64.deb dpkg: regarding virtualbox-5.1_5.1.22-115126~Ubuntu~trusty_amd64.deb containing virtualbox-5.1: virtualbox-5.1 conflicts with virtualbox virtualbox-5.0 provides virtualbox and is present and installed. dpkg: error processing archive virtualbox-5.1_5.1.22-115126~Ubuntu~trusty_amd64.deb (--install): conflicting packages - not installing virtualbox-5.1 Errors were encountered while processing: virtualbox-5.1_5.1.22-115126~Ubuntu~trusty_amd64.deb
I understand what it means, but are not sure how to solve the issue. Should I de-install my current installation? I am afraid I might lose my settings etc.
-
Ravexina about 7 yearsSeems you have an other version of virtualbox already installed on your system. you should remove it first... by the way: I suggest you to install virtualbox from Ubuntu repositories. I don't think that you lose any settings. At least I didn't ;)
-
Make42 about 7 years@Ravexina: I am using Kubuntu 14.4, so there are no updates for virtualbox anymore in the repo. My fear is that by removing the older version I lose the settings, not by updating from the repo.
-
Takkat about 7 yearsWe have to remove a previous version (5.0) to be able to intall an upgrade (5.1). See askubuntu.com/questions/692982/…
-
Ravexina about 7 years@Make42 I'm not sure, however I once removed mine and reinstalled the same version but everything was there ;)
-
Takkat about 7 yearsAll settings, and all virtual machines will be preserved.
-
Admin about 7 yearsUnless there is a very special configuration which I doubt, removing a package does not remove it's config files. That is what the purge option is for.
-
-
Boris Hamanov about 7 yearsA possibly better command to find installed virtualbox packages might be
dpkg -l *virtualbox* | grep ii
... as this shows all virtualbox-related packages, but only ones that are currently installed. -
jjmerelo over 5 yearsWhat if it still shows conflict after doing this? There were only some configuration files.
-
Krasimir over 5 yearsThanks man all work great, +1
-
Steve about 4 yearsIf I uninstall the old version of VB, will my virtual machine(s) get deleted along with it?
-
karel about 4 yearsVirtualBox only supports images of a virtual hard disk, so you first need to create a new virtual machine in VirtualBox before using an existing VirtualBox image. See this Oracle VirtualBox tutorial: Importing a VDI in VirtualBox.