big bug ban

兴趣 创新 践行

Archive for 十一月, 2011

关于一致性哈希

 

1. 一致性哈希

2.1 基本场景

比如你有 N 个 cache 服务器(后面简称 cache ),那么如何将一个对象 object 映射到 N 个 cache 上呢,你很可能会采用类似下面的通用方法计算 object 的 hash 值,然后均匀的映射到到 N 个 cache ;

hash(o[......]

继续阅读

Written by princehaku

十一月 15th, 2011 at 9:12 下午

210 views

Posted in technology

Tagged with

with 2 comments

phpcurl模块

 

1  概述

PHP支持的由Daniel Stenberg创建的libcurl库允许你与各种的服务器使用各种类型的协议进行连接和通讯。

目前支持http、https、ftp、gopher、telnet、dict、file和ldap协议。libcurl同时也支持HTTPS认证、HTTP PO[......]

继续阅读

Written by princehaku

十一月 15th, 2011 at 7:48 下午

167 views

Posted in php

with 3 comments

apache日志分离组件cronolog

 

1.1   概述

apache默认的日志都会记录到一个文件内

如果访问量过多,时间过长,将导致日志堆积,文件变大,影响apache的性能

cronolog是一个用于日志切分的软件,使用管道把输入定位到其他路径保存

1.2   安装

wget http://cronolo[......]

继续阅读

Written by princehaku

十一月 15th, 2011 at 7:36 下午

257 views

Posted in webbuild

Tagged with ,

without comments