|
|
Darren New escribió:
> Jim Henderson wrote:
>> On Sun, 04 Nov 2007 09:30:30 -0800, Darren New wrote:
>>
>>> No, actually. Something like "could not aquire package directory lock".
>>> If it said "you must be root" I wouldn't have had to try several times
>>> and wander around looking for where said lock might be in order to
>>> install the software.
>>
>> Oh, right, that is what it says - unable to lock database or unable to
>> get exclusive lock.
>>
>> I hit that every once in a while, but know that it means "yo, idiot,
>> you're not root!" - using the YaST software installer prompts you to
>> login; using Red Carpet would allow you to set rights, so I'd either
>> use rug or yast2 myself...
>
> Well, yeah, I do now. I mean, I learned what it meant. Would it really
> have been that hard to put
> if (euid() != 0) {
> fprintf(stderr, "You gotta be root!\n");
> exit(1);
> }
> at the start of the code?
>
Debian's dpkg message:
E: Could not open lock file /var/lib/dpkg/lock - open (13 Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you
root?
Doesn't even check for the userid; but it assumes the most common reason
for failing to acquire the lock is because of running it as non-root,
and mentions it.
Post a reply to this message
|
|