Dear Enrico, I am not trying to debug any particular part of ooRexx, everything runs just fine, all tests (including those I have written) pass without errors. What I am going after is a spurious problem:
REXX-ooRexx_5.0.0(MT)_64-bit 6.05 13 Feb 2019 r11755 Searching for test containers./Users/po/workspace/testooRexx.sh: line 37: 4122 Segmentation fault: 11 rexx testOORexx.rex -s -X native_API I have seen it happening on macOS and on Ubuntu, the segmentation fault just when rexx is starting. Running it again it runs just fine. It happens in average every 25-30 times I run the build&test (on Mac but also on Ubuntu) Since I am not familiar with the debugger on Linux this was an excellent opportunity for me to learn about it. Hälsningar/Regards/Grüsse, P.O. Jonsson oor...@jonases.se > Am 27.02.2019 um 13:06 schrieb Enrico Sorichetti via Oorexx-devel > <oorexx-devel@lists.sourceforge.net>: > > Dear P.O. > > Running the test suite is not the best the way - IMO - to debug rexx > The testSuite is sensitive to what is written to stdout and stderr > And it will usually report testSuite related non existent errors , > broken pipe, output mismatches, the most recurring ones > And because of that it will nor run many sections of the test > > Just isolate the section of the script being investigated > And run it outside of the test suite > > Cheers > E > > BTDTGTTS - been there done that got the tee shirt > > >> On 27 Feb 2019, at 12:40, P.O. Jonsson <oor...@jonases.se >> <mailto:oor...@jonases.se>> wrote: >> >> Dear Moritz, >> >> Sorry about the delay but I had pressing task and no time for ooRexx. Now I >> have tried to run the debugger (first-time-noob) but I do not understand the >> rexx core“ business, can you elaborate? >> >> osboxes@osboxes:~/workspace/ooRexx-mint19-test$ ulimit -c 1000000 >> >> osboxes@osboxes:~/workspace/ooRexx-mint19-test$ gdb -silent rexx core >> Reading symbols from rexx...done. >> /home/osboxes/workspace/ooRexx-mint19-test/core: No such file or directory. >> (gdb) >> >> This works, at least to some extent >> >> osboxes@osboxes:~/workspace/ooRexx-mint19-test$ gdb -silent -ex=r --args >> rexx testOORexx.rex -s -R ooRexx/samples >> Reading symbols from rexx...done. >> Starting program: /usr/bin/rexx testOORexx.rex -s -R ooRexx/samples >> [Thread debugging using libthread_db enabled] >> Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". >> Searching for test containers[New Thread 0x7ffff7f56700 (LWP 7612)] >> .. >> Executing automated test suite >> Executing .../ooRexx/samples/arithmeticEvaluation.testGroup >> Executing .../ooRexx/samples/month.testGroup >> >> ooTest Framework - Automated Test of the ooRexx Interpreter >> >> Interpreter: REXX-ooRexx_5.0.0(MT)_64-bit 6.05 27 Feb 2019 >> OS Name: LINUX >> SysVersion: Linux 4.15.0-45-generic >> >> Tests ran: 11 >> Assertions: 90 >> Failures: 0 >> Errors: 0 >> >> File search: 00:00:00.120060 >> Suite construction: 00:00:00.000917 >> Test execution: 00:00:00.256227 >> Total time: 00:00:00.760014 >> >> [Thread 0x7ffff7f56700 (LWP 7612) exited] >> [Inferior 1 (process 7605) exited normally] >> (gdb) >> >> And in a real run (a shell script executing the test suite) I got some >> errors (that are not there when I run the suite outside the debugger) >> >> osboxes@osboxes:~/workspace$ bash testooRexx.sh >> + cd /home/osboxes/workspace/ooRexx-mint19-test >> + svn update >> Updating '.': >> At revision 11810. >> + . ./setTestEnv.sh >> ++ UNAME_SYSTEM=Linux >> ++ case "${UNAME_SYSTEM}" in >> ++ echo 'Setting env for Linux' >> Setting env for Linux >> +++ pwd >> +++ pwd >> ++ >> frameworkPath=/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework: >> ++ export >> PATH=/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games >> ++ >> PATH=/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games >> +++ pwd >> ++ export >> LD_LIBRARY_PATH=/home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX:/home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX: >> ++ >> LD_LIBRARY_PATH=/home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX:/home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX: >> + echo >> >> + echo >> /home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games >> /home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/home/osboxes/workspace/ooRexx-mint19-test:/home/osboxes/workspace/ooRexx-mint19-test/framework:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games >> + echo >> >> + echo >> /home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX:/home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX: >> /home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX:/home/osboxes/workspace/ooRexx-mint19-test/bin/LINUX: >> + echo >> >> + rexx -e 'parse version v; say v '\''r'\'' || .RexxInfo~revision' >> REXX-ooRexx_5.0.0(MT)_64-bit 6.05 27 Feb 2019 r11810 >> + sleep 1 >> + ulimit -c 1000000 >> + gdb -silent -ex=r --args rexx testOORexx.rex -s -X native_API >> Reading symbols from rexx...done. >> Starting program: /usr/bin/rexx testOORexx.rex -s -X native_API >> [Thread debugging using libthread_db enabled] >> Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". >> Searching for test containers[New Thread 0x7ffff7f56700 (LWP 8018)] >> [New Thread 0x7ffff7ed5700 (LWP 8019)] >> ... >> Executing automated test suite >> Executing .../ooRexx/SimpleTests.testGroup >> Executing .../ooRexx/base/bif/ABBREV.testGroup >> Executing .../ooRexx/base/bif/ABS.testGroup >> Executing .../ooRexx/base/bif/ADDRESS.testGroup >> Executing .../ooRexx/base/bif/ARG.testGroup >> Executing .../ooRexx/base/bif/B2X.testGroup >> Executing .../ooRexx/base/bif/BEEP.testGroup >> Executing .../ooRexx/base/bif/BITAND.testGroup >> Executing .../ooRexx/base/bif/BITOR.testGroup >> Executing .../ooRexx/base/bif/BITXOR.testGroup >> Executing .../ooRexx/base/bif/C2D.testGroup >> Executing .../ooRexx/base/bif/C2X.testGroup >> Executing .../ooRexx/base/bif/CENTER.testGroup >> Executing .../ooRexx/base/bif/CENTRE.testGroup >> Executing .../ooRexx/base/bif/CHANGESTR.testGroup >> Executing .../ooRexx/base/bif/CHARIN.testGroup >> Executing .../ooRexx/base/bif/CHAROUT.testGroup >> Executing .../ooRexx/base/bif/CHARS.testGroup >> Executing .../ooRexx/base/bif/COMPARE.testGroup >> Executing .../ooRexx/base/bif/CONDITION.testGroup >> Executing .../ooRexx/base/bif/COPIES.testGroup >> Executing .../ooRexx/base/bif/COUNTSTR.testGroup >> Executing .../ooRexx/base/bif/D2C.testGroup >> Executing .../ooRexx/base/bif/D2X.testGroup >> Executing .../ooRexx/base/bif/DATATYPE.testGroup >> Executing .../ooRexx/base/bif/DATE.testGroup >> Executing .../ooRexx/base/bif/DELSTR.testGroup >> Executing .../ooRexx/base/bif/DELWORD.testGroup >> Executing .../ooRexx/base/bif/DIGITS.testGroup >> Executing .../ooRexx/base/bif/ERRORTEXT.testGroup >> Executing .../ooRexx/base/bif/FILESPEC.testGroup >> Executing .../ooRexx/base/bif/FORM.testGroup >> Executing .../ooRexx/base/bif/FORMAT.testGroup >> Executing .../ooRexx/base/bif/FUZZ.testGroup >> Executing .../ooRexx/base/bif/INSERT.testGroup >> Executing .../ooRexx/base/bif/LASTPOS.testGroup >> Executing .../ooRexx/base/bif/LEFT.testGroup >> Executing .../ooRexx/base/bif/LENGTH.testGroup >> Executing .../ooRexx/base/bif/LINEIN.testGroup >> Executing .../ooRexx/base/bif/LINEOUT.testGroup >> Executing .../ooRexx/base/bif/LINES.testGroup >> Executing .../ooRexx/base/bif/LOWER.testGroup >> Executing .../ooRexx/base/bif/MAX.testGroup >> Executing .../ooRexx/base/bif/MIN.testGroup >> Executing .../ooRexx/base/bif/OVERLAY.testGroup >> Executing .../ooRexx/base/bif/POS.testGroup >> Executing .../ooRexx/base/bif/QUALIFY.testGroup >> Executing .../ooRexx/base/bif/QUEUED.testGroup >> Executing .../ooRexx/base/bif/RANDOM.testGroup >> Executing .../ooRexx/base/bif/REVERSE.testGroup >> Executing .../ooRexx/base/bif/RIGHT.testGroup >> Executing .../ooRexx/base/bif/RXQUEUE.testGroup >> Executing .../ooRexx/base/bif/SIGN.testGroup >> Executing .../ooRexx/base/bif/SOURCELINE.testGroup >> Executing .../ooRexx/base/bif/SPACE.testGroup >> Executing .../ooRexx/base/bif/STREAM.testGroup >> Executing .../ooRexx/base/bif/STREAM.testGroup >> Executing .../ooRexx/base/bif/STRIP.testGroup >> Executing .../ooRexx/base/bif/SUBSTR.testGroup >> Executing .../ooRexx/base/bif/SUBWORD.testGroup >> Executing .../ooRexx/base/bif/SYMBOL.testGroup >> Executing .../ooRexx/base/bif/TIME.testGroup >> Executing .../ooRexx/base/bif/TIME.testGroup >> ^[Executing .../ooRexx/base/bif/TRANSLATE.testGroup >> Executing .../ooRexx/base/bif/TRUNC.testGroup >> Executing .../ooRexx/base/bif/UPPER.testGroup >> Executing .../ooRexx/base/bif/VALUE.testGroup >> Executing .../ooRexx/base/bif/VAR.testGroup >> Executing .../ooRexx/base/bif/VERIFY.testGroup >> Executing .../ooRexx/base/bif/WORD.testGroup >> Executing .../ooRexx/base/bif/WORDINDEX.testGroup >> Executing .../ooRexx/base/bif/WORDLENGTH.testGroup >> Executing .../ooRexx/base/bif/WORDPOS.testGroup >> Executing .../ooRexx/base/bif/WORDS.testGroup >> Executing .../ooRexx/base/bif/X2B.testGroup >> Executing .../ooRexx/base/bif/X2C.testGroup >> Executing .../ooRexx/base/bif/X2D.testGroup >> Executing .../ooRexx/base/bif/XRANGE.testGroup >> Executing .../ooRexx/base/class/Alarm.testGroup >> [New Thread 0x7ffff4115700 (LWP 8274)] >> [New Thread 0x7ffff4094700 (LWP 8275)] >> Executing .../ooRexx/base/class/Array.testGroup >> [New Thread 0x7fffdc676700 (LWP 8277)] >> >> Thread 6 "rexx" received signal SIGPIPE, Broken pipe. >> [Switching to Thread 0x7fffdc676700 (LWP 8277)] >> 0x00007ffff74b0187 in __GI___libc_write (fd=9, buf=0x7fffdc6a77b0, nbytes=6) >> at ../sysdeps/unix/sysv/linux/write.c:27 >> 27 ../sysdeps/unix/sysv/linux/write.c: No such file or directory. >> (gdb) >> >> What more can I do to improve the testing? The broken pipe message does not >> occur outside of the debugger. >> >> Hälsningar/Regards/Grüsse, >> P.O. Jonsson >> oor...@jonases.se <mailto:oor...@jonases.se> >> >> >> >> >>> Am 20.02.2019 um 15:52 schrieb Moritz Hoffmann <antig...@gmail.com >>> <mailto:antig...@gmail.com>>: >>> >>> It can help to enable core dumps, which can be used to debug after the >>> program faulted. On Linux, use the following command to enable them >>> for the current shell: >>> >>> ulimit -c 1000000 >>> >>> Later use gdb to read them: >>> >>> gdb rexx core >>> >>> Moritz >>> >>> On Wed, Feb 20, 2019 at 3:30 PM P.O. Jonsson <oor...@jonases.se >>> <mailto:oor...@jonases.se>> wrote: >>>> >>>> Thanks for the info, will build with debug and try to install the debugger >>>> then. Hopefully next time I have more info. >>>> >>>> For what it is worth here the last lines in /var/log/kern.log (seems to >>>> point to librexx.so): >>>> >>>> Feb 19 19:58:35 ubuntu18-04 kernel: [ 5.735603] audit: type=1400 >>>> audit(1550602715.004:11): apparmor="STATUS" operation="profile_load" >>>> profile="unconfined" name="/usr/lib/connman/scripts/dhclient-script" >>>> pid=587 comm="apparmor_parser" >>>> Feb 19 19:58:36 ubuntu18-04 kernel: [ 6.932503] IPv6: >>>> ADDRCONF(NETDEV_UP): enp0s3: link is not ready >>>> Feb 19 19:58:36 ubuntu18-04 kernel: [ 6.936425] IPv6: >>>> ADDRCONF(NETDEV_UP): enp0s3: link is not ready >>>> Feb 19 19:58:36 ubuntu18-04 kernel: [ 6.944100] e1000: enp0s3 NIC Link >>>> is Up 1000 Mbps Full Duplex, Flow Control: RX >>>> Feb 19 19:58:36 ubuntu18-04 kernel: [ 6.944427] IPv6: >>>> ADDRCONF(NETDEV_CHANGE): enp0s3: link becomes ready >>>> Feb 19 19:59:00 ubuntu18-04 kernel: [ 31.532494] rfkill: input handler >>>> disabled >>>> Feb 20 11:11:36 ubuntu18-04 kernel: [54782.226713] show_signal_msg: 28 >>>> callbacks suppressed >>>> Feb 20 11:11:36 ubuntu18-04 kernel: [54782.226717] rexx[10888]: segfault >>>> at 18 ip 00007ffa4466fff1 sp 00007ffdf0fb72f0 error 4 in >>>> librexx.so.5.0.0[7ffa44502000+219000] >>>> >>>> Hälsningar/Regards/Grüsse, >>>> P.O. Jonsson >>>> oor...@jonases.se <mailto:oor...@jonases.se> >>>> >>>> >>>> >>>> >>>> Am 20.02.2019 um 15:08 schrieb Moritz Hoffmann <antig...@gmail.com >>>> <mailto:antig...@gmail.com>>: >>>> >>>> This is good to know but unfortunately not helpful. See >>>> https://sourceforge.net/p/oorexx/wiki/how-to-debug-oorexx/ >>>> <https://sourceforge.net/p/oorexx/wiki/how-to-debug-oorexx/> on how to >>>> get more useful information. >>>> >>>> Cheers, >>>> Moritz >>>> >>>> On Wed, Feb 20, 2019 at 2:59 PM P.O. Jonsson <oor...@jonases.se >>>> <mailto:oor...@jonases.se>> wrote: >>>> >>>> >>>> Dear developers, >>>> >>>> I am building & testing on a number of different platforms and sometimes >>>> on macOS/Darwin I get this when I come to the test (it all runs from a >>>> shell script): >>>> >>>> REXX-ooRexx_5.0.0(MT)_64-bit 6.05 13 Feb 2019 r11755 >>>> Searching for test containers./Users/po/workspace/testooRexx.sh: line 37: >>>> 4122 Segmentation fault: 11 rexx testOORexx.rex -s -X native_API >>>> >>>> Today I had the same on Ubuntu for the first time: >>>> >>>> Searching for test containers... >>>> /home/osboxes/workspace/testooRexx.sh: line 33: 10888 Segmentation fault >>>> (core dumped) rexx testOORexx.rex -s -X native_API >>>> osboxes@ubuntu18-04:~/workspace$ ^C >>>> osboxes@ubuntu18-04:~/workspace$ >>>> >>>> There was a crash report on the Ubuntu desktop indicating usr/bin/rexx to >>>> be the culprit but apart from that I could get no further information out. >>>> Trying again a 2nd time it always work. >>>> >>>> Is there a way (on macOS or Ubuntu or any other system) to find out more >>>> about this? I build „release“ version on all systems. Is such information >>>> at all useful for U? >>>> >>>> Hälsningar/Regards/Grüsse, >>>> P.O. Jonsson >>>> oor...@jonases.se <mailto:oor...@jonases.se> >>>> >>>> >>>> >>>> >>>> _______________________________________________ >>>> Oorexx-devel mailing list >>>> Oorexx-devel@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/oorexx-devel >>>> >>>> >>>> >>>> >>>> -- >>>> Moritz Hoffmann; >>>> http://antiguru.de/ >>>> >>>> >>>> _______________________________________________ >>>> Oorexx-devel mailing list >>>> Oorexx-devel@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/oorexx-devel >>>> >>>> >>>> _______________________________________________ >>>> Oorexx-devel mailing list >>>> Oorexx-devel@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/oorexx-devel >>> >>> >>> >>> -- >>> Moritz Hoffmann; >>> http://antiguru.de/ <http://antiguru.de/> >>> >>> >>> _______________________________________________ >>> Oorexx-devel mailing list >>> Oorexx-devel@lists.sourceforge.net >>> <mailto:Oorexx-devel@lists.sourceforge.net> >>> https://lists.sourceforge.net/lists/listinfo/oorexx-devel >> >> _______________________________________________ >> Oorexx-devel mailing list >> Oorexx-devel@lists.sourceforge.net >> <mailto:Oorexx-devel@lists.sourceforge.net> >> https://lists.sourceforge.net/lists/listinfo/oorexx-devel > > _______________________________________________ > Oorexx-devel mailing list > Oorexx-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/oorexx-devel
_______________________________________________ Oorexx-devel mailing list Oorexx-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/oorexx-devel