diff --git a/garlic/exp/creams/gran+node1.nix b/garlic/exp/creams/gran+node1.nix index f874f36..075d631 100644 --- a/garlic/exp/creams/gran+node1.nix +++ b/garlic/exp/creams/gran+node1.nix @@ -81,8 +81,11 @@ let stages.exec { inherit nextStage; env = '' - cp -r ${input}/SodTubeBenchmark/* . - chmod +w -R . + # Only the MPI rank 0 will copy the files + if [ $SLURM_PROCID == 0 ]; then + cp -fr ${input}/SodTubeBenchmark/* . + chmod +w -R . + fi ''; }; diff --git a/garlic/exp/creams/gran+node16.nix b/garlic/exp/creams/gran+node16.nix index a0b794c..942b474 100644 --- a/garlic/exp/creams/gran+node16.nix +++ b/garlic/exp/creams/gran+node16.nix @@ -79,8 +79,11 @@ let stages.exec { inherit nextStage; env = '' - cp -r ${input}/SodTubeBenchmark/* . - chmod +w -R . + # Only the MPI rank 0 will copy the files + if [ $SLURM_PROCID == 0 ]; then + cp -fr ${input}/SodTubeBenchmark/* . + chmod +w -R . + fi ''; }; diff --git a/garlic/exp/creams/ss+hybrid.nix b/garlic/exp/creams/ss+hybrid.nix index 15fdb72..0b39d36 100644 --- a/garlic/exp/creams/ss+hybrid.nix +++ b/garlic/exp/creams/ss+hybrid.nix @@ -75,8 +75,11 @@ let stages.exec { inherit nextStage; env = '' - cp -r ${input}/SodTubeBenchmark/* . - chmod +w -R . + # Only the MPI rank 0 will copy the files + if [ $SLURM_PROCID == 0 ]; then + cp -fr ${input}/SodTubeBenchmark/* . + chmod +w -R . + fi ''; }; diff --git a/garlic/exp/creams/ss+pure.nix b/garlic/exp/creams/ss+pure.nix index 75bcf5f..244ccd2 100644 --- a/garlic/exp/creams/ss+pure.nix +++ b/garlic/exp/creams/ss+pure.nix @@ -66,8 +66,11 @@ let stages.exec { inherit nextStage; env = '' - cp -r ${input}/SodTubeBenchmark/* . - chmod +w -R . + # Only the MPI rank 0 will copy the files + if [ $SLURM_PROCID == 0 ]; then + cp -fr ${input}/SodTubeBenchmark/* . + chmod +w -R . + fi ''; };