zoukankan      html  css  js  c++  java
  • 常用shell

    namp -sP 192.168.1.0/24
    getconf LONG_BIT
    sudo cpulimit -p pid -l 50
    :w !sudo tee > /dev/null %
    rename 'y/A-Z/a-z/' * 将当前的文件改成小写
    rename 'y/a-z/A-Z/' *
    tail -10000 access_log | awk '{print $1}' | sort | uniq -c | sort -n | tail 找apache中最常见的ip
    ffmpeg -vcodec copy -acodec copy -i orginalfile -ss 00:01:30 -t 0:0:20 newfile 取一段视频
    history | awk '{print $2}' | sort | uniq -c | sort -rn | head 最常用命令
    :g/^$/d 用vim消除所有空行
    wget $URL | htmldoc --webpage -f "$URL".pdf - ; xpdf "$URL".pdf & 存储网页为pdf
    ffmpeg -i video.flv -vn -ar 44100 -ac 2 -ab 192k -f mp3 audio.mp3 提取音频
    convert *.jpg output.pdf
    echo {0..1}{0..1}{0..1}{0..1} 生成二进制,四位数
    man -t awk | ps2pdf - awk.pdf 把manpage存储为pdf
    echo $0 正在使用的shell
    !$ 上一个命令的最后一个参数
    sudo -K 
    !:1-3 上一个命令的1-3个参数,从0开始
    echo -e "Some Text Line1
    Some Text Line 2" | convert -background none -density 196  -resample 72 -unsharp 0x.5 -font "Courier" text:- -trim +repage -bordercolor white -border 3  text.gif 文本转化为图片
    truncate -s0 file 清空文件 
    make -j 4 用所有cpu编译
    curl -I www.commandlinefu.com 获取http头
    vi scp://username@host//path/to/somefile 编辑一个remote File
    fuser -v 80/tcp 显示80端口的程序pid
    who -b 上次重启时间 
    nmap -sP 192.168.1.100-254  ping一个范围
    watch vmstat -sSM 内存使用情况
    nmap -sP 192.168.1.0/24; arp -n  | grep "192.168.1.[0-9]* *ether" 找出所有活动主机
    mkdir -p doc/{text/,img/{wallpaper/,photos/}} 创建dirs树
    ffmpeg -i video.avi -f mp3 audio.mp3
    wget -r -l1 -H -t1 -nd -N -np -A.mp3 -erobots=off [url of website] 下载所有.mp3
    convert -resize '1024x600^' image.jpg small-image.jpg 缩放jpg
    oowriter -pt pdf your_word_file.doc doc变pdf
    sudo arp-scan -I eth0 192.168.1.0/24 查找活动Ip
    dmidecode -t bios 显示BIOS
    ps aux --sort=%mem,%cpu 进程排序
    hdparm -t /dev/sda 测试硬盘读写速度
    screen -x
    sudo dd if=/dev/sda of=/media/disk/backup/sda.backup  备份硬盘
    

    每天早上叫醒你的不是闹钟,而是心中的梦~
  • 相关阅读:
    win10家庭版添加远程桌面服务功能
    GNS3测试NAT元件功能
    prometheus监控系统之snmp-exporter部署来监控交换机端口流量
    GNS3内网配置虚拟机测试
    GNS3内网通过cloud与实际网络实现互连互通的实验(使用环回网口)
    添加对docker的监控
    docker环境下的Grafana安装
    prometheus配置pushgateway功能测试
    京东html面单
    顺丰html面单
  • 原文地址:https://www.cnblogs.com/vintion/p/4116848.html
Copyright © 2011-2022 走看看