分类导航

最新文章

按月份

  1. nodejs安装及配置

    下载及安装 git clone git://github.com/joyent/node.git cd node ./configure –prefix=/servers/app/node make && make install 启动 /servers/app/node/bin/node 直接执行./node将进入nodejs的命令 ...

    http://codante.org/nodejs-installation-and-configuration
  2. PHP中用Memcache存储Session数据

    使用memcached的好处不言而喻,它不仅减少了系统访问数据库的压力,而且提高系统的反应速度。特别是做多台服务器集群时,memcached有效的解决了session共享的问题。架构确实变复杂了一些,但应用起来却极为简便,几 ...

    http://codante.org/memcache-php-session-handle
  3. memcached安装及配置

    memcached是一个高性能的、分布式内存对象缓存系统,尽管很通用,但是用来加速WEB应用、降低数据库负载时比较多。memcached可以把数据库的负载降到了几乎没什么事可干的地步,同时为用户提供很快的页面响应速度,更 ...

    http://codante.org/memcached-install-and-configuration
  4. 在apache的log中找出访问次数最多的N个IP。

    根据需求修改文件名和行数即可 awk ‘{print $1}’ 日志文件名 |sort |uniq -c|sort -nr|head -行数 输出: 1234 123.456.789.0 321 11.22.33.44 56 22.33.44.55 34 33.44.55.66 ……

    http://codante.org/apache-log-top-ip-statistics
  5. 根据端口查找进程pid

    netstat -lnp|grep 端口号|grep -v grep|sed -n ’1p’|awk ‘{print $7}’|awk -F/ ‘{print $1}’

    http://codante.org/linux-shell-find-pid-from-port