memory error -- IEG files
Added by Birgit Mannig almost 10 years ago
Hello,
I run CDO version 1.6.2 on a Ubuntu 14.04 (64-bit).
For CDO operations on IEG files I get a memory error ("Speicherzugriffsfehler (Speicherabzug geschrieben)"). The problem seems to be with the library libcdi (see below). I tried the same files with the same CDO and Ubuntu version (but 32-bit), on a different machine, without any errors.
To exclude mistakes, I also tried with a public example file from https://www.unidata.ucar.edu/software/netcdf/examples/files.html (see attached), same problem occurs, I am not able to convert the file to IEG.
Does anybody know a way to fix this?
Running CDO with valgrind delivers:
valgrind cdo -info myfile.ieg ==3849== Invalid read of size 8 ==3849== at 0x4EB5230: iegInqContents (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x4ECDFAF: ??? (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x4ED09D6: streamOpen (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x4ED0A51: streamOpenRead (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x5010F4: ??? (in /usr/bin/cdo) ==3849== by 0x44C67C: ??? (in /usr/bin/cdo) ==3849== by 0x40BEAF: ??? (in /usr/bin/cdo) ==3849== by 0x607EEC4: (below main) (libc-start.c:287) ==3849== Address 0x5878 is not stack'd, malloc'd or (recently) free'd ==3849== ==3849== ==3849== Process terminating with default action of signal 11 (SIGSEGV) ==3849== Access not within mapped region at address 0x5878 ==3849== at 0x4EB5230: iegInqContents (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x4ECDFAF: ??? (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x4ED09D6: streamOpen (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x4ED0A51: streamOpenRead (in /usr/lib/x86_64-linux-gnu/libcdi.so.0.0.0) ==3849== by 0x5010F4: ??? (in /usr/bin/cdo) ==3849== by 0x44C67C: ??? (in /usr/bin/cdo) ==3849== by 0x40BEAF: ??? (in /usr/bin/cdo) ==3849== by 0x607EEC4: (below main) (libc-start.c:287) ==3849== If you believe this happened as a result of a stack ==3849== overflow in your program's main thread (unlikely but ==3849== possible), you can try to increase the size of the ==3849== main thread stack using the --main-stacksize= flag. ==3849== The main thread stack size used in this run was 67108864. ==3849== ==3849== HEAP SUMMARY: ==3849== in use at exit: 217,828 bytes in 20 blocks ==3849== total heap usage: 26 allocs, 6 frees, 297,767 bytes allocated ==3849== ==3849== LEAK SUMMARY: ==3849== definitely lost: 0 bytes in 0 blocks ==3849== indirectly lost: 0 bytes in 0 blocks ==3849== possibly lost: 0 bytes in 0 blocks ==3849== still reachable: 217,828 bytes in 20 blocks ==3849== suppressed: 0 bytes in 0 blocks ==3849== Rerun with --leak-check=full to see details of leaked memory ==3849==
Replies (2)
RE: memory error -- IEG files - Added by Ralf Mueller almost 10 years ago
with 1.7.1 I get
ram@luthien:~/Downloads cdo infov sresa1b_ncar_ccsm3-example.nc
Warning (cdfScanVarAttributes) : NetCDF: Variable not found - height
-1 : Date Time Level Gridsize Miss : Minimum Mean Maximum : Parameter name
1 : 2000-05-16 12:00:00 0 32768 0 : 4.7346e+08 1.5561e+10 2.4346e+10 : area
2 : 2000-05-16 12:00:00 0 32768 0 : 0.0000 0.00061035 1.0000 : msk_rgn
3 : 2000-05-16 12:00:00 0 32768 0 : 2.4460e-26 2.7258e-05 0.00030686 : pr
4 : 2000-05-16 12:00:00 0 32768 0 : 205.24 278.64 309.10 : tas
5 : 2000-05-16 12:00:00 100000 32768 20132 : -14.621 -1.2652 12.228 : ua
6 : 2000-05-16 12:00:00 92500 32768 5340 : -17.808 1.4447 19.665 : ua
7 : 2000-05-16 12:00:00 85000 32768 3381 : -18.704 2.3264 20.983 : ua
8 : 2000-05-16 12:00:00 70000 32768 1769 : -16.946 4.3663 24.866 : ua
9 : 2000-05-16 12:00:00 60000 32768 259 : -13.667 5.8819 27.928 : ua
10 : 2000-05-16 12:00:00 50000 32768 0 : -11.098 7.7648 31.205 : ua
11 : 2000-05-16 12:00:00 40000 32768 0 : -9.0083 10.428 35.412 : ua
12 : 2000-05-16 12:00:00 30000 32768 0 : -9.9183 13.887 39.998 : ua
13 : 2000-05-16 12:00:00 25000 32768 0 : -11.765 15.763 44.598 : ua
14 : 2000-05-16 12:00:00 20000 32768 0 : -12.916 17.281 49.843 : ua
15 : 2000-05-16 12:00:00 15000 32768 0 : -16.155 17.237 49.299 : ua
16 : 2000-05-16 12:00:00 10000 32768 0 : -24.160 13.707 38.365 : ua
17 : 2000-05-16 12:00:00 7000 32768 0 : -19.685 9.2464 39.309 : ua
18 : 2000-05-16 12:00:00 5000 32768 0 : -16.001 6.5147 43.567 : ua
19 : 2000-05-16 12:00:00 3000 32768 0 : -13.673 5.3174 50.794 : ua
20 : 2000-05-16 12:00:00 2000 32768 0 : -13.934 6.0367 56.021 : ua
21 : 2000-05-16 12:00:00 1000 32768 0 : -12.700 9.1144 63.261 : ua
cdo infon: Processed 688128 values from 5 variables over 1 timestep ( 0.00s )
Could you update? Conda might be an option Anaconda
RE: memory error -- IEG files - Added by Birgit Mannig almost 10 years ago
that was easy, with the update it works. Thank you!
(I still do not understand why the older version works on the 32-bit system but not on the 64-bit, but whatever...)