# git-svn checksum mismatch importing large file

5 messages from 2008-09-17 to 2008-09-17. Participants: Pascal Obry, Björn Steinbrink, Avery Pennarun.
Thread: https://gitlist.dev/t/15563

## Pascal Obry, 2008-09-17 07:53

Subject: git-svn checksum mismatch importing large file
Message-ID: <48D0B77E.7010308@obry.net>
URL: https://gitlist.dev/e/48D0B77E.7010308%40obry.net

```
I get this error:

Checksum mismatch: trunk/data
expected: 7c59e4dd67b5a9fde6c61cada070537b
    got: 3fcd9d077a5aa51a784a452c9d78d6e0

To reproduce launch run.sh in attached archive.

I have had this problem since some time now and I finally got some time
to create a reproducer. I have reproduced this problem with yesterday
master Git version.

-- 

--|------------------------------------------------------
--| Pascal Obry                           Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--|              http://www.obry.net
--| "The best way to travel is by means of imagination"
--|
--| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595

```

## Björn Steinbrink, 2008-09-17 08:25

Subject: Re: git-svn checksum mismatch importing large file
Message-ID: <20080917082506.GA8849@atjola.homenet>
URL: https://gitlist.dev/e/20080917082506.GA8849%40atjola.homenet
In-Reply-To: <48D0B77E.7010308@obry.net>

```
On 2008.09.17 09:53:34 +0200, Pascal Obry wrote:
> I get this error:
> 
> Checksum mismatch: trunk/data
> expected: 7c59e4dd67b5a9fde6c61cada070537b
>     got: 3fcd9d077a5aa51a784a452c9d78d6e0
> 
> To reproduce launch run.sh in attached archive.
> 
> I have had this problem since some time now and I finally got some time
> to create a reproducer. I have reproduced this problem with yesterday
> master Git version.

Your /tmp is probably to small to hold the temporary file that git-svn
creates. At least it doesn't fail for me unless I fill my /tmp first.

This should be fixed since 29c70e0b3e3183f86f93500882177d0c74069988, at
least it got me a useful error message when I tested it back then.
Avery, any ideas?

Björn

```

## Pascal Obry, 2008-09-17 09:39

Subject: Re: git-svn checksum mismatch importing large file
Message-ID: <48D0D03B.4040108@obry.net>
URL: https://gitlist.dev/e/48D0D03B.4040108%40obry.net
In-Reply-To: <20080917082506.GA8849@atjola.homenet>

```

Björn,

> Your /tmp is probably to small to hold the temporary file that git-svn
> creates. At least it doesn't fail for me unless I fill my /tmp first.

Hum probably, I did not thought about this given the error message!

> This should be fixed since 29c70e0b3e3183f86f93500882177d0c74069988, at
> least it got me a useful error message when I tested it back then.
> Avery, any ideas?

I'm using Git on master. This commit is there, the error message is not
that useful on my side :)

Anyway, what's the best option? Is there a way to specify another tmp
directory to use with git-svn?

-- 

--|------------------------------------------------------
--| Pascal Obry                           Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--|              http://www.obry.net
--| "The best way to travel is by means of imagination"
--|
--| gpg --keyserver wwwkeys.pgp.net --recv-key C1082595

```

## Björn Steinbrink, 2008-09-17 10:07

Subject: Re: git-svn checksum mismatch importing large file
Message-ID: <20080917100759.GA11718@atjola.homenet>
URL: https://gitlist.dev/e/20080917100759.GA11718%40atjola.homenet
In-Reply-To: <48D0D03B.4040108@obry.net>

```
On 2008.09.17 11:39:07 +0200, Pascal Obry wrote:
> > Your /tmp is probably to small to hold the temporary file that git-svn
> > creates. At least it doesn't fail for me unless I fill my /tmp first.
> 
> Hum probably, I did not thought about this given the error message!

Yeah, I only came up with the idea because of the previous breakage,
otherwise I'd not have guessed that either :-)

> > This should be fixed since 29c70e0b3e3183f86f93500882177d0c74069988, at
> > least it got me a useful error message when I tested it back then.
> > Avery, any ideas?
> 
> I'm using Git on master. This commit is there, the error message is not
> that useful on my side :)

Yeah, I tested with yesterday's master as well, thus I was asking Avery
if he has any clue of what's going on. Should probably have mentioned
that...

> Anyway, what's the best option? Is there a way to specify another tmp
> directory to use with git-svn?

Looks like the code honors the TMPDIR environment variable, but I didn't
actually try that.

Björn

```

## Avery Pennarun, 2008-09-17 17:39

Subject: Re: git-svn checksum mismatch importing large file
Message-ID: <32541b130809171039q22d3776aw45e6ec347c315248@mail.gmail.com>
URL: https://gitlist.dev/e/32541b130809171039q22d3776aw45e6ec347c315248%40mail.gmail.com
In-Reply-To: <20080917082506.GA8849@atjola.homenet>

```
On Wed, Sep 17, 2008 at 4:25 AM, Björn Steinbrink <B.Steinbrink@gmx.de> wrote:
> On 2008.09.17 09:53:34 +0200, Pascal Obry wrote:
>> I get this error:
>>
>> Checksum mismatch: trunk/data
>> expected: 7c59e4dd67b5a9fde6c61cada070537b
>>     got: 3fcd9d077a5aa51a784a452c9d78d6e0
>>
>> To reproduce launch run.sh in attached archive.
>>
>> I have had this problem since some time now and I finally got some time
>> to create a reproducer. I have reproduced this problem with yesterday
>> master Git version.
>
> Your /tmp is probably to small to hold the temporary file that git-svn
> creates. At least it doesn't fail for me unless I fill my /tmp first.
>
> This should be fixed since 29c70e0b3e3183f86f93500882177d0c74069988, at
> least it got me a useful error message when I tested it back then.
> Avery, any ideas?

It is possible that before my patch, you wouldn't have gotten that
error message - instead you would have gotten a corrupt repository,
which might have been caught later with an even more obscure-sounding
error.  It does appear that there's a write() call somewhere in
git-svn that still isn't protected by an "or die", however, because
we're getting an invalid checksum without getting a write error first.

In any case, if the problem is a giant file that won't fit in /tmp,
the best we could do in git-svn is produce a better error message.
/tmp is still the "right" place to put temp files.  I agree with the
suggestion to try pointing the TMPDIR environment variable somewhere
else... or else make your /tmp bigger.

Have fun,

Avery

```
