ITPub博客

首页 > 数据库 > NoSQL > MongoDB报错:"assertion" : "can't map file memory"

MongoDB报错:"assertion" : "can't map file memory"

原创 NoSQL 作者:mchdba 时间:2014-03-03 12:29:16 0 删除 编辑

PRIMARY> use identify;
switched to db identify
PRIMARY> db.dropDatabase();
{
        "assertion" : "Can't take a write lock while out of disk space",
        "assertionCode" : 14031,
        "errmsg" : "db assertion failure",
        "ok" : 0
}
PRIMARY>

-- 磁盘满了
-- 清空磁盘之后,空余2G空间之后,重启mongodb,结果报错如下:
PRIMARY> show dbs';
Thu Mar 21 23:32:34 uncaught exception: don't know how to show [dbs']
PRIMARY> show dbs;
Thu Mar 21 23:32:37 uncaught exception: listDatabases failed:{
        "assertion" : "can't map file memory",
        "assertionCode" : 10085,
        "errmsg" : "db assertion failure",
        "ok" : 0
}
PRIMARY> 

网上找来很多资料,都搞不定,先记下来吧,空了继续去研究。

继续研究,网上很多资料,都说是磁盘空间不足,所以准备把刚导入的3G的collection删除掉,现在在mongo操作界面执行不了,直接进到linux目录删除文件试试看

1 service mongo stop

2 rm -rf identifed.*  --磁盘剩余为6G。

3 service mongo start

4 mongo admin 登陆

5 show dbs;

PRIMARY> show dbs;
admin   0.203125GB
apollo  0.203125GB
apollodev       0.203125GB

 

ok,可以了。

 

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/26230597/viewspace-1098509/,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
Happy is the man who is living by his hobby.

注册时间:2011-09-05

  • 博文量
    147
  • 访问量
    3755831