ysrc / xunfeng

巡风是一款适用于企业内网的漏洞快速应急,巡航扫描系统。
GNU General Public License v3.0
3.53k stars 1.34k forks source link

LINUX 安裝後配置頁空白 #236

Open GGOOHAPPY opened 4 years ago

GGOOHAPPY commented 4 years ago

我LINUX 安裝後配置頁空白 , RUN "python vulscan/vulscan.py" 有以下的問題:

'NoneType' object has no attribute 'getitem' Traceback (most recent call last): File "vulscan/vulscan.py", line 355, in PASSWORD_DIC, THREAD_COUNT, TIMEOUT, WHITE_LIST = get_config() TypeError: 'NoneType' object is not iterable

應該是跟舊帖問題一樣, 但未知哪裡有改FULL PATH https://github.com/ysrc/xunfeng/issues/111

ywolf commented 4 years ago

应该是 数据库初始化那个步骤出问题导致

GGOOHAPPY commented 4 years ago

mongorestore -h 127.0.0.1 --port 27017 -d xunfeng . 就來這句嗎? 我已經有打了這句, 有方法CHECK 是什麼問題嗎?

ywolf commented 4 years ago

执行结果是否有异常 可以连接 mongo 看看表结构和基础配置信息是否已经成功导入

GGOOHAPPY commented 4 years ago

是這樣的,

use xunfeng switched to db xunfeng db.stats() { "db" : "xunfeng", "collections" : 1, "objects" : 151, "avgObjSize" : 371.3576158940397, "dataSize" : 56075, "storageSize" : 36864, "numExtents" : 0, "indexes" : 1, "indexSize" : 16384, "ok" : 1 }

ywolf commented 4 years ago

"collections" : 1, 应该是没有导入成功把 重新操作初始化数据库这个流程

GGOOHAPPY commented 4 years ago

cd /root/mongodb-linux-x86_64-3.4.0/bin

pwd

/root/mongodb-linux-x86_64-3.4.0/bin

mongorestore -h 127.0.0.1 --port 27017 -d xunfeng .

2019-10-22T19:37:44.767+0800 the --db and --collection args should only be used when restoring from a BSON file. Other uses are deprecated and will not exist in the future; use --nsInclude instead 2019-10-22T19:37:44.767+0800 building a list of collections to restore from . dir 2019-10-22T19:37:44.768+0800 don't know what to do with file "bsondump", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongo", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongod", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongodump", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongoexport", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongofiles", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongoimport", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongooplog", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongoperf", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongoreplay", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongorestore", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongos", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongostat", skipping... 2019-10-22T19:37:44.768+0800 don't know what to do with file "mongotop", skipping... 2019-10-22T19:37:44.768+0800 done

i tried to do the above , and see again the db.stats() , it still only has one collection . my mongo db version is now 3.4 .

ywolf commented 4 years ago

先cd 到源码的db目录 再执行导入命令

GGOOHAPPY commented 4 years ago

thanks , it works now