LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices


Reply
  Search this Thread
Old 03-03-2005, 07:01 PM   #1
bglnelissen
Member
 
Registered: Feb 2004
Location: Utrecht Holland
Distribution: MacOS, Debian, Raspbian
Posts: 76

Rep: Reputation: 15
Lightbulb Answer on the 'urpmi database locked' message


(i use mandrake 10.1 so plz tell me if it works on other systems with urpmi, i think it does)

while installing programs with urpmi you sometimes get an 'error' which says:
"URPMI DATABASE LOCKED"
This is normal while you're using the database (installing, removing using urpmi)
there are 2 simple lines that solve this problem NEED TO BE ROOT:

# rm -f "/var/lib/urpmi/.LOCK"
# rm -f "/var/lib/urpmi/.RPMLOCK"
Those rules will remove the 'locks' from the RPM database. Only use it when URPMI is NOT installing or removing a program.

To make things easy, and we like things easy, i wrote myself a little script. Open your text editor as root and save the little script as 'urpmi.unlock' in '/usr/bin/'

$ su
password

# kwrite
past the following text in a new file and save it in:
/usr/bin
name it:
urpmi.unlock

from now on the following command will unlock you URPMI DATABASE

# urpmi.unlock

################COPY EVERYTHING UNDER THIS LINE############
Code:
#!/bin/bash
echo "";
echo "Only root can unlock the URPMI database.";
echo "Starting with the removal of URPMI locks:";

rm -f "/var/lib/urpmi/.LOCK";
echo "     rm -f '/var/lib/urpmi/.LOCK'...";
rm -f "/var/lib/urpmi/.RPMLOCK";
echo "     rm -f '/var/lib/urpmi/.RPMLOCK'..." 

echo "URPMI DATABASE UNLOCKED!";
echo "Happy installing!"
echo ""
################DON'T COPY THIS, END OF FILE#################

Last edited by bglnelissen; 03-03-2005 at 07:10 PM.
 
Old 03-04-2005, 02:47 PM   #2
rshaw
Senior Member
 
Registered: Apr 2001
Location: Perry, Iowa
Distribution: Mepis , Debian
Posts: 2,692

Rep: Reputation: 45
moved to mandrake
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
URPMI Database Locked Dooley Mandriva 6 02-07-2006 02:17 AM
urpmi database locked? otto k Mandriva 9 05-17-2005 11:37 AM
urpmi database locked? KiLLaWaBBiT Linux - Software 2 09-06-2004 01:56 AM
urpmi database locked! /home/kyle Mandriva 3 03-09-2004 06:05 AM
urpmi.update --all / urpmi database locked thepoint Mandriva 5 11-05-2003 06:03 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva

All times are GMT -5. The time now is 09:41 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration