Power supply failed on n0002. Replace and restart job. First use of NAMDautorestart script:
Perl script to prepare files for a restart
#!/usr/bin/perl -w print "\nChecking files:\n"; if ( -e "equi.namd" ) { print " Found: equi.namd\n"; } else { print " Missing equi.namd. Aborting now.\n"; exit; } if ( -e "LOG" ) { print " Found: LOG\n"; } else { print " Missing LOG. Aborting now.\n"; exit; } if ( -e "output/equi_out.dcd" ) { print " Found: output/equi_out.dcd\n"; } else { print " Missing output/equi_out.dcd. Aborting now.\n"; exit; } if ( -e "output/equi_out.xst" ) { print " Found: output/equi_out.xst\n"; } else { print " Missing output/equi_out.xst. Aborting now.\n"; exit; } if ( -e "output/restart.coor" ) { print " Found: output/restart.coor\n"; } else { print " Missing output/restart.coor. Aborting now.\n"; exit; } if ( -e "output/restart.vel" ) { print " Found: output/restart.vel\n"; } else { print " Missing output/restart.vel. Aborting now.\n"; exit; } if ( -e "output/restart.xsc" ) { print " Found: output/restart.xsc\n"; } else { print " Missing output/restart.xsc. Aborting now.\n"; exit; } $count = `grep -c -i "heat_out.vel" equi.namd`; if ( $count == 1 ) { print "\nThis appears to be the first restart.\n\n"; $count = `grep -c -i "restart.coor" equi.namd`; if ( $count > 0 ) { print "Both restart.coor and heat_out.coor used in equi.namd ?\n"; print "Aborting now.\n"; exit; } if ( -e "LOG.1" ) { print "But a LOG.1 exists ? Abort.\n"; exit; } if ( -e "equi.namd.1" ) { print "But a equi.namd.1 exists ? Abort.\n"; exit; } if ( -e "output/RUN_1.dcd" ) { print "But an output/RUN_1.dcd exists ? Abort.\n"; exit; } print "Renaming/moving/removing files:\n"; system("mv LOG LOG.1"); print " Renamed LOG to LOG.1\n"; system("mv equi.namd equi.namd.1"); print " Renamed equi.namd to equi.namd.1\n"; system("mv output/restart.coor ./restart.coor"); print " Moved output/restart.coor to current directory\n"; system("mv output/restart.vel ./restart.vel"); print " Moved output/restart.vel to current directory\n"; system("mv output/restart.xsc ./restart.xsc"); print " Moved output/restart.xsc to current directory\n"; system("mv output/equi_out.dcd output/RUN_1.dcd"); print " Renamed output/equi_out.dcd to output/RUN_1.dcd\n"; system("rm -rf output/equi_out.xst"); print " Removed output/equi_out.xst\n"; system("rm -rf output/restart*.old"); print " Removed output/restart*.old\n"; # # Starting timestep # open XSC, "restart.xsc" or die "Can not open restart.xsc for reading ? Abort.\n"; $line = <XSC>; $line = <XSC>; $line = <XSC>; @words = split( ' ', $line ); $starting_timestep = $words[0]; if ( ! $starting_timestep =~ /^(\d+\.?\d*|\.\d+)$/ ) { print "Starting timestep not a number ? Abort now.\n"; exit; } close( XSC ); print "\nStarting timestep is $starting_timestep\n"; print "Modifying equi.namd ...\n\n"; # # Add restart stuff & new timestep # open IN_NAMD, "equi.namd.1" or die "Can not open equi.namd.1 for reading ? Abort.\n"; open OUT_NAMD, ">equi.namd" or die "Can not open equi.namd file for writing. Abort.\n"; while( $line = <IN_NAMD> ) { if ( $line =~ /coordinates\s+heat_out.coor/ ) { print OUT_NAMD "coordinates heat_out.coor\n"; print OUT_NAMD "bincoordinates restart.coor\n"; print OUT_NAMD "binvelocities restart.vel\n"; print OUT_NAMD "extendedSystem restart.xsc\n"; } elsif ( $line =~ /velocities\s+heat_out.vel/ ) { } elsif ( $line =~ /extendedSystem\s+heat_out.xsc/ ) { } elsif ( $line =~ /velocities\s+heat_out.vel/ ) { } elsif ( $line =~ /firsttimestep\s+\d+/ ) { print OUT_NAMD "firsttimestep $starting_timestep\n"; } else { print OUT_NAMD $line; } } print "All done.\n\n"; exit; } $count = `grep -c -i "restart.vel" equi.namd`; if ( $count == 1 ) { $count = `ls -1 | grep 'LOG.*' | wc -l`; chomp( $count ); print "\nThis will be restart number $count\n\n"; $check = `grep -c -i "heat_out.vel" equi.namd`; if ( $check > 0 ) { print "Both restart.vel and heat_out.vel used in equi.namd ?\n"; print "Aborting now.\n"; exit; } if ( -e "LOG.$count" ) { print "But a LOG.$count exists ? Abort.\n"; exit; } if ( -e "equi.namd.$count" ) { print "But a equi.namd.$count exists ? Abort.\n"; exit; } if ( -e "output/RUN_$count.dcd" ) { print "But an output/RUN_1.dcd exists ? Abort.\n"; exit; } print "Renaming/moving/removing files:\n"; system("mv LOG LOG.$count"); print " Renamed LOG to LOG.$count\n"; system("mv equi.namd equi.namd.$count"); print " Renamed equi.namd to equi.namd.$count\n"; system("mv output/restart.coor ./restart.coor"); print " Moved output/restart.coor to current directory\n"; system("mv output/restart.vel ./restart.vel"); print " Moved output/restart.vel to current directory\n"; system("mv output/restart.xsc ./restart.xsc"); print " Moved output/restart.xsc to current directory\n"; system("mv output/equi_out.dcd output/RUN_$count.dcd"); print " Renamed output/equi_out.dcd to output/RUN_$count.dcd\n"; system("rm -rf output/equi_out.xst"); print " Removed output/equi_out.xst\n"; system("rm -rf output/restart*.old"); print " Removed output/restart*.old\n"; # # Starting timestep # open XSC, "restart.xsc" or die "Can not open restart.xsc for reading ? Abort.\n"; $line = <XSC>; $line = <XSC>; $line = <XSC>; @words = split( ' ', $line ); $starting_timestep = $words[0]; if ( ! $starting_timestep =~ /^(\d+\.?\d*|\.\d+)$/ ) { print "Starting timestep not a number ? Abort now.\n"; exit; } close( XSC ); print "\nStarting timestep is $starting_timestep\n"; print "Modifying equi.namd ...\n\n"; # # Add restart stuff & new timestep # open IN_NAMD, "equi.namd.$count" or die "Can not open equi.namd.1 for reading ? Abort.\n"; open OUT_NAMD, ">equi.namd" or die "Can not open equi.namd file for writing. Abort.\n"; while( $line = <IN_NAMD> ) { if ( $line =~ /firsttimestep\s+\d+/ ) { print OUT_NAMD "firsttimestep $starting_timestep\n"; } else { print OUT_NAMD $line; } } print "All done.\n\n"; exit; } print "Something is wrong. No heat_out.coor, nor restart.coor used ?\n"; print "Aborting now.\n"; exit;