Cannot push over sftp when parents of remote directory are not readable

Bug #322070 reported by wouter bolsterlee
2
Affects Status Importance Assigned to Milestone
Bazaar
Confirmed
Low
Unassigned

Bug Description

I'm trying to push a branch over sftp to sftp://hostname/home/u/uws/dir/subdir, but Bazaar fails with this message:

  bzr: ERROR: Permission denied: "/home/u/.bzr/branch-format": [Errno 13] Permission denied

My home directory on the remote machine is /home/u/uws, not /home/uws. Also, Bazaar is not installed on the remote machine.

The directories /home and /home/u cannot be read/listed by me.

Revision history for this message
Jelmer Vernooij (jelmer) wrote : Re: [Bug 322070] [NEW] Cannot push over sftp when remote homedir is not in /home/$USER format

On Tue, 2009-01-27 at 21:48 +0000, Wouter Bolsterlee (uws) wrote:
> Public bug reported:
>
> I'm trying to push a branch over sftp to
> sftp://hostname/home/u/uws/dir/subdir, but Bazaar fails with this
> message:
>
> bzr: ERROR: Permission denied: "/home/u/.bzr/branch-format": [Errno
> 13] Permission denied
>
> My home directory on the remote machine is /home/u/uws, not /home/uws.
> Also, Bazaar is not installed on the remote machine.
Does any bzr branch exist yet on the remote host? If not, I would guess
bzr is looking for a repository to put the branch in.

It should probably ignore this error when looking for repositories. And
to make sure that we don't accidently skip repositories, I think
Martin's suggestion to print the repository that's being used would be
very useful here.

Cheers,

Jelmer

--
Jelmer Vernooij <email address hidden> - http://samba.org/~jelmer/
Jabber: <email address hidden>

Revision history for this message
wouter bolsterlee (wbolster) wrote : Re: Cannot push over sftp when remote homedir is not in /home/$USER format

No, there is no repository or branch on the remote machine. /home/u/uws/dir already existed, but /home/u/uws/dir/subdir did not.

Revision history for this message
wouter bolsterlee (wbolster) wrote :

Ah, the culprit is that the parent directories cannot be read by me:

$ ls -ald /home /home/u
drwxr-xr-x 38 root wheel 512 2008-09-26 15:27 /home
dr-xr-xr-x 2 root wheel 512 2009-01-27 23:21 /home/u

description: updated
Revision history for this message
wouter bolsterlee (wbolster) wrote :

This makes more sense, since the directory permissions do not really reflect what I'm experiencing:

$ ls -al /home/u/.bzr /home/.bzr /.bzr
ls: cannot access /home/u/.bzr: Permission denied
ls: cannot access /home/.bzr: No such file or directory
ls: cannot access /.bzr: No such file or directory

The machine I'm trying to push to is a shell server operated by a large Dutch ISP with advanced network storage disks (auto)mounted over NFS (I think, the machine is pretty much locked down).

Revision history for this message
Vincent Ladeuil (vila) wrote :

bzr should handle the permission denied error and create a standalone branch, this permission layout is valid.

Changed in bzr:
status: New → Confirmed
importance: Undecided → Low
Jelmer Vernooij (jelmer)
tags: added: check-for-breezy
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.