FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
FIX, warning:, cannot, get, exclusive, lock, on, /var/lib/rpm/Packages


Fri Feb 29, 2008 12:01 pm - FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
#783
FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
author: stalionboy
Leave Your Comments
name
comments
Share
Share this post by copy and paste this URL and put it on your forums or use it on your profile like myspace, friendster, Facebook, Twitter or others and add in with your comments.
URL Link: ask
Use this HTML code to embed this topic, just copy the code from the "Embed" box. Once you've copied the code, just paste it into your website or blog to embed it.
Embed: ask
BBCODE is use on forums. You can put this code on all your BBCODE enabled forums like PhpBB, vBulletin® and others. Just Copy and Paste this code on with Posts and Replies on your forums
BBCODE: ask
| More
Fri Jul 21, 2006 8:27 am - Re: FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
#979
stalionboy
this means your file is being used by another user(locked). Make sure if you are logged in twice into the same machine with the same user, you close one of the sessions.

For example, we had a customer who was logged in twice with root from from different computers using his SSH. He was at work logged in, and he remembered that he also was logged in when he left home from work. So that meant he was logged in as root from home using a SSH connection, and when he got to work, he also logged in as root . When he tried to use the same file (httpd.conf) from work, he couldn't because his session at home was also using the file httpd.conf.

He needed to have his computer the home release the httpd.conf file. But since he was at work, he couldn't do that. The only suggestion we could provide was to reboot the server remotely from work. After he did that, the server rebooted and all the connections (users loggedin) were dropped. When the server rebooted, he logged in with SSH and was able to edit his httpd.conf file.

so basically, if you are getting this error, its because the file is being used by another user. If you are stuck with this issue, do a reboot and that should clear your problem.
Thu Jan 10, 2008 8:01 pm - Re: FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
#980
ramank
above method of rebooting the machine seems to be difficult when we don't have access to do so.
is there any method or configuration that can solve this problem which provides multiple login from the same user.
Tue Sep 29, 2009 11:04 pm - Re: FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
#2461
Sebi
Use this...
rpm --rebuilddb

Thanks,
Sebi
Sat Nov 07, 2009 9:03 pm - Re: FIX warning: cannot get exclusive lock on /var/lib/rpm/Packages
#2747
asnkighs
what is the use of /var/lock/rpm can you explain please? once you have explained it to me i can understand what you people are talking about