Merge branch 'master' of ssh://git-annex.branchable.com
This commit is contained in:
		
				commit
				
					
						1f8a1f843c
					
				
			
		
					 10 changed files with 274 additions and 1 deletions
				
			
		
							
								
								
									
										121
									
								
								doc/bugs/4.20130601_xmpp_sync_error.mdwn
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										121
									
								
								doc/bugs/4.20130601_xmpp_sync_error.mdwn
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,121 @@
 | 
			
		|||
4.20130601 xmpp sync error.
 | 
			
		||||
 | 
			
		||||
setup: A debian machine, with indirect fresh annex, android galaxy s3 with a
 | 
			
		||||
fresh direct annex, both running ga-20130601.
 | 
			
		||||
 | 
			
		||||
steps:
 | 
			
		||||
- Start assistant on both, add jabber account to both.
 | 
			
		||||
- Add box.com account on desktop with no encryption, (now correctly shows up on android, wasn't the case with 20130521).
 | 
			
		||||
- Add hello.txt on desktop repo, filename is now visible on android, but content is not.
 | 
			
		||||
- Add greeting.txt on desktop, nothing shows up on android, content still missing for hello.txt
 | 
			
		||||
- Webapp shows uploading messages, but no errors.
 | 
			
		||||
- Manually checking box.com confirms that files have been uploaded.
 | 
			
		||||
 | 
			
		||||
debian desktop daemon.log:
 | 
			
		||||
 | 
			
		||||
    [2013-06-02 17:57:03 CEST] main: starting assistant version 4.20130601
 | 
			
		||||
    (scanning...) [2013-06-02 17:57:03 CEST] Watcher: Performing startup scan
 | 
			
		||||
    (started...) [2013-06-02 17:57:52 CEST] XMPPClient: Pairing with myJabberAccount in progress
 | 
			
		||||
    [2013-06-02 17:57:53 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 17:58:03 CEST] XMPPClient: Pairing with myJabberAccount in progress
 | 
			
		||||
    [2013-06-02 17:58:52 CEST] main: Syncing with box.com 
 | 
			
		||||
    warning: Not updating non-default fetch respec
 | 
			
		||||
	
 | 
			
		||||
	Please update the configuration manually if necessary.
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 17:59:53 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:00:02 CEST] Committer: Adding hello.txt
 | 
			
		||||
 | 
			
		||||
    (testing WebDAV server...)
 | 
			
		||||
    add hello.txt (checksum...) [2013-06-02 18:00:02 CEST] Committer: Committing changes to git
 | 
			
		||||
    [2013-06-02 18:00:02 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    Already up-to-date.
 | 
			
		||||
    [2013-06-02 18:00:03 CEST] Committer: Committing changes to git
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:00:03 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
 | 
			
		||||
    
 | 
			
		||||
100%          1.0 B/s 0s
 | 
			
		||||
                        
 | 
			
		||||
[2013-06-02 18:00:19 CEST] Transferrer: Uploaded hello.txt
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:01:53 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:02:04 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:03:53 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:05:10 CEST] Committer: Adding greeting.txt
 | 
			
		||||
    ok
 | 
			
		||||
    (Recording state in git...)
 | 
			
		||||
    (Recording state in git...)
 | 
			
		||||
 | 
			
		||||
    (Recording state in git...)
 | 
			
		||||
    add greeting.txt (checksum...) [2013-06-02 18:05:10 CEST] Committer: Committing changes to git
 | 
			
		||||
    [2013-06-02 18:05:10 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    Already up-to-date.
 | 
			
		||||
    [2013-06-02 18:05:11 CEST] Committer: Committing changes to git
 | 
			
		||||
 | 
			
		||||
    
 | 
			
		||||
100%          9.0 B/s 0s
 | 
			
		||||
                        
 | 
			
		||||
[2013-06-02 18:05:24 CEST] Transferrer: Uploaded greeting.txt
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:06:13 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    ok
 | 
			
		||||
    (Recording state in git...)
 | 
			
		||||
    (Recording state in git...)
 | 
			
		||||
 | 
			
		||||
    (Recording state in git...)
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
 | 
			
		||||
Thanks as always.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
Android daemon.log:
 | 
			
		||||
    [2013-06-02 17:53:07 CEST] main: starting assistant version 4.20130601-g7483ca4
 | 
			
		||||
    (scanning...) [2013-06-02 17:53:07 CEST] Watcher: Performing startup scan
 | 
			
		||||
    (started...) [2013-06-02 17:57:51 CEST] XMPPClient: Pairing with myJabberAccount in progress
 | 
			
		||||
    [2013-06-02 17:57:52 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    Already up-to-date.
 | 
			
		||||
    [2013-06-02 17:58:00 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 17:58:00 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 17:58:02 CEST] XMPPClient: Pairing with myJabberAccount in progress
 | 
			
		||||
    [2013-06-02 17:58:07 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 17:58:07 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 17:58:15 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:00:02 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:00:03 CEST] XMPPReceivePack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:00:04 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    Merge made by the 'recursive' strategy.
 | 
			
		||||
     hello.txt | 1 +
 | 
			
		||||
     1 file changed, 1 insertion(+)
 | 
			
		||||
     create mode 120000 hello.txt
 | 
			
		||||
    [2013-06-02 18:00:05 CEST] Committer: Committing changes to git
 | 
			
		||||
    [2013-06-02 18:00:06 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    Already up-to-date.
 | 
			
		||||
    [2013-06-02 18:00:14 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:00:14 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:00:25 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:02:03 CEST] Committer: Committing changes to git
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:02:04 CEST] XMPPReceivePack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:02:04 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:02:04 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:02:13 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:02:15 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:02:24 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:04:04 CEST] XMPPReceivePack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:05:10 CEST] XMPPReceivePack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:06:12 CEST] Committer: Committing changes to git
 | 
			
		||||
    [2013-06-02 18:06:13 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:06:21 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    [2013-06-02 18:06:21 CEST] XMPPSendPack: Syncing with myJabberAccount 
 | 
			
		||||
    [2013-06-02 18:06:29 CEST] XMPPSendPack: Unable to download files from your other devices. 
 | 
			
		||||
    fatal: The remote end hung up unexpectedly
 | 
			
		||||
    [2013-06-02 18:07:10 CEST] XMPPReceivePack: Unable to download files from your other devices. 
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
thanks
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,73 @@
 | 
			
		|||
### Please describe the problem.
 | 
			
		||||
Trying to apply certain commands - such as 'drop' - to a filename which starts with "-c" instead applies it to all files.  In the instance where I found this, I was using "drop --force" and it caused it to indiscriminately get rid of everything in the directory instead of a single file.
 | 
			
		||||
 | 
			
		||||
### What steps will reproduce the problem?
 | 
			
		||||
1. Make a repository.
 | 
			
		||||
2. Create several files and add them.
 | 
			
		||||
3. Create a file whose name begins with "-c" and add it as well.
 | 
			
		||||
4. Run "git annex drop <fname>" where 'fname' is the file from that last step. 
 | 
			
		||||
 | 
			
		||||
### What version of git-annex are you using? On what operating system?
 | 
			
		||||
4.20130516-gedc4ccd on Arch Linux
 | 
			
		||||
 | 
			
		||||
### Please provide any additional information below.
 | 
			
		||||
 | 
			
		||||
[[!format sh """
 | 
			
		||||
# If you can, paste a complete transcript of the problem occurring here.
 | 
			
		||||
# If the problem is with the git-annex assistant, paste in .git/annex/daemon.log
 | 
			
		||||
 | 
			
		||||
[user@host ~]$ mkdir annex_test
 | 
			
		||||
[user@host ~]$ cd annex_test/
 | 
			
		||||
[user@host annex_test]$ ls
 | 
			
		||||
[user@host annex_test]$ git init
 | 
			
		||||
Initialized empty Git repository in /home/user/annex_test/.git/
 | 
			
		||||
[user@host annex_test]$ git annex init "test"
 | 
			
		||||
init test ok
 | 
			
		||||
(Recording state in git...)
 | 
			
		||||
[user@host annex_test]$ 
 | 
			
		||||
[user@host annex_test]$ echo foo > foo
 | 
			
		||||
[user@host annex_test]$ echo bar > bar
 | 
			
		||||
[user@host annex_test]$ echo baz > baz
 | 
			
		||||
[user@host annex_test]$ echo test > "-c-test"
 | 
			
		||||
[user@host annex_test]$ git annex add *
 | 
			
		||||
add bar (checksum...) ok
 | 
			
		||||
add baz (checksum...) ok
 | 
			
		||||
add foo (checksum...) ok
 | 
			
		||||
(Recording state in git...)
 | 
			
		||||
[user@host annex_test]$ git annex add -c-test 
 | 
			
		||||
add -c-test (checksum...) ok
 | 
			
		||||
(Recording state in git...)
 | 
			
		||||
[user@host annex_test]$ git annex drop -c-test 
 | 
			
		||||
drop -c-test (unsafe) 
 | 
			
		||||
  Could only verify the existence of 0 out of 1 necessary copies
 | 
			
		||||
 | 
			
		||||
  Rather than dropping this file, try using: git annex move
 | 
			
		||||
 | 
			
		||||
  (Use --force to override this check, or adjust annex.numcopies.)
 | 
			
		||||
failed
 | 
			
		||||
drop bar (unsafe) 
 | 
			
		||||
  Could only verify the existence of 0 out of 1 necessary copies
 | 
			
		||||
 | 
			
		||||
  Rather than dropping this file, try using: git annex move
 | 
			
		||||
 | 
			
		||||
  (Use --force to override this check, or adjust annex.numcopies.)
 | 
			
		||||
failed
 | 
			
		||||
drop baz (unsafe) 
 | 
			
		||||
  Could only verify the existence of 0 out of 1 necessary copies
 | 
			
		||||
 | 
			
		||||
  Rather than dropping this file, try using: git annex move
 | 
			
		||||
 | 
			
		||||
  (Use --force to override this check, or adjust annex.numcopies.)
 | 
			
		||||
failed
 | 
			
		||||
drop foo (unsafe) 
 | 
			
		||||
  Could only verify the existence of 0 out of 1 necessary copies
 | 
			
		||||
 | 
			
		||||
  Rather than dropping this file, try using: git annex move
 | 
			
		||||
 | 
			
		||||
  (Use --force to override this check, or adjust annex.numcopies.)
 | 
			
		||||
failed
 | 
			
		||||
git-annex: drop: 4 failed
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# End of transcript or log.
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -6,7 +6,7 @@ locally paired systems, and remote servers with rsync.
 | 
			
		|||
Help me prioritize my work: What special remote would you most like
 | 
			
		||||
to use with the git-annex assistant?
 | 
			
		||||
 | 
			
		||||
[[!poll open=yes 15 "Amazon S3 (done)" 12 "Amazon Glacier (done)" 9 "Box.com (done)" 70 "My phone (or MP3 player)" 18 "Tahoe-LAFS" 7 "OpenStack SWIFT" 28 "Google Drive"]]
 | 
			
		||||
[[!poll open=yes 16 "Amazon S3 (done)" 12 "Amazon Glacier (done)" 9 "Box.com (done)" 70 "My phone (or MP3 player)" 18 "Tahoe-LAFS" 7 "OpenStack SWIFT" 29 "Google Drive"]]
 | 
			
		||||
 | 
			
		||||
This poll is ordered with the options I consider easiest to build
 | 
			
		||||
listed first. Mostly because git-annex already supports them and they
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -0,0 +1,9 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="https://www.google.com/accounts/o8/id?id=AItOawmkBwMWvNKZZCge_YqobCSILPMeK6xbFw8"
 | 
			
		||||
 nickname="develop"
 | 
			
		||||
 subject="I noticed you stopped filing issues on github"
 | 
			
		||||
 date="2013-06-02T10:38:04Z"
 | 
			
		||||
 content="""
 | 
			
		||||
Does that mean the hook is working properly for you properly now?
 | 
			
		||||
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,8 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="http://edheil.wordpress.com/"
 | 
			
		||||
 ip="99.54.57.201"
 | 
			
		||||
 subject="comment 4"
 | 
			
		||||
 date="2013-06-02T20:27:08Z"
 | 
			
		||||
 content="""
 | 
			
		||||
it is, thank you!  working perfectly.
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,8 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="https://www.google.com/accounts/o8/id?id=AItOawmkBwMWvNKZZCge_YqobCSILPMeK6xbFw8"
 | 
			
		||||
 nickname="develop"
 | 
			
		||||
 subject="comment 5"
 | 
			
		||||
 date="2013-06-02T20:29:48Z"
 | 
			
		||||
 content="""
 | 
			
		||||
Good :)
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,8 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="http://id.clacke.se/"
 | 
			
		||||
 nickname="clacke"
 | 
			
		||||
 subject="comment 5"
 | 
			
		||||
 date="2013-06-03T09:03:57Z"
 | 
			
		||||
 content="""
 | 
			
		||||
You are not the only one, Justin. I am just getting into git-annex and I am setting up a glacier remote as I write this.
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,8 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="https://www.google.com/accounts/o8/id?id=AItOawkwjBDXkP9HAQKhjTgThGOxUa1B99y_WRA"
 | 
			
		||||
 nickname="Franck"
 | 
			
		||||
 subject="comment 10"
 | 
			
		||||
 date="2013-06-02T17:23:43Z"
 | 
			
		||||
 content="""
 | 
			
		||||
I updated the C program to simplify it so it uses a static path for `_chrooter`. In the previous version, I suspect that one can play with symlinks and use it to get a root shell. So, if `_chrooter` is not installed in `/opt/bin` this file has to be edited too before compilation.
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,9 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="https://www.google.com/accounts/o8/id?id=AItOawkwjBDXkP9HAQKhjTgThGOxUa1B99y_WRA"
 | 
			
		||||
 nickname="Franck"
 | 
			
		||||
 subject="comment 11"
 | 
			
		||||
 date="2013-06-03T09:55:54Z"
 | 
			
		||||
 content="""
 | 
			
		||||
A last update and I stop spamming this thread: I've implemented access control and simplified customisation. All this has been moved to https://bitbucket.org/franckp/gasp 
 | 
			
		||||
 | 
			
		||||
"""]]
 | 
			
		||||
