Created
October 31, 2014 06:28
-
-
Save jmpcyc/438aa984592f9fb0a13c to your computer and use it in GitHub Desktop.
Linux运维相关命令
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 查看总的访问次数 | |
| cat itv-update.openspeech.cn.access.log | wc -l | |
| 查看访问的ip总数 | |
| cat itv-update.openspeech.cn.access.log | aw '{a[$1]+=1;}END{for(i in a){print i " >> "a[i];}}' | wc -l | |
| 按访问量大小排序所有的访问ip,并且答应出具体的ip 和访问次数 | |
| cat itv-update.openspeech.cn.access.log | awk '{a[$1]+=1;}END{for(i in a){print i " >> "a[i];}}' | sort -nr |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment