摘要:
一,安装#yum install -y wireshark 二.具体使用案例 1.抓取500个包,提取访问的网址打印出来tshark -s 0 -i eth0 -n -f 'tcp dst port 80' -R 'http.host and http.request.uri' -T fields
阅读全文
posted @ 2016-11-11 17:35
rorshach
阅读(750)
推荐(0)
摘要:
这么大跨度的升级,本身不推荐.升级应该是循序渐进的,以防止不兼容.如果确实要这么做,你先要确保你的客户端管理工具要能兼容,比如phpmyadmin,此次升级依然存在一个问题,mysql server和mysql client不匹配的问题. 一.升级前1.先备份数据#mysqldump --all-d
阅读全文
posted @ 2016-11-11 16:52
rorshach
阅读(4915)
推荐(0)
摘要:
php-fpm 启动:/usr/sbin/php-fpmphp-fpm 关闭:kill -INT `cat /var/run/php-fpm.pid`php-fpm 重启:kill -USR2 `cat /var/run/php-fpm.pid` php-fpm 查询进程netstat -napo
阅读全文
posted @ 2016-10-20 17:52
rorshach
阅读(248)
推荐(0)
摘要:
查看系统目前打开的文件数命令#cat /proc/slabinfo | grep ip_conn | grep -v ip_conntrack_expect | awk '{print $2}' 查看系统文件数限制#ulimit -n
阅读全文
posted @ 2016-10-19 13:53
rorshach
阅读(150)
推荐(0)
摘要:
1.直接修改/etc/resolv.conf,重启网卡 后发现并没有修改掉 2.直接修改ifcfg-eth0文件 增加或修改至文件末尾 然后重启网卡 发现生效
阅读全文
posted @ 2016-10-09 17:00
rorshach
阅读(1172)
推荐(0)
摘要:
官网:http://www.mycat.org.cn/ 一.jdk环境的安装1.安装jdk1.7,这是mycat推荐的jdk环境 2.之前是用yum安装的jdk1.6,首先查找下 3.删除jdk1.6 4.安装jdk1.7 二.mysql主从配置略 三.安装mycat1.下载 2.解压 四.配置my
阅读全文
posted @ 2016-10-09 16:52
rorshach
阅读(4209)
推荐(0)
摘要:
1.查看当前环境变量 #echo $PATH 2.增加环境变量 #vi /etc/profile export PATH=/usr/path/bin:$PATH 3.生效 #source /etc/profile
阅读全文
posted @ 2016-10-06 21:02
rorshach
阅读(228)
推荐(0)
摘要:
apache2.2使用mod_remoteip模块 一.安装 wget https://github.com/ttkzw/mod_remoteip-httpd22/raw/master/mod_remoteip.c/usr/local/apache/bin/apxs -i -c -n mod_rem
阅读全文
posted @ 2016-10-06 20:58
rorshach
阅读(1032)
推荐(0)
摘要:
零.前言1.官网 http://trafficserver.apache.org/2.国内社区 https://blog.zymlinux.net3.简洁明了的配置:http://blog.csdn.net/tiantiandjava/article/details/50327855 一.ats安装
阅读全文
posted @ 2016-10-06 20:47
rorshach
阅读(3224)
推荐(0)
摘要:
1、允许PING设置 iptables -A INPUT -p icmp --icmp-type echo-request -j ACCEPT iptables -A OUTPUT -p icmp --icmp-type echo-reply -j ACCEPT 或者也可以临时停止防火墙操作的。 s
阅读全文
posted @ 2016-09-29 08:27
rorshach
阅读(5674)
推荐(0)
摘要:
linux建立文件夹软连接,并强制覆盖 ln -sfn /home/var/log/httpd/logs logs 这将在当前目录下建立logs软连接,指向/home/var/log/httpd/logs,如果存在logs软连接,将强制覆盖
阅读全文
posted @ 2016-08-10 15:09
rorshach
阅读(23774)
推荐(2)
摘要:
一.安装nginx 二.安装luajit2.0 三.安装ngx_devel_kit#wget https://github.com/simpl/ngx_devel_kit/archive/v0.2.19.tar.gz --no-check-certificate#tar -zxvf v0.2.19
阅读全文
posted @ 2016-05-09 16:11
rorshach
阅读(925)
推荐(0)
摘要:
一.mysqldumpslow为mysql自带,安装后既带有该工具. 二.mysqldumpslow经常使用的参数 -s,是order的顺序 al 平均锁定时间 ar 平均返回记录时间 at 平均查询时间(默认) c 计数 l 锁定时间 r 返回记录 t 查询时间 -t,是top n的意思,即为返回
阅读全文
posted @ 2016-05-04 15:12
rorshach
阅读(451)
推荐(0)
摘要:
一.strace参数 strace是Linux环境下的一款程序调试工具,用来监察一个应用程序所使用的系统调用及它所接收的系统信息。追踪程序运行时的整个生命周期,输出每一个系统调用的名字,参数,返回值和执行消耗的时间等。strace常用参数:-p 跟踪指定的进程-f 跟踪由fork子进程系统调用-F
阅读全文
posted @ 2016-05-04 15:10
rorshach
阅读(2019)
推荐(0)
摘要:
状态名 作用域 详细解释 Aborted_clients Global 由于客户端没有正确关闭连接导致客户端终止而中断的连接数 Aborted_connects Global 试图连接到MySQL服务器而失败的连接数 Binlog_cache_disk_use Global 使用临时二进制日志缓存但超过binlog_cache_size值并使用临时文件来保存事务中的语句的事务数量...
阅读全文
posted @ 2016-05-04 15:09
rorshach
阅读(476)
推荐(0)
摘要:
在mysql工具中如phpmyadmin中执行show engine innodb status;注意观察Log sequence number 60秒后再次执行 获取Log sequence number log_diff_minutes = 第二次的Log sequence number - 第
阅读全文
posted @ 2016-05-04 15:08
rorshach
阅读(2737)
推荐(0)
posted @ 2016-05-03 20:31
rorshach
阅读(207)
推荐(0)
摘要:
一.下载安装jemalloc 二.在mysqld_safe文件中导入 # executing mysqld_safe #jemallocexport LD_PRELOAD=/usr/local/jemalloc/lib/libjemalloc.so 三.查看是否导入成功
阅读全文
posted @ 2016-05-03 19:40
rorshach
阅读(786)
推荐(0)
摘要:
使用要创建登录密匙的账号登录 生成密匙 生成时提示输入密码,如果不输入,则直接回车即可,如果输入,将在无密匙登陆时要求输入该密码 进入生成目录.ssh 重命名id_rsa.pub为authorized_keys 并将authorized_keys设置权限为400(不可写) 将.ssh目录下的id_r
阅读全文
posted @ 2016-05-03 15:07
rorshach
阅读(183)
推荐(0)
摘要:
查看vsftpd是否支持ssl 输出 libssl.so.6 => /lib64/libssl.so.6 (0x00002ba684304000) 表示支持 使用openssh生成密匙 配置vsftpd.conf,加入以下文件 重启vsftpd服务 ftp使用tls连接出现:500 Illegal
阅读全文
posted @ 2016-05-03 13:46
rorshach
阅读(1087)
推荐(0)
摘要:
#!/bin/bash mysqladmin -uroot -p'123456' extended-status -i1|awk 'BEGIN{local_switch=0;print "QPS Commit Rollback TPS Threads_con Threads_run \n------------------------------------------------...
阅读全文
posted @ 2016-05-02 11:27
rorshach
阅读(660)
推荐(0)
摘要:
innodb_buffer_pool_size参数大小建议: 查看Innodb_buffer_pool_pages_data大小,即已使用页面 查看Innodb_buffer_pool_pages_total大小,总计页面 按如下结算设置'Innodb_buffer_pool_pages_data'
阅读全文
posted @ 2016-05-02 11:23
rorshach
阅读(1493)
推荐(0)
摘要:
linux下使用top命令或uptime命令 单核cpu下,负载超过0.7即意味着瓶颈,多核cpu下按核数*0.7计算负载 如2核,1.4可能即意味着负载较吃力了 查看核数
阅读全文
posted @ 2016-05-02 11:14
rorshach
阅读(1446)
推荐(0)
摘要:
一.查看攻击者ip 二.安装ddos deflate 三.配置DDoS deflate下面是DDoS deflate的默认配置位于/usr/local/ddos/ddos.conf ,内容如下: 用户可根据给默认配置文件加上的注释提示内容,修改配置文件。查看/usr/local/ddos/ddos.
阅读全文
posted @ 2016-04-30 16:31
rorshach
阅读(520)
推荐(0)
摘要:
使用 来查看可疑ip登录查看/var/log/secure保存的系统信息来确定可以ip登录
阅读全文
posted @ 2016-04-30 12:05
rorshach
阅读(259)
推荐(0)
摘要:
#!/bin/bash while read line do $line & done < /path/filename
阅读全文
posted @ 2016-04-30 11:49
rorshach
阅读(2337)
推荐(0)
摘要:
table_cache 参数设置表高速缓存的数目。每个连接进来,都会至少打开一个表缓存。因此, table_cache 的大小应与 max_connections 的设置有关。例如,对于 200 个并行运行的连接,应该让表的缓存至少有 200 × N ,这里 N 是应用可以执行的查询的一个联接中表的
阅读全文
posted @ 2016-04-30 11:27
rorshach
阅读(382)
推荐(0)
摘要:
一.nmon下载地址http://nmon.sourceforge.net/pmwiki.php?n=Site.Download 二.下载centos5对应版本nmon_linux_14i.tar.gz 三.解压 四.常用参数
阅读全文
posted @ 2016-04-26 10:40
rorshach
阅读(247)
推荐(0)
摘要:
一,下载ext3grep-0.10.1.tar.gz 点此下载 二,安装 如果缺乏e2fsprogs-devel和e2fsprogs-devel,yum安装 三.模拟删除1.制造一个分区 2.挂载 /dev/sda1 485M 32M 429M 7% /boot/home/test/file 49M
阅读全文
posted @ 2016-04-25 19:41
rorshach
阅读(449)
推荐(0)
摘要:
简单的cc攻击防御cckiller一.下载#wget wget --no-check-certificate https://zhangge.net/wp-content/uploads/files/cckiller/install.sh?ver=1.0.1 二.安装#mv install.sh?v
阅读全文
posted @ 2016-04-25 18:26
rorshach
阅读(287)
推荐(0)
摘要:
一.首先关闭防火墙#service iptables stop二.查看状态,确认关闭#service iptables status三.清除掉防火墙规则#iptables -F#iptables -X三.接收所有的output和forward#iptables -P OUTPUT ACCEPT#ip
阅读全文
posted @ 2016-04-25 17:33
rorshach
阅读(236)
推荐(0)
摘要:
1.linux启用网卡,#vi /etc/sysconfig/network-scripts/ifcfg-eth0将ONBOOT=no改为yes 设置静态ip 重启network #service networ restart2.#free -m 命令 total used free shared
阅读全文
posted @ 2016-04-24 16:32
rorshach
阅读(177)
推荐(0)
摘要:
1.安装#yum install sysstat2.启动#/etc/init.d/sysstat start3.自启动#checkfig sysstat4.基本使用#iostat -k 2每两秒刷新一次Device: tps kB_read/s kB_wrtn/s kB_read kB_wrtnsc
阅读全文
posted @ 2016-04-24 16:20
rorshach
阅读(274)
推荐(0)
摘要:
php-fpm中比较重要的两项参数是:request_terminate_timeoutpm.max_children request_terminate_timeout该值决定了php-fpm进程的连接读取和发送,如果将该值设置的过小,将会出现502或504错误,该指令默认为0,就是不启用. 如果
阅读全文
posted @ 2016-04-24 16:08
rorshach
阅读(362)
推荐(0)
摘要:
Nginx编译安装1.nginx官网:http://wiki.nginx.org/Install下载:http://nginx.org/en/download.html2.编译安装# wget http://nginx.org/download/nginx-1.8.0.tar.gz# tar -zv
阅读全文
posted @ 2016-04-24 16:01
rorshach
阅读(165)
推荐(0)
摘要:
一.下载php-7.0.5http://cn2.php.net/distributions/php-7.0.5.tar.gz二.解压安装:# tar zxvf php-7.0.5.tar.gz# cd php-7.0.5配置#./configure --prefix=/usr/local/php7
阅读全文
posted @ 2016-04-24 15:40
rorshach
阅读(1431)
推荐(0)
摘要:
1.profile在mysql5.0.37及其以上版本中可用 2.查看profile是否可用SELECT @@profiling;来查看是否已经启用profile,如果profilng值为0,可以通过SET profiling = 1;启用mysql>select count(*) from roi
阅读全文
posted @ 2016-04-24 15:19
rorshach
阅读(3697)
推荐(0)
摘要:
一.amoeba介绍网址:http://docs.hexnova.com/amoeba/二.安装java se1.5三.安装amoeba2.2.01.下载地址:http://sourceforge.net/projects/amoeba/files/,下载amoeba-mysql-binary-2.
阅读全文
posted @ 2016-04-24 15:10
rorshach
阅读(526)
推荐(0)
摘要:
查看Nginx并发状态 #netstat -n | awk '/^tcp/ {++S[$NF]} END {for(a in S) print a, S[a]}' TIME_WAIT 1259SYN_SENT 2FIN_WAIT1 8ESTABLISHED 166FIN_WAIT2 24SYN_RE
阅读全文
posted @ 2016-04-23 10:10
rorshach
阅读(2508)
推荐(0)
摘要:
一,查看工作模式 /usr/sbin/httpd -l Compiled in modules: core.c prefork.c http_core.c mod_so.c 如果出现prefork.c,表示apache工作在prefork模式下 二,prefork调优 ServerLimit 300
阅读全文
posted @ 2016-04-23 09:13
rorshach
阅读(4618)
推荐(0)