| | 1 | === Frequently Asked Questions about Help === |
| | 2 | |
| | 3 | ==== I'm having trouble with my configuration ==== |
| | 4 | |
| | 5 | * The IPP program <code>ppConfigDump</code> is useful for seeing your configuration as the code sees it. Run it as you would the binary that's giving you trouble, removing those command-line arguments that are specific to it, but keeping the general arguments: |
| | 6 | * <code>-recipe SOURCE TARGET</code> |
| | 7 | * <code>-D KEY VALUE</code> |
| | 8 | * <code>-Db KEY VALUE</code> |
| | 9 | * <code>-Di KEY VALUE</code> |
| | 10 | * <code>-Df KEY VALUE</code> |
| | 11 | * <code>-ipprc FILE</code> |
| | 12 | * <code>-camera CAMERA</code> |
| | 13 | * <code>-F OLD NEW</code> |
| | 14 | * Also keep a representative input file (from which the camera type and format can be determined by the program; this then triggers the recipe overrides), and feed it to <code>ppConfigDump</code> with the <code>-file</code> flag. |
| | 15 | * If you can't see anything wrong with the configuration, you can dump the user configuration (<code>ppConfigDump -file INPUT.fits -dump-user my_config.mdc</code>) and send it to someone who can run using your configuration by specifying it with the <code>-ipprc his_config.mdc</code> command-line argument to an IPP binary. |
| | 16 | * Dumping the recipe (e.g., <code>ppConfigDump -file INPUT.fits -recipe PPIMAGE PPIMAGE_SOMETHING -dump-recipe PPIMAGE my_ppImage.mdc</code>) can be useful to see why some change isn't being seen by the program. |
| | 17 | <pre> |
| | 18 | Pan-STARRS IPP configuration dumper |
| | 19 | |
| | 20 | Usage: ppConfigDump [-file INPUT.fits] [-dump-site FILE.mdc] |
| | 21 | [-dump-camera FILE.mdc] [-dump-format FILE.mdc] [-dump-recipes FILE.mdc] |
| | 22 | [-dump-recipe RECIPE FILE.mdc] |
| | 23 | |
| | 24 | FILE.mdc may be "-", in which case the file is written to stdout. |
| | 25 | |
| | 26 | Optional arguments, with default values: |
| | 27 | -file () FITS file to use for camera determination |
| | 28 | -dump-user () Filename for user configuration |
| | 29 | -dump-site () Filename for site configuration |
| | 30 | -dump-system () Filename for system configuration |
| | 31 | -dump-camera () Filename for camera configuration |
| | 32 | -dump-format () Filename for camera format |
| | 33 | -dump-recipes () Filename for recipes |
| | 34 | -dump-recipe () Name of recipe |
| | 35 | () Filename |
| | 36 | </pre> |
| | 37 | |
| | 38 | ==== I've got a segmentation violation or bus error ==== |
| | 39 | |
| | 40 | * You should never see these, so this is may be a major programming bug. They are caused by trying to read memory that shouldn't be read (segmentation violations are often caused by "dereferencing a <code>NULL</code> pointer"). |
| | 41 | * These can occur due to problems with dynamically linked libraries, e.g., if something changed in one library that didn't have a corresponding change in a dependent library, Bad Things can happen. To rule out this possibility, rebuild everything from scratch, and re-run. |
| | 42 | * If the problem is still present, you should send the [wiki:#How_do_I_generate_a_backtrace? backtrace] to the IPP developers. |
| | 43 | |
| | 44 | |
| | 45 | ==== How do I generate a backtrace? ==== |
| | 46 | |
| | 47 | * If you have a core dump (typically named something like <code>core.12345</code>, or just <code>core</code>), then do: |
| | 48 | <pre> |
| | 49 | % gdb programName core.12345 |
| | 50 | (gdb) backtrace full |
| | 51 | </pre> |
| | 52 | * You may not get a core dump if your resource limits are set to prohibit them. To turn on core dumps, do: |
| | 53 | <pre> |
| | 54 | % limit coredumpsize unlimited # tcsh |
| | 55 | % ulimit -c ulimited # bash |
| | 56 | </pre> |
| | 57 | * To produce a backtrace without a core dump, run the program under <code>gdb</code>, e.g.: |
| | 58 | <pre> |
| | 59 | % gdb pxinject |
| | 60 | (gdb) run -newExp -tmp_exp_name simtest. |
| | 61 | 005.003 -tmp_inst /Users/tgrav/Work/Software/IPP/ipp-2.6.1-darwin/ |
| | 62 | default.darwin/share/ippconfig/simtest/camera.config -tmp_telescope / |
| | 63 | Users/tgrav/Work/Software/IPP/ipp-2.6.1-darwin/default.darwin/share/ |
| | 64 | ippconfig/simtest/camera.config -workdir /Users/tgrav/Work/ |
| | 65 | Observations/IPP/SIM/work -dvodb /Users/tgrav/Work/Observations/IPP/ |
| | 66 | SIM/DVO -tess_id /Users/tgrav/Work/Observations/IPP/SIM/TESS -label |
| | 67 | wait -dbname ippTest001 -trace pastro 10 |
| | 68 | ... |
| | 69 | Bus error |
| | 70 | (gdb) backtrace full |
| | 71 | </pre> |