What does “too many positional options” mean when doing a mongoexport?

后端 未结 14 1681
暖寄归人
暖寄归人 2020-12-05 09:27

mongoexport -h db.mysite.com -u myUser -p myPass -c myCollection

But the response I get is:

ERROR: too many positional options

14条回答
  •  不知归路
    2020-12-05 10:04

    I had the same issue with starting mongod. I used the following command:

    ./mongod --port 27001 --replSet abc -- dbpath /Users/seanfoley/Downloads/mongodb-osx-x86_64-3.4.3/bin/1 --logpath /Users/seanfoley/Downloads/mongodb-osx-x86_64-3.4.3/log.1 --logappend --oplogSize 5 --smallfiles --fork

    The following error message appeared:

    Error parsing command line: too many positional options have been specified on the command line

    What fixed this issue was removing the single space between the '--' and 'dbpath'

提交回复
热议问题