Strange break-lock output

Bug #57871 reported by Robert Collins
2
Affects Status Importance Assigned to Milestone
Bazaar
New
Undecided
Unassigned

Bug Description

Reported on IRC:
$ bzr break-lock sftp://bazaar.launchpad.net/%7Eharmony-dev/harmony/addressbook/
Break lock <bzrlib.transport.sftp.SFTPTransport
  url=sftp://bazaar.launchpad.net/%7Eharmony-dev/harmony/addressbook/.bzr/branch/>
  held by XXXX@supernova [process #11627]? [y/n]:y
bzr: ERROR: exceptions.IOError: rmdir failed at
/usr/lib/python2.4/site-packages/bzrlib/transport/sftp.py line 540 in _translate_io_exception

 affects /products/bzr

-Rob

--
GPG key available at: <http://www.robertcollins.net/keys.txt>.

Revision history for this message
Wouter van Heyst (larstiq) wrote : Re: [Bug 57871] Strange break-lock output

On Sun, Aug 27, 2006 at 10:20:12AM -0000, Robert Collins wrote:
> Public bug reported:
>
> Reported on IRC:
> $ bzr break-lock sftp://bazaar.launchpad.net/%7Eharmony-dev/harmony/addressbook/
> Break lock <bzrlib.transport.sftp.SFTPTransport
> url=sftp://bazaar.launchpad.net/%7Eharmony-dev/harmony/addressbook/.bzr/branch/>
> held by XXXX@supernova [process #11627]? [y/n]:y
> bzr: ERROR: exceptions.IOError: rmdir failed at
> /usr/lib/python2.4/site-packages/bzrlib/transport/sftp.py line 540 in _translate_io_exception
>

Perhaps worth to note, before that it gave:

    bzr push
    Using saved location: sftp://bazaar.launchpad.net/~harmony-dev/harmony/addressbook
    bzr: ERROR: Lock was broken while still open: LockDir(sftp://bazaar.launchpad.net/%7Eharmony-dev/harmony/addressbook/.bzr/branch/lock) - check storage consistency!

Wouter van Heyst

Revision history for this message
Andrew Bennetts (spiv) wrote :

The server logs say this is due to "Directory not empty" when trying to RMDIR
".bzr/branch/lock/broken.n3od98yk38yj7r95805y.tmp".

That directory contains 8 subdirectories, all named
pending.2nro740p0ilbgxa7doum.tmp or similar, which in turn contain files named
"info". The info files all look like:

hostname: supernova
nonce: 0rl1xw2flyst003uzbg0
pid: 25261
start_time: 1156620866
user: XXXX@XXXX

(the nonce, pid and start_time all vary from file to file).

Let me know if you need further info.

Revision history for this message
Alexander Belchenko (bialix) wrote :

I'm often have similar error messages when I try to push to sftp://launchpad.net and my dial-up is suddenly disconnected.
Usually after running break-lock command all works normal. (But I don't check of existence of 'pending' files/dirs). So what status of this issue now?

Revision history for this message
John A Meinel (jameinel) wrote :

This is at least partly related to bug 87934.

The reason the "rmdir" fails, is because the other lock attempt is renaming its "pending.*" directory *into* lock/ instead of failing to rename it *to* lock/.

That is certainly Wouter's "Lock was broken while still open". Because it cannot find the "pending" directory after the rename puts it in the wrong place.

Can we confirm that it is just bug 87934, and then mark this as a duplicate?

Revision history for this message
Robert Collins (lifeless) wrote : Re: [Bug 57871] Re: Strange break-lock output

On Wed, 2007-04-25 at 13:37 +0000, John A Meinel wrote:
>
> The reason the "rmdir" fails, is because the other lock attempt is
> renaming its "pending.*" directory *into* lock/ instead of failing to
> rename it *to* lock/.

I thought we had tests about this.

I wonder if its a launchpad sftp server bug?

-Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.

Revision history for this message
John A Meinel (jameinel) wrote :

Robert-

That is why I pointed to bug 87934. Which is the Launchpad-Bazaar SFTP server rename bug. (Which turns out to be a bug in Twisted's SFTP adapter, which JML has already created a possible patch for).
I don't know what it takes to get it put into Launchpad (does it have to be approved by Twisted, and have them make a new release?)

Anyway, I would be happy to say that this bug is just a duplicate of bug 87934, but I wanted someone else's feedback.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.