05 2017 档案

摘要:1.查看http的并发请求数与其TCP连接状态 netstat -n | grep '^tcp' | awk '{print $6}' | sort | uniq -c 2.用tcpdump嗅探80端口的访问看看谁最高 tcpdump -i eth0 -tnn dst port 80 -c 1000 阅读全文
posted @ 2017-05-18 11:35 孤鸟的悲歌丶 阅读(343) 评论(0) 推荐(0)
摘要:先授权一个用户对所要备份的库权限 grant select,lock tables on zabbix.*to 'backup'@'localhost' identified by '123456' #!/bin/bash#grant select,lock tables on zabbix.*to 阅读全文
posted @ 2017-05-17 09:19 孤鸟的悲歌丶 阅读(169) 评论(0) 推荐(0)
摘要:#!/bin/bash#read -p "Input username: " username while :;docat << EOFU|u) show UIDG|g) show GIDS|s) show SHELLQ|q) quit.R|r) Re-select the user.EOF jud 阅读全文
posted @ 2017-05-11 19:19 孤鸟的悲歌丶 阅读(357) 评论(0) 推荐(0)
摘要:#!/bin/bash#function menu(){cat << EOFd|D) show disk usagesm|M) show memory usagess|S) show swap usagesq|Q) quit.EOF}while :;do menuread -p "Your choi 阅读全文
posted @ 2017-05-11 14:54 孤鸟的悲歌丶 阅读(203) 评论(0) 推荐(0)
摘要:#!/bin/bash#function user {judge=`id -u $1 &>/dev/null` if [ $? -eq 0 ];then uid=`id -u $1` Shell=`grep "$1" /etc/passwd | awk -F : '{print $7}' ` ech 阅读全文
posted @ 2017-05-11 14:50 孤鸟的悲歌丶 阅读(3897) 评论(0) 推荐(0)
摘要:#!/bin/bash function detect(){ ping=`ping -c 1 $1 &>/dev/null`} for i in {0..254};do detect 193.168.1.$i if [ $? -eq 0 ];then echo -e "\033[32mIP 193. 阅读全文
posted @ 2017-05-11 11:47 孤鸟的悲歌丶 阅读(355) 评论(0) 推荐(0)