"Writing R Extensions" says
{quotes}
If you have a crash which gives a core dump you can use something like
gdb /path/to/R/bin/exec/R core.12345
to examine the core dump. If core dumps are disabled...
{unquotes}
sadly it doesn't go on to say how to enable if core dumps are disabled.
I understand that in bash I need to do
$ ulimit -c unlimited
but this doesn't seem to be enough, I still don't find a core file
despite
*** caught segfault ***
address 0x20000028, cause 'memory not mapped'
Possible actions:
1: abort (with core dump)
2: normal R exit
3: exit R without saving workspace
4: exit R saving workspace
Selection: 1
I am running Ubuntu jaunty on a laptop. Any ideas as to what I might need to
configure next?
thanks
David
--
David Pleydell
UMR BGPI
CIRAD
TA A-54/K
Campus International de Baillarguet
34398 MONTPELLIER CEDEX 5
FRANCE
Tel: +33 4 99 62 48 65 - Secr?tariat : +33 4 99 62 48 21
Fax : +33 4 99 62 48 22
http://umr-bgpi.cirad.fr/trombinoscope/pleydell_d.htm
https://sites.google.com/site/drjpleydell/
I forgot to add that I am compiling with R CMD SHLIB buggyCode.c --ggdb thanks David Quoting pleydell at supagro.inra.fr:> "Writing R Extensions" says > > {quotes} > If you have a crash which gives a core dump you can use something like > > gdb /path/to/R/bin/exec/R core.12345 > > to examine the core dump. If core dumps are disabled... > {unquotes} > > sadly it doesn't go on to say how to enable if core dumps are disabled. > > I understand that in bash I need to do > > $ ulimit -c unlimited > > but this doesn't seem to be enough, I still don't find a core file despite > > *** caught segfault *** > address 0x20000028, cause 'memory not mapped' > > Possible actions: > 1: abort (with core dump) > 2: normal R exit > 3: exit R without saving workspace > 4: exit R saving workspace > Selection: 1 > > > I am running Ubuntu jaunty on a laptop. Any ideas as to what I might need to > configure next? > > thanks > David > > > > > > > -- > David Pleydell > UMR BGPI > CIRAD > TA A-54/K > Campus International de Baillarguet > 34398 MONTPELLIER CEDEX 5 > FRANCE > Tel: +33 4 99 62 48 65 - Secr?tariat : +33 4 99 62 48 21 > Fax : +33 4 99 62 48 22 > http://umr-bgpi.cirad.fr/trombinoscope/pleydell_d.htm > https://sites.google.com/site/drjpleydell/ >-- David Pleydell UMR BGPI CIRAD TA A-54/K Campus International de Baillarguet 34398 MONTPELLIER CEDEX 5 FRANCE Tel: +33 4 99 62 48 65 - Secr?tariat : +33 4 99 62 48 21 Fax : +33 4 99 62 48 22 http://umr-bgpi.cirad.fr/trombinoscope/pleydell_d.htm https://sites.google.com/site/drjpleydell/
pleydell at supagro.inra.fr wrote:> "Writing R Extensions" says > > {quotes} > If you have a crash which gives a core dump you can use something like > > gdb /path/to/R/bin/exec/R core.12345 > > to examine the core dump. If core dumps are disabled... > {unquotes} > > sadly it doesn't go on to say how to enable if core dumps are disabled. > > I understand that in bash I need to do > > $ ulimit -c unlimited > > but this doesn't seem to be enough, I still don't find a core file despite > > *** caught segfault *** > address 0x20000028, cause 'memory not mapped' > > Possible actions: > 1: abort (with core dump) > 2: normal R exit > 3: exit R without saving workspace > 4: exit R saving workspace > Selection: 1 > > > I am running Ubuntu jaunty on a laptop. Any ideas as to what I might need to > configure next?not really answering your question, but I find it more useful to R -d gdb or R -d gdb -f test.R where test.R reproduces the bug in some minimal code. A variant is R -d valgrind -f test.R if the memory problem is not easy to spot. Martin> > thanks > David > > > > > >