Problems Pushing to personal SFTP server

Asked by Albert Yang

I am currently using Serv-U. When I try pushing a branch to my server with bazaar using sftp, it says the following:

Connecter (version 2.0, client Serv-U_11.0.0.2)
Authentication continues...
Secsh channel 1 opened.
[chan 1] Opened sftp connection (server version 3)
bzr: ERROR: Failure.

However, pushing without using sftp and only normal ftp, or branching with sftp works perfectly fine. May someone please help me solve this problem? Thanks in advance.

EDIT: This is what happens in bzr.log

0.219 bazaar version: 2.4.0
0.219 bzr arguments: [u'push', u'sftp://***:***@192.168.*.**/sftptest']
0.360 looking for plugins in C:/Documents and Settings/gyang/Application Data/bazaar/2.0/plugins
0.360 looking for plugins in C:/Program Files/Bazaar/plugins
0.531 encoding stdout as sys.stdout encoding 'cp936'
0.688 opening working tree 'C:/Documents and Settings/gyang/stuff'
1.219 falling back to default implementation
1.219 failed to load system host keys: [Errno 2] No such file or directory: 'C:\\Documents and Settings\\gyang/.ssh/known_hosts'
[ 5184] 2011-11-11 23:29:29.703 INFO: Connected (version 2.0, client Serv-U_11.0.0.2)
[ 5184] 2011-11-11 23:29:30.937 INFO: Authentication continues...
[ 5184] 2011-11-11 23:29:31.015 INFO: Secsh channel 1 opened.
[ 5184] 2011-11-11 23:29:31.125 INFO: [chan 1] Opened sftp connection (server version 3)
2.906 opening working tree 'C:/Documents and Settings/gyang/stuff'
6.016 creating repository in sftp://***:***@192.168.*.**/sftptest/.bzr/.
10.625 Using fetch logic to copy between CHKInventoryRepository('file:///C:/Documents%20and%20Settings/gyang/stuff/.bzr/repository/')(RepositoryFormat2a()) and CHKInventoryRepository('sftp://***:***@192.168.*.**/sftptest/.bzr/repository/')(RepositoryFormat2a())
10.625 fetching: <PendingAncestryResult heads:frozenset(['<email address hidden>']) repo:CHKInventoryRepository('file:///C:/Documents%20and%20Settings/gyang/stuff/.bzr/repository/')>
11.235 Raising exception with args ('Failure.',)
11.360 Transferred: 1kB (0.1kB/s r:1kB w:0kB)
11.360 Traceback (most recent call last):
  File "bzrlib\commands.pyo", line 946, in exception_to_return_code
  File "bzrlib\commands.pyo", line 1150, in run_bzr
  File "bzrlib\commands.pyo", line 699, in run_argv_aliases
  File "bzrlib\commands.pyo", line 721, in run
  File "bzrlib\cleanup.pyo", line 135, in run_simple
  File "bzrlib\cleanup.pyo", line 165, in _do_with_cleanups
  File "bzrlib\builtins.pyo", line 1204, in run
  File "bzrlib\push.pyo", line 91, in _show_push_branch
  File "bzrlib\branch.pyo", line 1414, in create_clone_on_transport
  File "bzrlib\bzrdir.pyo", line 205, in clone_on_transport
  File "bzrlib\repository.pyo", line 724, in fetch
  File "bzrlib\decorators.pyo", line 217, in write_locked
  File "bzrlib\vf_repository.pyo", line 2497, in fetch
  File "bzrlib\fetch.pyo", line 75, in __init__
  File "bzrlib\fetch.pyo", line 102, in __fetch
  File "bzrlib\fetch.pyo", line 130, in _fetch_everything_for_search
  File "bzrlib\vf_repository.pyo", line 1968, in insert_stream
  File "bzrlib\repository.pyo", line 641, in commit_write_group
  File "bzrlib\repofmt\pack_repo.pyo", line 1711, in _commit_write_group
  File "bzrlib\repofmt\pack_repo.pyo", line 1587, in _commit_write_group
  File "bzrlib\repofmt\groupcompress_repo.pyo", line 753, in _check_new_inventories
  File "bzrlib\repofmt\groupcompress_repo.pyo", line 1333, in _build_interesting_key_sets
  File "bzrlib\repofmt\groupcompress_repo.pyo", line 977, in _iter_inventories
  File "bzrlib\groupcompress.pyo", line 1474, in get_record_stream
  File "bzrlib\groupcompress.pyo", line 1635, in _get_remaining_record_stream
  File "bzrlib\groupcompress.pyo", line 1188, in yield_factories
  File "bzrlib\groupcompress.pyo", line 1430, in _get_blocks
  File "bzrlib\repofmt\pack_repo.pyo", line 2026, in get_raw_records
  File "bzrlib\pack.pyo", line 221, in make_readv_reader
  File "bzrlib\transport\__init__.pyo", line 682, in readv
  File "bzrlib\transport\sftp.pyo", line 457, in _readv
  File "bzrlib\transport\sftp.pyo", line 719, in _translate_io_exception
IOError: Failure.

Question information

Language:
English Edit question
Status:
Expired
For:
Bazaar Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Jelmer Vernooij (jelmer) said :
#1

Can you paste the relevant bits from ~/.bzr.log ?

Revision history for this message
Albert Yang (alberty123) said :
#2

Please define "relevant bits" and is it the log command?

Revision history for this message
Jelmer Vernooij (jelmer) said :
#3

