forum/How do I get rid of a wrong remote uuid?git-annexhttp://git-annex.branchable.com/forum/How_do_I_get_rid_of_a_wrong_remote_uuid__63__/git-annexikiwiki2014-03-14T18:11:52Zcomment 1http://git-annex.branchable.com/forum/How_do_I_get_rid_of_a_wrong_remote_uuid__63__/comment_1_b3c215cedba51fb47992ef10c60d6acc/Alan Schmitt2014-03-08T06:42:29Z2014-03-08T06:42:29Z
If it helps, I had a look at "git annex vicfg", and there is no mention of the extra UUID there.
comment 2http://git-annex.branchable.com/forum/How_do_I_get_rid_of_a_wrong_remote_uuid__63__/comment_2_85415e1fceb737919cc1cd9f37242458/joeyh.name2014-03-12T19:35:26Z2014-03-12T19:35:26Z
<p>Probably this will fix it:</p>
<p><code>git annex dead 70582c7b-0b57-4087-a9d1-77b5f5f3c75e</code></p>
comment 3http://git-annex.branchable.com/forum/How_do_I_get_rid_of_a_wrong_remote_uuid__63__/comment_3_fb3a591dc60182f7922fc2b5c24f50f1/Alan Schmitt2014-03-13T23:35:39Z2014-03-13T20:05:53Z
<p>Unfortunately git annex tells me there is no such remote:</p>
<pre><code>cody:games schmitta$ git annex dead 70582c7b-0b57-4087-a9d1-77b5f5f3c75e
dead 70582c7b-0b57-4087-a9d1-77b5f5f3c75e git-annex: there is no available git remote named "70582c7b-0b57-4087-a9d1-77b5f5f3c75e"
</code></pre>
comment 4http://git-annex.branchable.com/forum/How_do_I_get_rid_of_a_wrong_remote_uuid__63__/comment_4_aed0be32e579c7a39c63aa7e3ec5f67b/joeyh.name2014-03-14T17:50:20Z2014-03-14T17:46:23Z
<p>It seems that the git-annex branch's uuid.log must somehow not list this uuid, but it's used in the location tracking log files.</p>
<p>The only way I can think of that this could happen is if you had set up a repository, run git-annex init, and then went in and changed the annex.uuid setting to this other uuid, and added files with that misconfiguration. Does that sound like what happened?</p>
<p>The fix is just as evil as the cause -- you can edit .git/config to add a new, dummy git remote that has annex-uuid set to the problem uuid, and then <code>git-annex dead</code> can be used to kill the uuid via that remote. For example:</p>
<div class="highlight-sh"><pre class="hl">joey@darkstar<span class="hl opt">:</span>~<span class="hl opt">/</span>tmp<span class="hl opt">/</span>x<span class="hl opt">></span>git annex <span class="hl kwc">whereis</span> eep
<span class="hl kwc">whereis</span> eep <span class="hl opt">(</span><span class="hl num">1</span> copy<span class="hl opt">)</span>
<span class="hl num">00000</span>a6d-e770-4ab9-a640-7d6272e9ffff
ok
joey@darkstar<span class="hl opt">:</span>~<span class="hl opt">/</span>tmp<span class="hl opt">/</span>x<span class="hl opt">></span>git annex dead <span class="hl num">00000</span>a6d-e770-4ab9-a640-7d6272e9ffff
dead <span class="hl num">00000</span>a6d-e770-4ab9-a640-7d6272e9ffff git-annex<span class="hl opt">:</span> there is no available git remote named <span class="hl str">"00000a6d-e770-4ab9-a640-7d6272e9ffff"</span>
<span class="hl opt">-</span> <span class="hl kwb">exit</span> <span class="hl num">1</span>
joey@darkstar<span class="hl opt">:</span>~<span class="hl opt">/</span>tmp<span class="hl opt">/</span>x<span class="hl opt">></span>git remote add dummy dummy
joey@darkstar<span class="hl opt">:</span>~<span class="hl opt">/</span>tmp<span class="hl opt">/</span>x<span class="hl opt">></span>git config remote.dummy.annex-uuid <span class="hl num">00000</span>a6d-e770-4ab9-a640-7d6272e9ffff
joey@darkstar<span class="hl opt">:</span>~<span class="hl opt">/</span>tmp<span class="hl opt">/</span>x<span class="hl opt">></span>git annex dead dummy
dead dummy ok
<span class="hl opt">(</span>Recording state <span class="hl kwa">in</span> git...<span class="hl opt">)</span>
joey@darkstar<span class="hl opt">:</span>~<span class="hl opt">/</span>tmp<span class="hl opt">/</span>x<span class="hl opt">></span>git annex <span class="hl kwc">whereis</span> eep
<span class="hl kwc">whereis</span> eep <span class="hl opt">(</span><span class="hl num">0</span> copies<span class="hl opt">)</span> failed
</pre></div>
comment 5http://git-annex.branchable.com/forum/How_do_I_get_rid_of_a_wrong_remote_uuid__63__/comment_5_0c9a6c8a92d6c6e04ae3a8349b799c60/Alan Schmitt2014-03-14T18:11:52Z2014-03-14T18:11:52Z
<p>Thanks, it worked!</p>
<p>Regarding how I got into that state, here is what happened:
- I configured a new repository (git init, git annex init) on machine B
- I added that repository as a remote from machine A
- I started pushing files from machine A to machine B, starting with the file that later showed this problem
- I then noticed that, although the files were said to be successfully sent, I could not see them on machine B (no symbolic link was created), even after a "git annex sync" there
- I decided to start over, deleting the annex, and creating it from a clone of an existing annex
- This resulted in a duplicated UUID for the same path, which led to this problem</p>
<p>Maybe some documentation on how to cleanly start over when things get in a bad state would be very useful.</p>
<p>Thanks again,</p>
<p>Alan</p>