随笔分类 -  shell

Some simple shell scripts
摘要:#!/bin/bash startT=`date +%Y-%m-%dT%H:%M:%S`echo "TIMESTAMP CONTAINER ID NAME CPU % MEM USAGE / LIMIT MEM % NET I/O BLOCK I/O PIDS\n">>mem.$startT.txt 阅读全文
posted @ 2020-06-04 12:50 buptqq 阅读(239) 评论(0) 推荐(0)
摘要:查找file1中每一行是否在file2中,若在输出到InRight.txt, 若不在输出到NotInRight.txt. f1=$1f2=$2 while read mylinedo grepR=`grep $myline $f2` if [[ $grepR != "" ]]; then echo 阅读全文
posted @ 2020-06-04 12:48 buptqq 阅读(200) 评论(0) 推荐(0)