加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Linux > 正文

开发技巧记录

发布时间:2020-12-14 01:08:01 所属栏目:Linux 来源:网络整理
导读:定时记录top的信息命令:? watch -n 1 " top -b -d 1 -n 1 mem.log " ? find查找命令,按照文件检索过滤: find . -type f | xargs grep ? rsync命令模板: /usr/local/bin/rsync -vczrtopg -P --timeout= 60 --bwlimit= 10000 --port 873 --password- file
  • 定时记录top的信息命令:?
    watch -n 1 "top -b -d 1 -n 1 >> mem.log"

    ?

  • find查找命令,按照文件检索过滤:
    find . -type f | xargs grep 

    ?

  • rsync命令模板:
    /usr/local/bin/rsync -vczrtopg -P --timeout=60 --bwlimit=10000 --port 873 --password-file=/etc/rsyncd/thshq.passwd [email?protected]127.0.0.1::shase/temp.tar.gz .

    ?

  • system函数使用坑点记录:http://www.voidcn.com/article/p-xscqakna-bok.html
  • 健身技巧记录:
    胸:杠铃平板卧推  5组每组12次 组间休息1-2分钟
            哑铃上斜卧推  5组每组12次 组间休息1-2分钟
            双杠臂屈伸    如可以可以做,就同上,如果做不了,就努力做1-3个为一组
            龙门架夹胸     4组每组15-20次(这个重量可以轻一些)
           
    背:引体向上  确保提胸 不要让背勾起来,尽力做四组,不限次数,力竭为止
            硬挂              5组每组12次   动作需要网上学习,动作复杂。
            哑铃划船    每只手5组   每组12次
            高位下拉    反手握把  握距与肩膀同宽  5组每组12次
           
    肩: 杠铃坐姿推举(不要使用史密斯架 推的时候身体可以稍微倾斜,不要刻意使身体和地面垂直)
            哑铃侧平举   小重量多次数,切记要肘子高于手腕   5组每组20-30次
            哑铃俯身飞鸟   动作网上学   同上
            哑铃前平举     双手交替做  每只手12次五组

    ?

  • 排名前十的命令使用:
    history | awk {CMD[$2]++;count++;} END { for (a in CMD )print CMD[ a ]" " CMD[ a ]/count*100 "% " a } | grep -v "./" | column -c3 -s " " -t |sort -nr | nl | head -n10 

    ?

  • gdb屏蔽管道破裂命令:
    handle SIGPIPE nostop noprint

    ?

  • valgrind使用基本:
    valgrind --tool=memcheck --leak-check=full ./test     参考:https://blog.csdn.net/justenjoyitpy/article/details/77877038

    ?

  • wireshark抓包过滤命令:
    1.过滤对应的源ip和port
    
    host 192.168.0.1 //抓取192.168.0.1 收到和发出的所有数据包
    src host 192.168.0.1 //源地址,192.168.0.1发出的所有数据包
    dst host 192.168.0.1 //目标地址,192.168.0.1收到的所有数据包
    
    tcp port 23 and host 192.168.0.1
    tcp.port==23&&ip.addr==192.168.0.1
    
    2.过滤对应的关键词:
    tcp contains kmatch   【使用contains关键词】
    
    
    
    3.条件:
    非: ! or “not” (去掉双引号)
    且: && or “and”
    或: || or “or”

    ?

  • tcpdump常用命令:
    tcpdump -i eth0 port 58298 -s 0 -X
    
    tcpdump –i any –X –v –vv tcp and dst port 6379

    ?

  • top详细解释:https://linuxtools-rst.readthedocs.io/zh_CN/latest/tool/top.html
  • bash编程常用判别式:http://blog.chinaunix.net/uid-23802873-id-3523169.html

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读