It's the .bzr.log file in your home directory if you're on Linux/Mac.

With relevant bits I mean the section in the log file related to the push command that failed.

Revision history for this message
Albert Yang (alberty123) said :
#4

Would it be in the same location on windows?

Revision history for this message
Albert Yang (alberty123) said :
#5

0.219 bazaar version: 2.4.0
0.219 bzr arguments: [u'push', u'sftp://***:***@192.168.*.**/sftptest']
0.360 looking for plugins in C:/Documents and Settings/gyang/Application Data/bazaar/2.0/plugins
0.360 looking for plugins in C:/Program Files/Bazaar/plugins
0.531 encoding stdout as sys.stdout encoding 'cp936'
0.688 opening working tree 'C:/Documents and Settings/gyang/stuff'
1.219 falling back to default implementation
1.219 failed to load system host keys: [Errno 2] No such file or directory: 'C:\\Documents and Settings\\gyang/.ssh/known_hosts'
[ 5184] 2011-11-11 23:29:29.703 INFO: Connected (version 2.0, client Serv-U_11.0.0.2)
[ 5184] 2011-11-11 23:29:30.937 INFO: Authentication continues...
[ 5184] 2011-11-11 23:29:31.015 INFO: Secsh channel 1 opened.
[ 5184] 2011-11-11 23:29:31.125 INFO: [chan 1] Opened sftp connection (server version 3)
2.906 opening working tree 'C:/Documents and Settings/gyang/stuff'
6.016 creating repository in sftp://albert@192.168.1.99/sftptest/.bzr/.
10.625 Using fetch logic to copy between CHKInventoryRepository('file:///C:/Documents%20and%20Settings/gyang/stuff/.bzr/repository/')(RepositoryFormat2a()) and CHKInventoryRepository('sftp://albert@192.168.1.99/sftptest/.bzr/repository/')(RepositoryFormat2a())
10.625 fetching: <PendingAncestryResult heads:frozenset(['<email address hidden>']) repo:CHKInventoryRepository('file:///C:/Documents%20and%20Settings/gyang/stuff/.bzr/repository/')>
11.235 Raising exception with args ('Failure.',)
11.360 Transferred: 1kB (0.1kB/s r:1kB w:0kB)
11.360 Traceback (most recent call last):
  File "bzrlib\commands.pyo", line 946, in exception_to_return_code
  File "bzrlib\commands.pyo", line 1150, in run_bzr
  File "bzrlib\commands.pyo", line 699, in run_argv_aliases
  File "bzrlib\commands.pyo", line 721, in run
  File "bzrlib\cleanup.pyo", line 135, in run_simple
  File "bzrlib\cleanup.pyo", line 165, in _do_with_cleanups
  File "bzrlib\builtins.pyo", line 1204, in run
  File "bzrlib\push.pyo", line 91, in _show_push_branch
  File "bzrlib\branch.pyo", line 1414, in create_clone_on_transport
  File "bzrlib\bzrdir.pyo", line 205, in clone_on_transport
  File "bzrlib\repository.pyo", line 724, in fetch
  File "bzrlib\decorators.pyo", line 217, in write_locked
  File "bzrlib\vf_repository.pyo", line 2497, in fetch
  File "bzrlib\fetch.pyo", line 75, in __init__
  File "bzrlib\fetch.pyo", line 102, in __fetch
  File "bzrlib\fetch.pyo", line 130, in _fetch_everything_for_search
  File "bzrlib\vf_repository.pyo", line 1968, in insert_stream
  File "bzrlib\repository.pyo", line 641, in commit_write_group
  File "bzrlib\repofmt\pack_repo.pyo", line 1711, in _commit_write_group
  File "bzrlib\repofmt\pack_repo.pyo", line 1587, in _commit_write_group
  File "bzrlib\repofmt\groupcompress_repo.pyo", line 753, in _check_new_inventories
  File "bzrlib\repofmt\groupcompress_repo.pyo", line 1333, in _build_interesting_key_sets
  File "bzrlib\repofmt\groupcompress_repo.pyo", line 977, in _iter_inventories
  File "bzrlib\groupcompress.pyo", line 1474, in get_record_stream
  File "bzrlib\groupcompress.pyo", line 1635, in _get_remaining_record_stream
  File "bzrlib\groupcompress.pyo", line 1188, in yield_factories
  File "bzrlib\groupcompress.pyo", line 1430, in _get_blocks
  File "bzrlib\repofmt\pack_repo.pyo", line 2026, in get_raw_records
  File "bzrlib\pack.pyo", line 221, in make_readv_reader
  File "bzrlib\transport\__init__.pyo", line 682, in readv
  File "bzrlib\transport\sftp.pyo", line 457, in _readv
  File "bzrlib\transport\sftp.pyo", line 719, in _translate_io_exception
IOError: Failure.

That seems to be the error, is there a possible fix?

Revision history for this message
Albert Yang (alberty123) said :
#6

I've noticed that after i push it creates the branch folder and some files in the .bzr folder, but it does not finish and then it fails.

Revision history for this message
Launchpad Janitor (janitor) said :
#7

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Martin Packman (gz) said :
#8

One possibility is that the sftp server is not giving specific enough error returns for certain filesystem operation failures for bzr to interpret the state correctly, that's a problem with some ftp servers at least, which we've got around in the past by sniffing for exact strings. If you can get a log from the server side of what it's sending, that may allow you to add a check along those lines.