zhaowawj / ks

my knowledge summary
0 stars 0 forks source link

linux commands #7

Open zhaowawj opened 6 years ago

zhaowawj commented 6 years ago

conversion, read raw file

echo $((base#number)) any base to decimal conversion

echo 'ibase=16; obase=10; B87' | bc base x -----> base y 16进制只认大写

$ echo '6^6' | bc

head -1 /dev/urandom first 1 line

  1. Display contents of file in octal format using -b option: $od -b input
  2. Display contents of file in character format using -c option: $ od -c input
  3. Display limited bytes in output using -N option: $ od -N9 -c input
  4. Display output as hexadecimal 2 byte units using -x option: $ od -x input
  5. Display the contents as two byte octal units using -o option: $ od -o input $ od input

    vim

format: 1. gg 2. %=G

zhaowawj commented 6 years ago

find / -size +1G -exec ls -lh {} \;

du -hs logs du -hs *

curl -U user:passwd -x my-proxy:8080 http://www.getthis.com curl -k -x 127.0.0.1:8087 https://www.google.com.hk curl .curlrc wget .wgetrc

iostat -c -d -x -k 3

zhaowawj commented 6 years ago

程序构建: configure, make, gcc 程序调试: gdb, pstack, strace 目标文件分析: nm, objdump, readelf, size, file, strings, fuser, xxd, od 性能优化: top, free, iostat, pstack, pstrace, gprof, valgrind, oprofile, sar

zhaowawj commented 6 years ago

hostname,uname,ifconfig,dig,ping,traceroute,iptable,tcpdump iostat,netstat, curl,wget sed,awk find,grep,sort,uniq,wc ps,top,free,kill ssh,scp,sftp,telnet echo,printf,yes,seq,clear expr,dc date,ntpdate sleep,watch,at,crontab