摘要: Linux上的free命令详解 阅读全文
posted @ 2010-02-20 21:26 coldplayerest 阅读(188197) 评论(21) 推荐(40) 编辑
摘要: 1. 计算网络的QPS时,必须要指定并发度,否则没有意义。2. 等式关系:QPS = 并发度 / 用户平均等待时间QPS = 1 / 服务器平均请求处理时间用户平均等待时间 / 并发度 = 服务器平均请求处理时间3. QPS是指在一定并发度下,服务器每秒可以处理多少请求。这是从服务器的角度来说的,而不是从每个用户的角度再乘以并发度来说的。4. Apache AB的两个翻译:Time per Request:用户平均等待时间Time per Request (across all concurrent request): 服务器平均请求处理时间 阅读全文
posted @ 2012-06-28 15:13 coldplayerest 阅读(3748) 评论(0) 推荐(0) 编辑
摘要: http://www.x-berry.com/vpn-tunneling-protocol 阅读全文
posted @ 2012-06-17 11:08 coldplayerest 阅读(280) 评论(0) 推荐(0) 编辑
摘要: http://www.quora.com/Boosting-documents-in-solr-on-field-value 阅读全文
posted @ 2012-06-15 10:50 coldplayerest 阅读(1382) 评论(0) 推荐(0) 编辑
摘要: 转载一篇讲tty/pty/console的文章http://blog.chinaunix.net/uid-7828352-id-3233064.html 阅读全文
posted @ 2012-06-12 16:19 coldplayerest 阅读(340) 评论(0) 推荐(0) 编辑
摘要: 先mark一下,有时间再看。http://www.ruanyifeng.com/blog/2011/12/inode.htmlhttp://teaching.idallen.com/dat2330/04f/notes/links_and_inodes.htmlhttp://www.thegeekstuff.com/2012/01/linux-inodes/http://blog.chinaunix.net/uid/7828352/frmd/-1.htmlhttp://blog.chinaunix.net/uid-7828352-id-3233062.htmlhttp://blog.chinau 阅读全文
posted @ 2012-06-12 16:18 coldplayerest 阅读(659) 评论(0) 推荐(0) 编辑
摘要: 1. 对一列数据求和awk 'BEGIN {sum=0} {sum+=$1} END {print sum}' data.txt2. 对一列数据求和、求平均值awk -F ',' 'BEGIN {sum=0 ;count=0} {sum +=$5; count++;} END {print "sum="sum" count="count " avg="sum/count}'3. 成批rename文件find * -type f | awk '{print "mv &qu 阅读全文
posted @ 2012-06-12 14:43 coldplayerest 阅读(563) 评论(0) 推荐(0) 编辑
摘要: Stop your application serverChange your schema.xml fileStart your application serverDelete the index directory in your data directory (or alternately delete all documents using <delete><query>*:*</query></delete> before shutting down Solr)Send an <optimize/> commandRe-I 阅读全文
posted @ 2012-06-03 13:45 coldplayerest 阅读(3860) 评论(0) 推荐(0) 编辑
摘要: solr计算一个query的score分为两个部分:Lucene的算分模型Boost其中Lucene的算分模型包括:1. tf - Term Frequency. The frequency with which a term appears in a document. Given a search query, the higher the term frequency, the higher the document score.2. idf - Inverse Document Frequency. The rarer a term is across all documents in 阅读全文
posted @ 2012-06-03 11:52 coldplayerest 阅读(4728) 评论(0) 推荐(0) 编辑
摘要: fl: 是逗号分隔的列表,用来指定文档结果中应返回的 Field 集。默认为 “*”,指所有的字段。defType: 指定query parser,常用defType=lucene, defType=dismax, defType=edismaxq: query。q.alt: 当q字段为空时,用于设置缺省的query,通常设置q.alt为*:*。qf: query fields,指定solr从哪些field中搜索。pf: 用于指定一组field,当query完全匹配pf指定的某一个field时,来进行boost。简言之pf的作用是boosting phrases over words。fq: 阅读全文
posted @ 2012-05-20 17:33 coldplayerest 阅读(28382) 评论(0) 推荐(0) 编辑
摘要: 所谓RAII,即 Resource Acquizition Is Initialization。很晦涩吧?其实具体实现很简单:把资源封装成一个类,在其构造函数中分配,在析构函数中释放。当需要使用的时候,在栈上初 始化一个对象,当这个对象生命周期结束的时候,其析构函数会被调用,自动完成资源的释放。原文:http://felix021.com/blog/ 阅读全文
posted @ 2012-03-24 21:56 coldplayerest 阅读(464) 评论(0) 推荐(0) 编辑