Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-66651

Role "restore" not sufficient for `mongorestore --preserveUUID`

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 6.0.1, 4.4.16, 5.0.11, 6.1.0-rc0
    • Affects Version/s: 4.4.14
    • Component/s: None
    • Major Change
    • ALL
    • v6.0, v5.0, v4.4
    • Security 2022-07-11

      I create a user with role "restore" in database "admin". This user is able to successfully restore a dumped database (mongodump => mongorestore).

       

      However, with `mongorestore --drop --preserveUUID` it fails with error

       

      Failed: <collection-name>: error creating collection <collection-name>: applyOps: (Unauthorized) not authorized on admin to execute command { applyOps:...
      

      I'm not sure if this is a missing piece in documentation (https://www.mongodb.com/docs/manual/reference/built-in-roles/#mongodb-authrole-restore, https://www.mongodb.com/docs/database-tools/mongorestore) or problem with MongoDB server (using 4.4.14).

       

            Assignee:
            sara.golemon@mongodb.com Sara Golemon
            Reporter:
            ujr@insynergie.de Ulf Rößler
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: