我将一个批处理文件发送到一个 slurm 集群,该集群 awks 相同 infile 的字段并附加到输出。前几行有效,但随后突然死亡。它在第二次回响之前就死了。如果有人会调试或向我展示更好的脚本会很好,但我想知道为什么(或是否)bash 文件在一遍又一遍地执行相同的工作时会崩溃。
#!/bin/bash
#SBATCH -A b2014091
#SBATCH -p core
#SBATCH -n 1
#SBATCH -t 23:00:00
#SBATCH -J sbatch
#input was MK...vcf
input=$1
output=$(grep -v '^#' ${input} | awk '(substr($12,1,3)=="1/1") && (substr($15,1,3)=="1/1") {print $0}')
echo "$output\n" >> /proj/b2014091/nobackup/potHomoF1.txt
output=$(grep -v '^#' ${input} | awk '(substr($12,1,3)=="0/0") && (substr($15,1,3)=="0/0") {print $0}')
echo "$output\n" >> /proj/b2014091/nobackup/potHomoF1.txt
output=$(grep -v '^#' ${input} | awk '(substr($12,1,3)=="1/1") && (substr($15,1,3)=="./.") {print $0}')
echo "$output\n" >> /proj/b2014091/nobackup/potHomoF1.txt
output=$(grep -v '^#' ${input} | awk '(substr($12,1,3)=="./.") && (substr($15,1,3)=="1/1") {print $0}')
echo "$output\n" >> /proj/b2014091/nobackup/potHomoF1.txt
output=$(grep -v '^#' ${input} | awk '(substr($12,1,3)=="0/0") && (substr($15,1,3)=="./.") {print $0}')
echo "$output\n" >> /proj/b2014091/nobackup/potHomoF1.txt
output=$(grep -v '^#' ${input} | awk '(substr($12,1,3)=="./.") && (substr($15,1,3)=="0/0") {print $0}')
echo "$output\n" >> /proj/b2014091/nobackup/potHomoF1.txt
错误信息:
slurmstepd:get_exit_code 任务 0 因信号而死
字段 12-15 的示例:
1/1:0,38:38:99:1149,114,0 1/1:0,39:39:99:1161,117,0 1/1:0,46:46:99:1383,138,0 0/1:21,18:39:99:413,0,524