rsync
rsync排除一些文件和目录
exclude.txt:
krp_gpu_uni_predict_server/tools/log-collector/logs/stderr.log*
krp_gpu_uni_predict_server/tools/log-collector/logs/stdout.log*
krp_gpu_uni_predict_server/tools/core-collector/logs/stderr.log*
krp_gpu_uni_predict_server/tools/core-collector/logs/stdout.log*
krp_gpu_uni_predict_server/data/item_doc.binlog*
krp_gpu_uni_predict_server/data/item_doc*.binlog
krp_gpu_uni_predict_server/data/item_doc*.binlog.tmp
krp_gpu_uni_predict_server/bin/supervise/control
krp_gpu_uni_predict_server/bin/supervise/ok
*.backtrace
bin/krp_gpu_uni_predict_server
bin/perfutil.log.*
krp_gpu_uni_predict_server/log
cmd:
rsync -acvP --exclude-from=exclude.txt krp_gpu_uni_predict_server mig
远程服务器执行命令,本地桌面在命令结束后收到通知
远程服务器命令
source teams/reco-arch/uni-predict-v2/build/custom-tf2-cpu.sh && ENABLE_DISTCC=true OPTIMIZATION_LEVEL=-O3 nohup sh -c "kbuild build -v dragon/server/BUILD --targets=opt --base_tag=HEAD_GCC10_LLD > tmp/.build.log.`nowstr.sh` 2>&1 ; echo 'cpu done' > /tmp/notify.txt ; scp /tmp/notify.txt kice@macos:/tmp/ " &
本地监控文件
/opt/homebrew/bin/bash /Users/kice/bin/macosnotify.sh
macosnotify.sh里面的内容
Mac|2024-01-30 11:17:58[kice@~]cat ~/bin/macosnotify.sh
#/opt/homebrew/bin/bash
if [[ -f "/tmp/notify.txt" ]]; then /opt/homebrew/bin/terminal-notifier -title "Terminal" -message "`cat /tmp/notify.txt`"; fi
linux打印所有线程的名称
ps H -o 'tid comm'| grep FollyLifoThread > /tmp/folly.txt
进一步,找到 nonvoluntary_ctxt_switches
for I in `cat /tmp/folly.txt | awk '{print $1}'`; do grep nonvoluntary_ctxt_switches /proc/$I/status; done > /tmp/nonvoluntary_ctxt_switches.txt
cat /tmp/nonvoluntary_ctxt_switches.txt | awk '{print $2}' | paste -sd+ | bc -l
rpm命令
https://www.cyberciti.biz/faq/howto-list-installed-rpm-package/
docker
You will need to save the Docker image as a tar file:
docker save -o <path for generated tar file> <image name>
Then copy your image to a new system with regular file transfer tools such as cp, scp, or rsync (preferred for big files). After that you will have to load the image into Docker:
docker load -i <path to image tar file>
done
how to change access time of file
mount -o strictatime <drive> <mount_point>
ffmpeg merge video
ffmpeg -i video.webm -i audio.webm -c copy Improve_your_Speaking_and_Conversational_skills_with_me_English_Speaking_Practice.mkv