Dear Sumit,
I can only suggest you to try with a lighter script.
Because the errors may come from your script (machinefile?), the MPI library (though I'm pretty confident in your admin) or from Telemac itself.
So, you should separate these tasks :
(1) submit a job with with the -t option o runcode.py. It will generate both TMP directory and the executable ;
(2) write a very minimal script in which you directly run the executable with mpirun from the TMP directory (see the attached script). Try with 12 and 24 procs.
=> If it doesn't work, try to adapt the mpirun syntax.
=> If it works straightforward, I guess there's something in your config or/and the runcode.py script.
Some ideas / improvements :
(1) Delete anything related to the HPC mode in your config file ("hpc_cmdexec: chmod 755 <hpc_stdin>; qsub < <hpc_stdin>", HPC in "options")
(2) Instead, add the QSUB submission at the end of your bash script where you only run "telemac2d.py Bode2DNew.cas" (see the attached sample script, not tested however)
(3) And then, I see no reason for re-generating the config file.
Best regards,
Fabien Decung