[opensuse] Re: Unlocking a locked file
Stan Goodman wrote:
My VirtualBox program has become corrupted, and I wish to remove it and start over again from scratch. At the moment, it won't start at all. I find that reinstalling over what is there is not permitted, because there is a locked file. How can I unlock this file?
This is not the ose version of the program, I downloaded it from the VBox site.
This is what happens when I try to uninsstall: # rpm -e VirtualBox* error: package VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm is not installed
This will never work; since there is no package with the same name as the RPM. As others have posted, the correct command to remove VirtualBox is rpm -e VirtualBox-3.1
On the other hand, here is what happens when I try to reinstall: # rpm -U VirtualBox* warning: VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm: Header V4 DSA signature: NOKEY, key ID 6dfbcbae package VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64 is already installed #
When I try to reinstall from the user prompt, the response is: rpm -U VirtualBox* warning: VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm: Header V4 DSA signature: NOKEY, key ID 6dfbcbae error: can't create transaction lock on /var/lib/rpm/__db.000
Normally, this error message means that the command is not run as root. Since you quote your prompt as '#', I assume you are root. Then your RPM database is hosed. This is *not* a problem with VirtualBox or with the VirtualBox rpm. First, check that no rpm command is still running. ps -ef | grep rpm should show the grep command at max. Remove /var/lib/rpm/__db.000. Check if rpm -q 'VirtualBox*' outputs information about an installed VirtualBox. If yes, try rpm -e VirtualBox-3.1 If that still does not succeed, reestablish rpm's Packages database from backup: The backups are in /var/adm/backup/rpmdb. Take the last one that has a date before the start of your problems and gunzip it. (If it's the very last one in that directory, it should be identical to /var/lib/rpm/Packages.) Make a backup copy of your current /var/lib/rpm/Packages and then replace it with that file. Run rpm query and remove commands again, as cited above. Tell us if you succeeded. :-) Joachim -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Joachim Schrod Email: jschrod@acm.org Roedermark, Germany -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
At 11:53:49 on Tuesday Tuesday 16 March 2010, Joachim Schrod <jschrod@acm.org> wrote:
Stan Goodman wrote:
My VirtualBox program has become corrupted, and I wish to remove it and start over again from scratch. At the moment, it won't start at all. I find that reinstalling over what is there is not permitted, because there is a locked file. How can I unlock this file?
This is not the ose version of the program, I downloaded it from the VBox site.
This is what happens when I try to uninsstall: # rpm -e VirtualBox* error: package VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm is not installed
This will never work; since there is no package with the same name as the RPM. As others have posted, the correct command to remove VirtualBox is
rpm -e VirtualBox-3.1
That produced the reponse: # rpm -e VirtualBox-3.1 insserv: script lpd: service cupsd already provided! insserv: script portmap: service portmap already provided! running the same command again got: # rpm -e VirtualBox-3.1 error: package VirtualBox-3.1 is not installed
On the other hand, here is what happens when I try to reinstall: # rpm -U VirtualBox* warning: VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm: Header V4 DSA signature: NOKEY, key ID 6dfbcbae package VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64 is already installed #
When I try to reinstall from the user prompt, the response is: rpm -U VirtualBox* warning: VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm: Header V4 DSA signature: NOKEY, key ID 6dfbcbae error: can't create transaction lock on /var/lib/rpm/__db.000
Normally, this error message means that the command is not run as root. Since you quote your prompt as '#', I assume you are root.
I was root at the time I ran it. But as you see, I ran the command both ways.
Then your RPM database is hosed. This is *not* a problem with VirtualBox or with the VirtualBox rpm.
First, check that no rpm command is still running. ps -ef | grep rpm should show the grep command at max.
ps -ef | grep rpm stan 7000 6758 0 12:31 pts/1 00:00:00 grep rpm
Remove /var/lib/rpm/__db.000
Done.
Check if rpm -q 'VirtualBox*'
Not installed.
Tell us if you succeeded. :-)
# rpm -U VirtualBox-3.1* warning: VirtualBox-3.1-3.1.4_57640_openSUSE111-1.x86_64.rpm: Header V4 DSA signature: NOKEY, key ID 6dfbcbae Creating group 'vboxusers'. VM users must be member of that group! insserv: script lpd: service cupsd already provided! insserv: script portmap: service portmap already provided! No precompiled module for this kernel found -- trying to build one. Messages emitted during module compilation will be logged to /var/log/vbox-install.log. Success! WARNING: Can't read module /lib/modules/2.6.27.45-0.1-default/weak-updates/updates/vboxvfs.ko: No such file or directory WARNING: Can't read module /lib/modules/2.6.27.45-0.1-default/weak-updates/updates/vboxadd.ko: No such file or directory # find -name "vbox*.ko" ./lib/modules/2.6.27.45-0.1-default/misc/vboxnetadp.ko ./lib/modules/2.6.27.45-0.1-default/misc/vboxnetflt.ko ./lib/modules/2.6.27.45-0.1-default/misc/vboxdrv.ko ./lib/modules/2.6.27.45-0.1-default/weak-updates/updates/vboxvfs.ko ./lib/modules/2.6.27.45-0.1-default/weak-updates/updates/vboxadd.ko ./lib/modules/2.6.27.39-0.2-default/misc/vboxnetadp.ko ./lib/modules/2.6.27.39-0.2-default/misc/vboxnetflt.ko ./lib/modules/2.6.27.39-0.2-default/misc/vboxdrv.ko ./lib/modules/2.6.27.39-0.2-trace/misc/vboxnetadp.ko ./lib/modules/2.6.27.39-0.2-trace/misc/vboxnetflt.ko ./lib/modules/2.6.27.39-0.2-trace/misc/vboxdrv.ko ./lib/modules/2.6.27.39-0.2-debug/misc/vboxnetadp.ko ./lib/modules/2.6.27.39-0.2-debug/misc/vboxnetflt.ko ./lib/modules/2.6.27.39-0.2-debug/misc/vboxdrv.ko ./lib/modules/2.6.27.45-0.1-trace/weak-updates/updates/vboxvfs.ko ./lib/modules/2.6.27.45-0.1-trace/weak-updates/updates/vboxadd.ko ./lib/modules/2.6.27.42-0.1-trace/updates/vboxvfs.ko ./lib/modules/2.6.27.42-0.1-trace/updates/vboxadd.ko So the "missing" files are indeed present. Why does VB think otherwise? -- Stan Goodman Qiryat Tiv'on Israel -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 2010-03-16 19:49, Stan Goodman wrote:
At 11:53:49 on Tuesday Tuesday 16 March 2010, Joachim Schrod <> wrote:
This will never work; since there is no package with the same name as the RPM. As others have posted, the correct command to remove VirtualBox is
rpm -e VirtualBox-3.1
That produced the reponse: # rpm -e VirtualBox-3.1 insserv: script lpd: service cupsd already provided! insserv: script portmap: service portmap already provided!
That is correct, no error. At least, not in the uninstall. The uninstall process is first stopping and removing the startup scripts, and hinting at some unrelated problem or warning.
running the same command again got: # rpm -e VirtualBox-3.1 error: package VirtualBox-3.1 is not installed
Correct, as it suceeded the first time.
Normally, this error message means that the command is not run as root. Since you quote your prompt as '#', I assume you are root.
I was root at the time I ran it. But as you see, I ran the command both ways.
As you didn't get an error this time, my guess is that it was a temporary problem that time. Not now. - -- Cheers / Saludos, Carlos E. R. (from 11.2 x86_64 "Emerald" GM (Minas Tirith)) -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org/ iF4EAREIAAYFAkuf6IYACgkQja8UbcUWM1xGKQD9Eoq0rnY6I/6nK3CttsWEhiHu KUPv78FC/HSl1Xn0rf0A/iPFK/QdTg+4ArBELUt/Xrul+2evrWIc0kboKNBZ3FOv =mZRa -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (3)
-
Carlos E. R.
-
Joachim Schrod
-
Stan Goodman