php
性能函数检查工具 xhprof
Calls:方法被调用的次数。
Calls%:方法调用次数在同级方法总数调用次数中所占的百分比。
Incl.Wall Time(microsec):方法执行花费的时间,包括子方法的执行时间。(单位:微秒)
IWall%:方法执行花费的时间百分比。
Excl. Wall Time(microsec):方法本身执行花费的时间,不包括子方法的执行时间。(单位:微秒)
EWall%:方法本身执行花费的时间百分比。
Incl. CPU(microsecs):方法执行花费的CPU时间,包括子方法的执行时间。(单位:微秒)
ICpu%:方法执行花费的CPU时间百分比。
Excl. CPU(microsec):方法本身执行花费的CPU时间,不包括子方法的执行时间。(单位:微秒)
ECPU%:方法本身执行花费的CPU时间百分比。
Incl.MemUse(bytes):方法执行占用的内存,包括子方法执行占用的内存。(单位:字节)
IMemUse%:方法执行占用的内存百分比。
Excl.MemUse(bytes):方法本身执行占用的内存,不包括子方法执行占用的内存。(单位:字节)
EMemUse%:方法本身执行占用的内存百分比。
Incl.PeakMemUse(bytes):Incl.MemUse峰值。(单位:字节)
IPeakMemUse%:Incl.MemUse峰值百分比。
Excl.PeakMemUse(bytes):Excl.MemUse峰值。单位:(字节)
EPeakMemUse%:Excl.MemUse峰值百分比。
============================
git
You asked me to pull without telling me which branch you
want to merge with, and 'branch.develop.merge' in
your configuration file does not tell me, either. Please
specify which branch you want to use on the command line and
try again (e.g. 'git pull <repository> <refspec>').
See git-pull(1) for details.
git branch --set-upstream master origin/master
===========================
go
tar zxvf go1.7.4.linux-amd64.tar.gz -C $GO_INSTALL_DIR
export GOROOT=/usr/local/go
export GOPATH=$HOME/go
export PATH=$PATH:$GOROOT/bin
#运行同步
mysql-schema-
sync
-conf mydb_conf.json -
sync
#预览并生成变更sql
mysql-schema-
sync
-conf mydb_conf.json 2>
/dev/null
>db_alter.sql
自动定时运行
添加crontab 任务
30 * * * * cd /your/path/xxx/ && bash check.sh >/dev/null 2>&1
======================================================
wrk 压力测试工具
======================================================
lsof -i :3000 |grep "(LISTEN)" 查看端口占用
nohup command > myout.file 2>&1 &
======================================================
#!/bin/sh
#添加本地执行路径
#export LD_LIBRARY_PATH=./
while true; do
#启动一个循环,定时检查进程是否存在
server=`lsof -i :3000 |grep "(LISTEN)"`
if [ ! "$server" ]; then
#如果不存在就重新启动
nohup node ./index.js &
#启动后沉睡10s
sleep 10
fi
#每次循环沉睡10s
sleep 5
done
=====================================================
vim
1,$!sort -r -n -k12,13 排序