| 
						 | 
				
			
			@ -0,0 +1,29 @@
 | 
			
		|||
[[!comment format=mdwn
 | 
			
		||||
 username="https://www.google.com/accounts/o8/id?id=AItOawkwjBDXkP9HAQKhjTgThGOxUa1B99y_WRA"
 | 
			
		||||
 nickname="Franck"
 | 
			
		||||
 subject="comment 9"
 | 
			
		||||
 date="2013-06-02T13:14:56Z"
 | 
			
		||||
 content="""
 | 
			
		||||
Hi, I finally succeeded! :-)
 | 
			
		||||
 | 
			
		||||
Here are the main steps:
 | 
			
		||||
 | 
			
		||||
 1. install `debian-chroot` on the NAS
 | 
			
		||||
 2. create an account `gitannex` in Debian
 | 
			
		||||
 3. configure git on this account (this is important otherwise git complains and fails) `git config --global user.email YOUR_EMAIL` and `git config --global user.name YOUR_NAME`
 | 
			
		||||
 4. install `gcc` on the NAS (using `ipkg`)
 | 
			
		||||
 5. download the files here: https://www.dropbox.com/sh/b7z68a730aj3mnm/95nFOzE1QP
 | 
			
		||||
 6. edit `_chrooter` to fit your settings (probably there is nothing to change if your Debian is freshly installed)
 | 
			
		||||
 7. run `make install`, everything goes to `/opt/bin`, if you change this, you should also edit line 17 in file `gasp`
 | 
			
		||||
 8. create an account `gitannex` on the NAS (doesn't need to be the same name as in Debian, but I feel it is easier)
 | 
			
		||||
 9. edit its `.ssh/authorized_keys` to prefix lines as follows `command=\"gasp\" THE_PUBLIC_KEY_AS_USUAL`
 | 
			
		||||
 10. it should work
 | 
			
		||||
 11. the repositories will be in the Debian account, but it's easy to symlink them in the NAS account if you wish
 | 
			
		||||
 | 
			
		||||
The principle is as follows: `command=\"gasp\"` allows to launch `gasp` on SSH connexion instead of the original command given to `ssh`. This command is retrieved by `gasp` and prefixed with `chrooter-` (so, eg, running `ssh git` on the client results in running `chrooter-git` on the NAS). `chrooter-*` commands are symlinks to `chrooter`, this is a setuid root binary that launches `_chrooter`. (This intermediary binary is necessary because `_chrooter` is a script which cannot be setuid, and setuid is required for the chroot and identity change.) Finally, `_chrooter` starts the `debian-chroot` service, chroot to the target dir, changes identity and eventually launches the original command as if it was lauched directly by `gitannex` user in Debian. `_chrooter` and `gasp` are Python scripts, I did not use shell in order to avoid error-prone issues with spaces in arguments (that need to be passed around several times in the process).
 | 
			
		||||
 | 
			
		||||
I'll try now to add command-line parameters to `gasp` in order to restrict the commands that can be run through SSH and the repositories allowed.
 | 
			
		||||
 | 
			
		||||
Cheers,
 | 
			
		||||
Franck
 | 
			
		||||
"""]]
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue