unable to uninstall previous guest additions for upgrade

Discussions about using Linux guests in VirtualBox.
Post Reply
bcreane
Posts: 3
Joined: 9. Nov 2017, 01:48

unable to uninstall previous guest additions for upgrade

Post by bcreane »

Hi All, running Lubuntu distro with VirtualBox Guest Additions from 5.1.30. I upgraded VirtualBox, mounted the new v5.2.0 Guest Additions CD and tried to run the upgrade with:
sudo ./VBoxLinuxAdditions.run
The uninstall of the previous version fails:
/usr/sbin/vbox-uninstall-guest-additions: 9: /usr/sbin/vbox-uninstall-guest-additinos: /opt/VBoxGuestAdditions-5.1.30/uninstall.sh: not found
Failed to remove existing installation.   Aborting...
I confirmed that no existing packages were installed via:
sudo apt-get remove --purge virtualbox
Any suggestions for unblocking the upgrade?
thanks for any help you can provide.
bcreane
Posts: 3
Joined: 9. Nov 2017, 01:48

Re: unable to uninstall previous guest additions for upgrade

Post by bcreane »

I still haven't figured out a way past this issue. Seems like upgrades are sort of broken if you don't explicitly uninstall the VirtualBox packages with the old installer CD mounted. Not a great user experience. I'm still hopeful that someone has the magic bullet for uninstalling an old version of VirtualBox - I went through the install script and started hacking it to attempt to uninstall all the components, but no joy so far.
bcreane
Posts: 3
Joined: 9. Nov 2017, 01:48

Re: unable to uninstall previous guest additions for upgrade

Post by bcreane »

figured this out after deleting my VM - you can download old isos from: http://download.virtualbox.org/virtualbox. I may have been able to recover from virtualbox's broken upgrade process if I'd located those isos soon enough. Hope this helps someone else.
jbreen
Posts: 1
Joined: 16. Nov 2017, 11:12

Re: unable to uninstall previous guest additions for upgrade

Post by jbreen »

The current release breaks everything for me, so it's useless. And they're making us fix the problem ourselves manually? I can't expect the users of my VM to do that. This is frustrating.

Will Virtualbox release a new update with this problem fixed?
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: unable to uninstall previous guest additions for upgrade

Post by mpack »

If you're a business user then contact your Oracle rep and quote your service number. Otherwise you're just another Johnny free(down)loader.

> Will VirtualBox release a new update with the problem fixed?
Well given that there has been a new release every month or so for 10 years, I'd say the odds were quite good, especially if someone has provided a properly documented and repeatable test case.
Jiri
Posts: 2
Joined: 25. Nov 2017, 17:35

Re: unable to uninstall previous guest additions for upgrade

Post by Jiri »

VBoxLinuxAdditions.run is looking for the uninstall hook left behind by previous installation.
Look at lines 722 - 725 (VBoxLinuxAdditions.run, on VBoxGuestAdditions_5.2.2.iso - yours may be different if you're not looking at 5.2.2 )

Code: Select all

if test -x "${PUBLIC_UNINSTALL_HOOK}"; then
  "${PUBLIC_UNINSTALL_HOOK}" 1>&2 ||
    abort "Failed to remove existing installation.  Aborting..."
fi
PUBLIC_UNINSTALL_HOOK is defined on line 437:

Code: Select all

PUBLIC_UNINSTALL_HOOK="/usr/sbin/vbox-uninstall-guest-additions"
Looking at /usr/sbin:

Code: Select all

papaya mnt # ls /usr/sbin/vbo*
/usr/sbin/vbox-greeter  /usr/sbin/vbox-uninstall-guest-additions
Deleted both files (as in my case I went through the system and cleaned up (obviously not thoroughly enough) most of my old installations - I was playing with 2 or 3 of them)
Then it'll let you install the new guest additions

Hope this helps
Maran
Posts: 1
Joined: 21. May 2019, 02:31

Re: unable to uninstall previous guest additions for upgrade

Post by Maran »

This REALLY did the trick! Thank you, @Jiri! :D :D :D
Last edited by mpack on 21. May 2019, 09:44, edited 2 times in total.
Reason: Removed unnecessary verbatim quote of the whole previous message.
Post Reply