Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

mbsync error: UID is beyond highest assigned UID

Tags:

emacs

mbsync

I'm using emacs 24.5.1 on OSX with mu4e and mbsync. I'm synchronising with my imac and laptop so maybe it's the same error as mentioned here, but no one has posted a solution.

My specific error is that during the sync I'm receiving the following:

mbsync error: UID is 3 beyond highest assigned UID 1
mbsync error: UID is 7 beyond highest assigned UID 6

Any ideas on what's causing this and how to solve it?

like image 572
rev Avatar asked Sep 15 '16 14:09

rev


2 Answers

I was able to fix this by editing the .uidvalidity file in the folder(s) in question; the second line is the maximum value U= filename. So I just changed this to match and it synced perfectly.

like image 179
EkriirkE Avatar answered Sep 22 '22 17:09

EkriirkE


In yourMaildir/INBOX/cur folder (or Maildir/otherfolder/cur), there'll be a file named something like 1568901502.26338_1.hostname,U=3:2,S. You can strip off everything from the ,U= from that filename and resync and it should be fine, e.g.

mv '1568901502.26338_1.hostname,U=3:2,S' '1568901502.26338_1.hostname'

This also solves the duplicate UID error. See http://tiborsimko.org/mbsync-duplicate-uid.html for more info.

This has worked for me – but since mbsync doesn't do it automatically there may be some good reason, so take a backup before you try :)

like image 25
unhammer Avatar answered Sep 24 '22 17:09

unhammer