Uploaded image for project: 'Percona Server for MongoDB'
  1. Percona Server for MongoDB
  2. PSMDB-273

temp external sort files and rollback files are not encrypted when using data at rest encryption

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Pending Release
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0.5-2, 3.6.10-3.0
    • Component/s: None
    • Labels:
      None

      Description

      I have a big encrypted database and did initial sync on one of the instances and it created "_tmp" subdirectory inside db with "extsort.*" files inside with data which is not encrypted (and data at rest is enabled on this instance).

      Looks like this in directory:

      root@qaserver-03:~/percona-server-mongodb-4.0.4-1/nodes/node3/db/_tmp# ls -alh
      total 1.6G
      drwx------ 2 root             root    4.0K Dec 17 09:14 .
      drwxr-xr-x 6 tomislav.plavcic percona 4.0K Dec 17 09:16 ..
      -rw------- 1 root             root    181M Dec 17 08:27 extsort.0
      -rw------- 1 root             root    180M Dec 17 08:33 extsort.1
      -rw------- 1 root             root    180M Dec 17 08:39 extsort.2
      -rw------- 1 root             root    180M Dec 17 08:46 extsort.3
      -rw------- 1 root             root    180M Dec 17 08:52 extsort.4
      -rw------- 1 root             root    180M Dec 17 08:57 extsort.5
      -rw------- 1 root             root    180M Dec 17 09:03 extsort.6
      -rw------- 1 root             root    180M Dec 17 09:08 extsort.7
      -rw------- 1 root             root    180M Dec 17 09:14 extsort.8
      

      And file content (notice the "user" string in first line) for file "extsort.0":

      |00007ea0 00 00 00 02 00 18 00 00-00 75 73 65 72 31 30 30 |   ? ?   user100|
      |00007eb0 31 34 32 33 33 37 35 39-35 39 35 36 31 39 35 35 |1423375959561955|
      |00007ec0 00 00 61 98 07 00 00 00-00 00 e4 80 ff ff ab 80 |  a??     ??????|
      |00007ed0 04 a8 23 00 00 00 02 00-18 00 00 00 75 73 65 72 |??#   ? ?   user|
      |00007ee0 31 30 30 31 34 32 33 37-36 39 37 37 30 33 33 34 |1001423769770334|
      |00007ef0 30 39 38 00 00 60 08 6e-00 00 00 00 00 4e 2b 00 |098  `?n     N+ |
      |00007f00 44 34 31 31 34 39 35 39-37 39 33 31 34 39 00 00 |D4114959793149  |
      |00007f10 54 ef 85 01 2a 00 00 52-2b 00 24 32 34 30 38 30 |T???*  R+ $24080|
      |00007f20 39 35 34 35 37 01 2b 08-70 d5 4d 05 2b 00 22 05 |95457?+?p?M?+ "?|
      |00007f30 81 00 17 32 81 00 40 35-33 30 35 39 37 35 39 35 |? ?2? @530597595|
      |00007f40 39 31 33 00 00 27 d5 0b-05 2a 4e 55 00 44 35 33 |913  '???*NU D53|
      |00007f50 37 33 36 32 30 35 34 39-30 38 36 00 00 02 12 68 |73620549086  ??h|
      |00007f60 62 2b 00 44 36 34 32 39-32 30 33 31 31 32 39 31 |b+ D642920311291|
      |00007f70 35 00 00 83 fe 6f 66 2b-00 40 38 30 39 33 31 36 |5  ??of+ @809316|
      |00007f80 34 35 33 30 39 39 00 00-fd 13 5c 62 2b 00 44 38 |453099  ??\b+ D8|
      

      I believe this is related to this functionality here: https://docs.mongodb.com/manual/reference/method/db.collection.aggregate/#perform-large-sort-operation-with-external-sort
      and so it could be replicated in more than one way.

        Smart Checklist

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  igor.solodovnikov Igor Solodovnikov
                  Reporter:
                  tomislav.plavcic@percona.com Tomislav Plavcic
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Time Tracking

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - Not Specified
                    Not Specified
                    Logged:
                    Time Spent - 1 week, 3 days, 2 hours, 30 minutes
                    1w 3d 2h 30m