----- Forwarded message from Ivan Raikov <[EMAIL PROTECTED]> -----

From: Ivan Raikov <[EMAIL PROTECTED]>
To: Daniel Burrows <[EMAIL PROTECTED]>
Subject: Re: Bug#352721: aptitude: Ctrl-c aborts without cleaning lock files
Date: Fri, 24 Feb 2006 00:45:24 -0500


   Fix it so that it cleans the lock files upon interruption with
Ctrl-C. Otherwise, if aptitude is killed with Ctrl-C and started
again, it produces the following error messages:

E: Could not get /var/lib/dpkg/lock - open (11 Resource temporarily
unavailable) 

E: Unable to lock the administration directory (/var/lib/dpkg), is
another process using it?

W: Could not lock the cache file. Opening in read only mode; any
changes you make to the states of packages will not be preserved.


Daniel Burrows <[EMAIL PROTECTED]> writes:

> On Mon, Feb 13, 2006 at 03:04:31PM -0500, Ivan Raikov <[EMAIL PROTECTED]> was 
> heard to say:
>> After a recent upgrade of aptitude, I discovered that if I run it with
>> sudo, and interrupt it using Ctrl-C, it doesn't clean the lock files
>> /var/lib/dpkg/lock and /var/lib/aptitude/lock. This used to work --
>> Ctrl-C would cause a graceful exit. Please consider fixing the Ctrl-C
>> handler accordingly. Thanks,
>
>   Umm, fix it to do what?
>
>   Daniel

-- 
"I think we need to transition to a non magic fish based economy."
                      --Phil Hartman, SNL

----- End forwarded message -----
----- Forwarded message from Ivan Raikov <[EMAIL PROTECTED]> -----

From: Ivan Raikov <[EMAIL PROTECTED]>
To: Daniel Burrows <[EMAIL PROTECTED]>
Subject: Re: Bug#352721: aptitude: Ctrl-c aborts without cleaning lock files
Date: Fri, 24 Feb 2006 01:38:13 -0500


   ps showed that there were two aptitude processes running. After
killing the processes, the problem went away. So there must be some
situation when aptitude is not killed when Ctrl-C is pressed.  Thanks
for the constructive feedback.

         -Ivan


Daniel Burrows <[EMAIL PROTECTED]> writes:

>   aptitude does not test for the existence of a lock file; it tests for
> the existence of a fcntl lock on the lock file.  When a program is killed,
> all its fcntl locks are destroyed by the kernel.  In fact, these lock files
> are not removed by apt, dpkg or aptitude and have never been that I know of.
>
>   If removing the lock files fixes your problem, this suggests to me that
> the bug is that you have some process hanging around in the background that
> has a lock on the file and isn't being killed by the ^C.  Could you please
> send the output of pstree next time this happens?
>
>   (this could also be the return of #328234. but the fact that cleaning
> lock files actually fixes your problem indicates that it probably isn't)
>
>     Thanks,
>   Daniel

-- 
My other car is a cdr. 

----- End forwarded message -----
----- Forwarded message from Ivan Raikov <[EMAIL PROTECTED]> -----

From: Ivan Raikov <[EMAIL PROTECTED]>
To: Daniel Burrows <[EMAIL PROTECTED]>
Subject: Re: Bug#352721: aptitude: Ctrl-c aborts without cleaning lock files
Date: Sat, 25 Feb 2006 19:37:56 -0500


Hi Daniel,

   I have not encountered this problem since I killed the extra
aptitude processes; I just performed a fresh Debian testing
installation and aptitude worked fine, so I think it's safe to say the
problem went away. If I encounter this again, I'll make sure to record
the steps I took, and I'll reopen the bug.

     -Ivan


Daniel Burrows <[EMAIL PROTECTED]> writes:

> On Fri, Feb 24, 2006 at 01:38:13AM -0500, Ivan Raikov <[EMAIL PROTECTED]> was 
> heard to say:
>> 
>>    ps showed that there were two aptitude processes running. After
>> killing the processes, the problem went away. So there must be some
>> situation when aptitude is not killed when Ctrl-C is pressed.  Thanks
>> for the constructive feedback.
>
>   Is this reproducible?  i.e., does it happen every time you ^C aptitude?
>
>   Daniel

----- End forwarded message -----
----- Forwarded message from Ivan Raikov <[EMAIL PROTECTED]> -----

From: Ivan Raikov <[EMAIL PROTECTED]>
To: Daniel Burrows <[EMAIL PROTECTED]>
Subject: Re: Bug#352721: aptitude: Ctrl-c aborts without cleaning lock files
Date: Sun, 26 Feb 2006 14:40:41 -0500


   Yes, that's fine. Thanks for taking the time with this issue.


Daniel Burrows <[EMAIL PROTECTED]> writes:

> On Sat, Feb 25, 2006 at 07:37:56PM -0500, Ivan Raikov <[EMAIL PROTECTED]> was 
> heard to say:
>>    I have not encountered this problem since I killed the extra
>> aptitude processes; I just performed a fresh Debian testing
>> installation and aptitude worked fine, so I think it's safe to say the
>> problem went away. If I encounter this again, I'll make sure to record
>> the steps I took, and I'll reopen the bug.
>
>   Ok, thanks.  Would it be ok if I sent this discussion to the bug log?
>

----- End forwarded message -----
----- Forwarded message from Ivan Raikov <[EMAIL PROTECTED]> -----

From: Ivan Raikov <[EMAIL PROTECTED]>
To: Daniel Burrows <[EMAIL PROTECTED]>
Subject: Re: Bug#352721: aptitude: Ctrl-c aborts without cleaning lock files
Date: Fri, 24 Feb 2006 00:47:05 -0500


   Well, no, a cleanup is quite needed, as aptitude produces error
messages, and I have to clean the lock files by hand.

Daniel Burrows <[EMAIL PROTECTED]> writes:

> On Thu, Feb 23, 2006 at 08:48:12PM -0800, Daniel Burrows <[EMAIL PROTECTED]> 
> was heard to say:
>> On Mon, Feb 13, 2006 at 03:04:31PM -0500, Ivan Raikov <[EMAIL PROTECTED]> 
>> was heard to say:
>> > After a recent upgrade of aptitude, I discovered that if I run it with
>> > sudo, and interrupt it using Ctrl-C, it doesn't clean the lock files
>> > /var/lib/dpkg/lock and /var/lib/aptitude/lock. This used to work --
>> > Ctrl-C would cause a graceful exit. Please consider fixing the Ctrl-C
>> > handler accordingly. Thanks,
>> 
>>   Umm, fix it to do what?
>
>   To be clearer, the lock is just an fcntl lock and dies when the process
> does.  No cleanup is needed.
>
>   Daniel

-- 
Why should I be tarred with the epithet "loony" merely because I have
a pet halibut? --Monty Python

----- End forwarded message -----

Attachment: signature.asc
Description: Digital signature

Reply via email to