摘要: 一、开启权限认证1.windows下的mongodb开启权限认证C:\Users\Administrator>sc delete MongoDB //原来创建的服务如果没有开启 则删除[SC] DeleteService 成功C:\Users\Administrator>mongod --dbpat... 阅读全文
posted @ 2015-09-17 12:43 扬空 阅读(811) 评论(0) 推荐(0) 编辑
摘要: 1.借助工具 mongostat 分析mongodb运行状况C:\Users\Administrator>mongostat --help //查看帮助View live MongoDB performance statistics.usage: mongostat [options] [sleep... 阅读全文
posted @ 2015-09-16 14:26 扬空 阅读(381) 评论(0) 推荐(0) 编辑
摘要: 插入准备数据> for(var i=1;i db.user2_collection.find(){ "_id" : ObjectId("55f69331cc1593a1bb113958"), "name" : 1 }{ "_id" : ObjectId("55f69331cc1593a1bb1139... 阅读全文
posted @ 2015-09-16 13:58 扬空 阅读(381) 评论(0) 推荐(0) 编辑
摘要: 一、登录mongo ip:port/dbname默认进入test库二、退出exit三、库操作1.显示全部库show dbs2.创建或进入一个库use 库名3.清空一个库use 要清空的库db.dropDatabase()这个命令其实就是删除了库中的所有集合 如何彻底删除一个库,我也不知道。四、集合操... 阅读全文
posted @ 2015-09-14 17:13 扬空 阅读(148) 评论(0) 推荐(0) 编辑
摘要: window下安装:1.下载安装程序mongodb官网下载:https://www.mongodb.org/downloads百度网盘下载:http://pan.baidu.com/s/1pJOPSoz2.双击后自定义(custom)安装到E:/MongoDB3.设置环境变量4.把mongodb安装... 阅读全文
posted @ 2015-09-14 15:27 扬空 阅读(168) 评论(0) 推荐(0) 编辑
摘要: connect('127.0.0.1',6379); $redis->flushall(); $redis->rpush('mylist','1'); //先进先出 $redis->rpush('mylist','2'); $redis->lpush('mylist','3'... 阅读全文
posted @ 2015-09-02 14:56 扬空 阅读(189) 评论(0) 推荐(0) 编辑
摘要: $length || ($i+1) == $str_length) { $results[] = $tmp_str; $tmp_str = ''; $tmp_str_length = 0; } } ret... 阅读全文
posted @ 2015-08-15 10:25 扬空 阅读(456) 评论(0) 推荐(0) 编辑
摘要: url = $url; } public function get_info() { return array('url'=>$this->url,'input'=>$this->input,'curl_error'=>$this->curl_error,'curl_info'=>$this->c... 阅读全文
posted @ 2015-08-01 09:34 扬空 阅读(581) 评论(0) 推荐(0) 编辑
摘要: 一、可能用到的命令查看是否安装了 ftp软件#which vsftpd查看ftp是否在运行#service vsftpd status查看ftp服务有没有启动#netstat -an | grep 21启动ftp#service vsftpd start二、安装ftp安装ftpyum install... 阅读全文
posted @ 2015-08-01 09:31 扬空 阅读(170) 评论(0) 推荐(0) 编辑
摘要: key = $key; $this->iv = mcrypt_create_iv(mcrypt_get_iv_size($this->cipher,$this->modes),MCRYPT_RAND); } /** * 加密 */ public function encrypt($input)... 阅读全文
posted @ 2015-07-30 20:03 扬空 阅读(245) 评论(0) 推荐(0) 编辑