`
文章列表

mongodb oplog

mongodb oplog的使用 所在位置: Master/Slave架构: local.oplog.$main Replica sets架构: local.oplog.rs Sharding架构: 每个分片中 db.oplog.rs.findone() mongosync mongooplog 查看某个mongod上oplog的详细情况: rs.printReplicationInfo()
mongodb 原有数据库版本:2.2.2 更新到数据库版本: 2.6.6 原有添加帐号的函数: db.addUser("1", "1"). 失效 提示需要调用函数: db.createUser({ "user": "1", "pwd": "1", "roles": [{ "role": "readWrite", "db": "identidy_info" }]}) 但是 ...
http://www.ibm.com/developerworks/linux/library/l-memory/ http://stackoverflow.com/questions/1119134/how-do-malloc-and-free-work http://stackoverflow.com/questions/3358045/how-are-malloc-and-free-implemented

绘图软件

Sketch PS AI
[code = "python"] # coding:utf-8 import cookielib import mechanize import urllib br = mechanize.Browser() cj = cookielib.LWPCookieJar() br.set_cookiejar(cj) br.open('****')#需要打开的网址 br.select_form(nr=0)#需要查看源代码中输入框是第几个 br.form['id_input_username'] = '**'#需要到源码中查找对应的输入框名字 br.form['password'] ...

实用工具-windows

RAMMap.exe vmmap.exe 内存查看工具 花下眠工作室: http://huaxiamian.cc

查询 10055错误

https://wiki.pscs.co.uk/how_to:10055?s[]=10055 netstat -nat | find /c "LISTEN" 修改注册表中tcp_ip的time_wait时间,默认时间为4分钟 HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters TcpTimedWaitDelay

curl

-H: 添加消息头, 如 -H "Host: www.baidu.com" -o: 输出结果到文件中: 如: -o test.txt -v: 显示返回的结果到终端、 -T: 上传文件 上传文件到ftps服务器上去 curl -u user:password -T *** "ftps://user@host:port/logs/nginx_183/" -k
mongodb c++ driver 2.6之后的版本不能从mongdb的源码中编译,已经分离到独立的地方: https://github.com/mongodb/mongo-cxx-driver/wiki 编译64位的: 1. 打开vs 64位工具 2. scons --use-system-boost --prefix=F:\kevin\Downloads\mongodb_new\mongo-cxx-driver-legacy-0.0-26compat-2.6.6\install\ --release --64=FORCE64 --libpath=F:\CardMatch_Mongo_2 ...
http://goaccess.io/
ls /data/logs/access_2014121[5,9].bz2 | xargs -i tar -xjvf {} 压缩文件: ls -hl access_201503* | xargs -i tar -zcvf {}.tar.gz {} 江浙沪园艺

awk

http://coolshell.cn/articles/9070.html [0;31;40m5 ^[[0;31;40m5.925^[[0m awk 'substr($4, 11, 10) > 5'  **** ls /data/nginx/logs/access_2014123*.bz2 | xargs -i tar -xjvf {} grep "task_id=corp_466765_113506124" access_2014121[5,6].log > 20141215_vcf5.txt awk '{print $10}' 20141215_ ...
egrep "0;31;40m.*[5-9]\."

c++ 读取unicode文档

    博客分类:
  • c++
int ReadOneNameFile(char *filename, unsigned short names[g_maxLineNum][g_maxCharInLine], int &iLine) { printf("%s\n", filename); ifstream fin; fin.open(filename, ios::binary); size_t index = 2; int nameIndex = 0; //while (!fin.eof()) //注意这行如果是这行代码,最后读取出来的数据最后一个字符会多一个 ...

linux 命令

① 查看物理CPU的个数 #cat /proc/cpuinfo |grep "physical id"|sort |uniq|wc -l  2  ② 查看逻辑CPU的个数 #cat /proc/cpuinfo |grep "processor"|wc -l  24  ③ 查看CPU是几核 #cat /proc/cpuinfo |grep "cores"|uniq  6   free 查看内存信息: nohup 让命令不挂断执行命令 nohup command & history history -c: 清 ...
Global site tag (gtag.js) - Google Analytics