How to use system calls on JUGENE?
Because the compute nodes on the Blue Gene/P do not have a full Linux kernel implementation, some system routines are not available. Especially the "fork()", the "exec()" and the "call system" in FORTRAN do not work. However, there are replacement routines which can be used instead. You can find available routines in the Blue Gene/P Application Development Redbook
Hints for FORTRAN users: These routines are C routines but the FORTRAN compiler includes them automatically as well. You just have to be careful when using strings, they have to have the "\\0" as last character. You can either add this to the string which you pass to the C routines or you can use the following compiler flag:
Here an example FORTRAN program which renames "file1" to "file1a" and "file2" to "file2a":
character*5 :: filen1='file2'
character*6 :: filen2='file2a'
if (my_rank == 0) then
write(*,*) 'Moving file1 to file1a'
write(*,*) 'Moving ',filen1,' to ',filen2
mpixlf90 -qnullterm *.f90