map2cam running out of file descriptors #3841
Labels
bug
Something isn't working
good first issue
Good for newcomers
Products
Issues which are impacting the products group
ISIS version(s) affected: 4.0.1 and most likely nearly any recent version
Description
map2cam run in batch mode with 2000 images in the batch file fails around file 1018:
map2cam from= themosmap/mc02_diacria_dir_final.cub to=themosmap/$1_mapIR match=$1 -batch=cub.lis -onerror=continue -errli=mapthem.err
LOTS OF NOT SHOWN LINES WHERE map2cam WAS SUCCEEDING
map2cam from=themosmap/mc02_diacria_dir_final.cub to=themosmap/H0682_0003_SR2.IMG.cub_mapIR match=H0682_0003_SR2.IMG.cub
I/O ERROR Unable to open [H0682_0003_SR2.IMG.cub].
map2cam from=themosmap/mc02_diacria_dir_final.cub to=themosmap/H0682_0004_SR2.IMG.cub_mapIR match=H0682_0004_SR2.IMG.cub
terminate called after throwing an instance of 'Isis::IException'
what(): I/O ERROR Unable to open [/scratch/repos/hrsc-ssides/build/appdata/templates/labels/CubeFormatTemplate.pft].
Aborted (core dumped)
It looks like map2cam is not closing a file inside the batch loop.
ulimit -n shows an open file limit of 1024.
Running lsof while the batch is running shows that all the MATCH files remain open until the crash.
How to reproduce
See description
Possible Solution
Close the MATCH file when the ISIS main returns
Additional context
The text was updated successfully, but these errors were encountered: