Page 1 of 1

[SOLVED] - VirtualBox removal/update - Help

Posted: 23. Apr 2009, 19:10
by lkraemer
I am pretty new to PCLinuxOS, and don't have a good handle on removing software installed from
a run package by using the script. (The normal way to install or uninstall is via Synaptic which uses
apt-get, but Synaptic doesn't show VirtualBox as being installed, even though it is.)

I have installed "VirtualBox-2.1.4-42893-Linux_x86.run" in PCLinuxOS 2009.1 by running the script,
but never got around to installing my GUEST OS (XP). Now VirtualBox has released a newer version
VirtualBox-2.2.0-45846-Linux_x86.run. I'd like to update to the latest version.

What is the correct procedure for uninstalling the VirtualBox software so I can install the newest version
of VirtualBox without creating problems? Or do I just install the newest version over the old one?

I opened a Terminal window and did an apt-get update then did apt-get remove virtualbox.
apt-get doesn't find virtualbox installed. How can I list the installed virtualbox package, and
then remove it since it was installed with the script?

kpackage doesn't show it being installed either.

Thanks.

lkraemer

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 19:39
by Perryg
Try using dpkg to reinstall the package and then you should be able to uninstall it.

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 21:31
by Sasquatch
Check the --help output of the previous installer file (2.1.4) for any parameters you can use. It might have a --uninstall parameter. Dpkg won't show them, as your package manager will look in it's status file for installed packages.
Usually, you can just install the new version on top of the old one, but as this is a new major version, this is not recommended. Especially since you didn't install VB using a package for the package manager, as any upgrade would remove the previous version.

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 21:40
by lkraemer
Perryg,
I am too new to know exactly what you are telling me.
If I use dpkg to re-install VirtualBox-2.1.4-43001-Linux_x86, so I am able to remove it, do I use the .run, .rpm, or the .deb file?

After I've completed the install, then I understand to remove it.

Thanks for your help.

lkraemer

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 21:47
by Sasquatch
lkraemer wrote:Perryg,
I am too new to know exactly what you are telling me.
If I use dpkg to re-install VirtualBox-2.1.4-43001-Linux_x86, so I am able to remove it, do I use the .run, .rpm, or the .deb file?

After I've completed the install, then I understand to remove it.

Thanks for your help.

lkraemer
When using dpkg, you give the name of the package, not the full version and build. So it would be dpkg -r VirtualBox-2.1. But as you installed from the .run file, it won't be listed in your package status list.

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 22:06
by lkraemer
Sasquatch,
OK, bear with me as I an new to all this, and I really want to do things right.

PerryG said to use dpkg to install VirtualBox-2.1 again over the stuff I installed with the .run file. Then remove it with dpkg.
Do I use the deb, the rpm, or the run file with dpkg to install over 2.1.4 with the same package version, then use dpkg to
uninstall this version of VirtualBox.

Then install the latest RPM package for PCLinuxOS 2009.1.

I need detailed steps so I don't mess my PCLinuxOS up worse than I have already.

Thanks.

lkraemer

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 22:24
by Perryg
Ok this is only a work around for a problem.
Since you did not use the recommended method to install you have no clue as to what to remove.
One way to get this to a state that you can deal with is to reinstall using a suggested package installer.

You can from a terminal type

sudo dpkg -i <the full path and name to the install package>

What should happen is it will install as it did before but this time it will record the information needed to uninstall it.
Because all of the files are just placed over the already installed files all you are doing is allowing the dpkg manager to record the paths and dependencies.

Then you can just run the uninstall

sudo dpkg -r <program name>

And call it a day.

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 23:05
by lkraemer
Perryg,
Isn't dpkg only for .deb packages?

PCLinuxOS uses RPM type packages, and I am not 100% sure what installs a RPM type package
that I download to the Desktop.

Maybe you have more knowledge about what I should use to install the downloaded file.

I did managed to get VirtualBox 2.1.4 un-installed by running the script again, but added uninstall at
the end of the script. (I did go remove the /home/larry/.VirtualBox subdirectory manually.)

Thanks.

lkraemer

Re: VirtualBox removal/update - Help

Posted: 23. Apr 2009, 23:12
by Sasquatch
That would work, if the files are installed in the same folder. But I remember very clearly that users who installed the .run file had VB installed in /opt, and not /usr. And that is just the place where the .run file installs it.
Currently working inside a VM to test some more, on how to remove it.

EDIT:
Found out how to remove it. Very easy. Just run the script with "uninstall" as parameter. How simple do you want to have it?

Never, ever, think about your package manager when installing things from .run files or source, unless you are 100% sure that it is involved and called upon.

Re: VirtualBox removal/update - Help

Posted: 24. Apr 2009, 03:47
by lkraemer
Sasquatch,
THANK YOU for that information. It was just what I needed.

Thanks.

lkraemer