You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Mark Raymond <ma...@raymonds.org.uk> on 2012/11/01 22:21:21 UTC
svnserve crash
Background:
A week or so ago, I tried to set up svnserve with sasl authentication
(DIGEST-MD5 & sasldb), which I tried using various binaries of subversion (I
tried TortoiseSVN, CollabNet and Wandisco), to no avail (if you want more
details, see my email on 20/10/2012; basically authentication kept failing
despite credentials being correct). As I had to create the sasldb on Linux
due to a lack of Windows binaries of saslpasswd2, I thought that might be
the problem, so I set about compiling everything from source, which I have
now done. My binaries appear to work, generally; in particular, svnserve
works fine when using inbuilt authentication without sasl.
Problem:
I have svnserve running, using sasl, sasl being set up to use DIGEST-MD5 and
sasldb. When I try to check out the repository, svnserve crashes, producing
the attached log and dump files. The configuration files are good (they work
on Xubuntu, using a sasldb created on Xubuntu with the same parameters I
used on Windows)
Does anyone know what could be the problem causing the crash?
Thanks!
Re: svnserve crash
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
Shot in the dark, but: does the crash reproduce in non-threaded modes?
(such as -X/--foreground, or alternatively -i if you have netcat or
inetd to test it with)
Mark Raymond wrote on Thu, Nov 01, 2012 at 21:21:21 -0000:
> Background:
>
> A week or so ago, I tried to set up svnserve with sasl authentication
> (DIGEST-MD5 & sasldb), which I tried using various binaries of subversion (I
> tried TortoiseSVN, CollabNet and Wandisco), to no avail (if you want more
> details, see my email on 20/10/2012; basically authentication kept failing
> despite credentials being correct). As I had to create the sasldb on Linux
> due to a lack of Windows binaries of saslpasswd2, I thought that might be
> the problem, so I set about compiling everything from source, which I have
> now done. My binaries appear to work, generally; in particular, svnserve
> works fine when using inbuilt authentication without sasl.
>
> Problem:
>
> I have svnserve running, using sasl, sasl being set up to use DIGEST-MD5 and
> sasldb. When I try to check out the repository, svnserve crashes, producing
> the attached log and dump files. The configuration files are good (they work
> on Xubuntu, using a sasldb created on Xubuntu with the same parameters I
> used on Windows)
>
> Does anyone know what could be the problem causing the crash?
>
> Thanks!
RE: svnserve crash
Posted by Mark Raymond <ma...@raymonds.org.uk>.
> Now, the first thing that jumps out is that some of the actual parameters
are 0x00000000 or 0x00001000; for example:
> #14 0x13f639fd8 in serve(conn=(svn_ra_svn_conn_st *) 0x00000000,
params=(serve_params_t *) 0x00000000, pool=(apr_pool_t *) 0x00000000) at
> which might suggest a stack smash, or just that this is how windows stack
traces normally work and I'm not aware of that convention.
I think the hex values here may be truncated; this is a 64-bit compile, and
those are 32 bits long.
I've now compiled a debug version and I attached Visual Studio to svnserve
to see what happens. The stack trace looked similar, except there's an extra
8 digits after each hex value which has non-zero numbers.
In debug mode, I get an assertion fail for _CrtIsValidHeapPointer, which
occurs due to this attempt to free memory:
utils->free(data.data);
on line 256 of plugins\db_berkeley.c in Cyrus SASL code. I've now found that
if I remove this line, then the problem disappears, and svnserve works fine
- though obviously this probably results in a memory leak!
I'm considering this solved for me now. I've tried to measure the memory
leak, and it seems each check out / commit leaks ~8KB, which is small enough
to not worry me, especially as I'll be rebooting the computer svnserve is on
regularly.
> Are you using 1.7.7?
Yes
Re: svnserve crash
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
Andreas Mohr wrote on Fri, Nov 02, 2012 at 19:44:24 +0100:
> Hi,
>
> On Fri, Nov 02, 2012 at 08:35:11PM +0200, Daniel Shahaf wrote:
> > Please attach log files as text/* MIME type (maybe by renaming them to
> > *.txt) so it's easier to read/reply to them.
> >
> > Now, the first thing that jumps out is that some of the actual
> > parameters are 0x00000000 or 0x00001000; for example:
> >
> > #14 0x13f639fd8 in serve(conn=(svn_ra_svn_conn_st *) 0x00000000, params=(serve_params_t *) 0x00000000, pool=(apr_pool_t *) 0x00000000) at
> >
> > which might suggest a stack smash, or just that this is how windows
> > stack traces normally work and I'm not aware of that convention.
>
> Input parameter values as shown by the backtrace
> deviating from their original caller values
> may also have been caused by these input variables getting modified
> *within* the function (some people in some cases tend to prefer
> creating local variable copies to actively work on, for this reason).
>
Yes, C permits that, but it won't be the case here since we never set
'pool' variables to NULL (except when a variable declaration does that
implicitly) and never pass NULL as the actual value for an 'apr_pool_t *'
parameter.
> However, three parameters in a row being NULL
> might obviously point to a more systematic mem erase.
>
> Andreas Mohr
Re: svnserve crash
Posted by Andreas Mohr <an...@lisas.de>.
Hi,
On Fri, Nov 02, 2012 at 08:35:11PM +0200, Daniel Shahaf wrote:
> Please attach log files as text/* MIME type (maybe by renaming them to
> *.txt) so it's easier to read/reply to them.
>
> Now, the first thing that jumps out is that some of the actual
> parameters are 0x00000000 or 0x00001000; for example:
>
> #14 0x13f639fd8 in serve(conn=(svn_ra_svn_conn_st *) 0x00000000, params=(serve_params_t *) 0x00000000, pool=(apr_pool_t *) 0x00000000) at
>
> which might suggest a stack smash, or just that this is how windows
> stack traces normally work and I'm not aware of that convention.
Input parameter values as shown by the backtrace
deviating from their original caller values
may also have been caused by these input variables getting modified
*within* the function (some people in some cases tend to prefer
creating local variable copies to actively work on, for this reason).
However, three parameters in a row being NULL
might obviously point to a more systematic mem erase.
Andreas Mohr
Re: svnserve crash
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
Please attach log files as text/* MIME type (maybe by renaming them to
*.txt) so it's easier to read/reply to them.
Now, the first thing that jumps out is that some of the actual
parameters are 0x00000000 or 0x00001000; for example:
#14 0x13f639fd8 in serve(conn=(svn_ra_svn_conn_st *) 0x00000000, params=(serve_params_t *) 0x00000000, pool=(apr_pool_t *) 0x00000000) at
which might suggest a stack smash, or just that this is how windows
stack traces normally work and I'm not aware of that convention.
Are you using 1.7.7?
Mark Raymond wrote on Thu, Nov 01, 2012 at 21:21:21 -0000:
> Background:
>
> A week or so ago, I tried to set up svnserve with sasl authentication
> (DIGEST-MD5 & sasldb), which I tried using various binaries of subversion (I
> tried TortoiseSVN, CollabNet and Wandisco), to no avail (if you want more
> details, see my email on 20/10/2012; basically authentication kept failing
> despite credentials being correct). As I had to create the sasldb on Linux
> due to a lack of Windows binaries of saslpasswd2, I thought that might be
> the problem, so I set about compiling everything from source, which I have
> now done. My binaries appear to work, generally; in particular, svnserve
> works fine when using inbuilt authentication without sasl.
>
> Problem:
>
> I have svnserve running, using sasl, sasl being set up to use DIGEST-MD5 and
> sasldb. When I try to check out the repository, svnserve crashes, producing
> the attached log and dump files. The configuration files are good (they work
> on Xubuntu, using a sasldb created on Xubuntu with the same parameters I
> used on Windows)
>
> Does anyone know what could be the problem causing the crash?
>
> Thanks!