Unison produces "Fatal error: Corrupted archive" when switching on/off case sensitiveness

Bug #535211 reported by Leo
20
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Unison
Confirmed
Undecided
Unassigned
unison (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: unison

When a directory contains files whose name bare both capitalized and not capitalized letters (though not the same names, even ignoring case), the Unison archive is created in a way that switching on or off the "ignorecase" flag makes it crash.

Expected:

Unison re-sorts the archive to overcome the new user setting.

It should just proceed comparison normally
(unless "ignorecase" was set to "false" before and now with "ignorecase=true" it happens that two files have the same name, e.g., "AaAaa" and "aaaAA")

Reproducing this bug:

$ mkdir tmp
$ cd tmp
$ mkdir a ; mkdir b
$ ls > a/Aa
$ ls > a/Ee
$ ls > b/a
$ ls > b/e
$ unison a b -ignorecase=false -fastcheck=false
Warning: No archive files were found for these roots, whose canonical names are:
...
This can happen either
because this is the first time you have synchronized these roots,
or because you have upgraded Unison to a new version with a different
archive format.

Update detection may take a while on this run if the replicas are
large.

Unison will assume that the 'last synchronized state' of both replicas
was completely empty. This means that any files that are different
will be reported as conflicts, and any files that exist only on one
replica will be judged as new and propagated to the other replica.
If the two replicas are identical, then no changes will be reported.

If you see this message repeatedly, it may be because one of your machines
is getting its address from DHCP, which is causing its host name to change
between synchronizations. See the documentation for the UNISONLOCALHOSTNAME
environment variable for advice on how to correct this.

Donations to the Unison project are gratefully accepted:
http://www.cis.upenn.edu/~bcpierce/unison

Press return to continue.[<spc>]
a b
file ----> Aa
file ----> Ee
         <---- file a
         <---- file e

Proceed with propagating updates? [] g[BGN] Copying Aa...
[END] Copying Aa
...
[END] Copying e
Synchronization complete (4 items transferred, 0 skipped, 0 failures)
$ unison a b -ignorecase=false -fastcheck=false
$ unison a b -ignorecase=true -fastcheck=false
Fatal error: Corrupted archive: the files are not correctely ordered in directory
$ unison -version
unison version 2.27.57
$

ProblemType: Bug
Architecture: i386
Date: Tue Mar 9 18:51:30 2010
DistroRelease: Ubuntu 9.10
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release i386 (20091028.5)
Package: unison 2.27.57-2ubuntu1
ProcEnviron:
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.31-20.57-generic
SourcePackage: unison
Uname: Linux 2.6.31-20-generic i686

Revision history for this message
Leo (leorolla) wrote :
tags: added: karmic
Leo (leorolla)
description: updated
tags: added: hardy lucid
Revision history for this message
James Dearing (dearingj) wrote :

I'm confirming this bug; it affects me too. I'm running Ubuntu Karmic amd64 with unison (and unison-gtk) version 2.27.57-2ubuntu1.

Changed in unison (Ubuntu):
status: New → Confirmed
Leo (leorolla)
Changed in unison:
status: New → Confirmed
Revision history for this message
cocoa117 (cocoa117) wrote :

I can confirm it as well, I am running 64-bit Lucid, with unison-gtk package, version number 2.27.57

tags: added: maverick
Revision history for this message
Benjamin Pierce (bcpierce) wrote : Re: [Bug 535211] Re: Unison produces "Fatal error: Corrupted archive" when switching on/off case sensitiveness
Download full text (3.3 KiB)

I believe this is fixed in recent versions of Unison.

  - B

On Oct 26, 2010, at 2:37 PM, Bernhard Froehler wrote:

> ** Tags added: maverick
>
> --
> Unison produces "Fatal error: Corrupted archive" when switching on/off case sensitiveness
> https://bugs.launchpad.net/bugs/535211
> You received this bug notification because you are a member of Unison
> Developers, which is the registrant for Unison.
>
> Status in Unison: the file synchronization tool: Confirmed
> Status in “unison” package in Ubuntu: Confirmed
>
> Bug description:
> Binary package hint: unison
>
> When a directory contains files whose name bare both capitalized and not capitalized letters (though not the same names, even ignoring case), the Unison archive is created in a way that switching on or off the "ignorecase" flag makes it crash.
>
> Expected:
>
> Unison re-sorts the archive to overcome the new user setting.
>
> It should just proceed comparison normally
> (unless "ignorecase" was set to "false" before and now with "ignorecase=true" it happens that two files have the same name, e.g., "AaAaa" and "aaaAA")
>
> Reproducing this bug:
>
> $ mkdir tmp
> $ cd tmp
> $ mkdir a ; mkdir b
> $ ls > a/Aa
> $ ls > a/Ee
> $ ls > b/a
> $ ls > b/e
> $ unison a b -ignorecase=false -fastcheck=false
> Warning: No archive files were found for these roots, whose canonical names are:
> ...
> This can happen either
> because this is the first time you have synchronized these roots,
> or because you have upgraded Unison to a new version with a different
> archive format.
>
> Update detection may take a while on this run if the replicas are
> large.
>
> Unison will assume that the 'last synchronized state' of both replicas
> was completely empty. This means that any files that are different
> will be reported as conflicts, and any files that exist only on one
> replica will be judged as new and propagated to the other replica.
> If the two replicas are identical, then no changes will be reported.
>
> If you see this message repeatedly, it may be because one of your machines
> is getting its address from DHCP, which is causing its host name to change
> between synchronizations. See the documentation for the UNISONLOCALHOSTNAME
> environment variable for advice on how to correct this.
>
> Donations to the Unison project are gratefully accepted:
> http://www.cis.upenn.edu/~bcpierce/unison
>
> Press return to continue.[<spc>]
> a b
> file ----> Aa
> file ----> Ee
> <---- file a
> <---- file e
>
> Proceed with propagating updates? [] g[BGN] Copying Aa...
> [END] Copying Aa
> ...
> [END] Copying e
> Synchronization complete (4 items transferred, 0 skipped, 0 failures)
> $ unison a b -ignorecase=false -fastcheck=false
> $ unison a b -ignorecase=true -fastcheck=false
> Fatal error: Corrupted archive: the files are not correctely ordered in directory
> $ unison -version
> unison version 2.27.57
> $
>
> ProblemType: Bug
> Architecture: i386
> Date: Tue Mar 9 18:51:30 2010
> DistroRelease: Ubuntu 9.10
> InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release i386 (20091028.5)
> Package: unison 2.27.57-2ubuntu1...

Read more...

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.