Uploaded image for project: 'Couchbase Kubernetes'
  1. Couchbase Kubernetes
  2. K8S-2620

[SaveAndRestore] Bucket creation count after restore is not correct.

    XMLWordPrintable

Details

    • Bug
    • Resolution: Not a Bug
    • Major
    • 2.3.0
    • 2.3.0
    • None
    • None
    • 1

    Description

      Steps to reproduce:

      1. Create a 2 node 7.0.3 cluster with the default bucket.
      2. Set the bucket managed to false.
      3. Delete the default bucket.
      4. Load travel-sample bucket.
      5. Save the data topology.
      6. Delete the CB cluster (This deletes the Kubernetes object of the default bucket as well). 

        Prateeks-MacBook-Pro:couchbase-autonomous-operator-kubernetes_2.3.0-macos-x86_64 prateekkumar$ kubectl get couchbasebuckets
        No resources found in default namespace. 

             7. Create a new 2-node 7.0.3 cluster with the default bucket.

             8. Set bucket managed to false and increase the dataMemory Quota to 1024MB.

             9. Restore the saved topology.

      Output of restore with log level set as restore: __ 

       Prateeks-MacBook-Pro:bin prateekkumar$ ./cao restore -f save2.yaml --debug
      Collecting data topology resources...
      Loading current cluster topology...
        /
        └── default (bucket)
            └── _default (scope)
      Loading requested cluster topology...
        /
        └── travel-sample (bucket)
            ├── _default (scope)
            ├── inventory (scope)
            │   ├── airline (collection)
            │   ├── airport (collection)
            │   ├── hotel (collection)
            │   ├── landmark (collection)
            │   └── route (collection)
            ├── tenant_agent_00 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            ├── tenant_agent_01 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            ├── tenant_agent_02 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            ├── tenant_agent_03 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            └── tenant_agent_04 (scope)
                ├── bookings (collection)
                └── users (collection)
      Splicing requested cluster topology...
        /
        └── travel-sample (bucket)
            ├── _default (scope)
            ├── inventory (scope)
            │   ├── airline (collection)
            │   ├── airport (collection)
            │   ├── hotel (collection)
            │   ├── landmark (collection)
            │   └── route (collection)
            ├── tenant_agent_00 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            ├── tenant_agent_01 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            ├── tenant_agent_02 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            ├── tenant_agent_03 (scope)
            │   ├── bookings (collection)
            │   └── users (collection)
            └── tenant_agent_04 (scope)
                ├── bookings (collection)
                └── users (collection)
      Merging cluster topology...
      Data topology solution:
       
       
        /
        ├── default (bucket) retain
        │   └── _default (scope) retain
        └── travel-sample (bucket) create
            ├── _default (scope) create
            ├── inventory (scope) create
            │   ├── airline (collection) create
            │   ├── airport (collection) create
            │   ├── hotel (collection) create
            │   ├── landmark (collection) create
            │   └── route (collection) create
            ├── tenant_agent_00 (scope) create
            │   ├── bookings (collection) create
            │   └── users (collection) create
            ├── tenant_agent_01 (scope) create
            │   ├── bookings (collection) create
            │   └── users (collection) create
            ├── tenant_agent_02 (scope) create
            │   ├── bookings (collection) create
            │   └── users (collection) create
            ├── tenant_agent_03 (scope) create
            │   ├── bookings (collection) create
            │   └── users (collection) create
            └── tenant_agent_04 (scope) create
                ├── bookings (collection) create
                └── users (collection) create
       
       
      WARNING! resources marked as delete may result in data loss.
       
       
      OK to proceed? (y/N) y
      Compacting cluster topology...
      Merging children under node tenant_agent_04
      Merging children under node tenant_agent_03
      Merging children under node tenant_agent_02
      Merging children under node tenant_agent_01
      Merging children under node tenant_agent_00
      Merging children under node inventory
        /
        ├── default (bucket) retain
        └── travel-sample (bucket) create
            ├── inventory (scope) create
            │   └── airline, airport, hotel, landmark, route (collection group)
            ├── tenant_agent_00 (scope) create
            │   └── bookings, users (collection group)
            ├── tenant_agent_01 (scope) create
            │   └── bookings, users (collection group)
            ├── tenant_agent_02 (scope) create
            │   └── bookings, users (collection group)
            ├── tenant_agent_03 (scope) create
            │   └── bookings, users (collection group)
            └── tenant_agent_04 (scope) create
                └── bookings, users (collection group)
      Linking cluster topology...
      Creating new resources and pivoting root...
      couchbasebuckets/bucket-e9968ae4-ce0d-4aca-88a6-44a2a72154c2 created
      couchbasebuckets/bucket-00e2c78f-512c-4b9b-84ca-81600563eea1 created
      couchbasescopes/scope-30d0b751-3294-45e8-9f05-c3e5bc85b393 created
      couchbasescopes/scope-214518e7-3471-45ae-820a-3053fbdd722e created
      couchbasescopes/scope-82d450b2-c720-4dd0-ac8f-724480ae0e32 created
      couchbasescopes/scope-30ea6c55-1175-461c-9fe8-b6ea8e4159b7 created
      couchbasescopes/scope-897bc988-2371-4257-ab04-fdb7fc51839a created
      couchbasescopes/scope-745f8be8-6a10-4789-bb68-700354128511 created
      couchbasecollectiongroups/collectiongroup-5bc0d4f5-0fd8-4432-9073-77107e656d95 created
      couchbasecollectiongroups/collectiongroup-cfc7c6fb-b5bb-452b-9d63-341799d0148c created
      couchbasecollectiongroups/collectiongroup-2c9c85e0-8428-4dda-bc81-e8e794e8cf04 created
      couchbasecollectiongroups/collectiongroup-4f2c5667-1d0e-4b7b-937f-103c7116541b created
      couchbasecollectiongroups/collectiongroup-0680b67f-1daa-4df8-9222-ec9648819309 created
      couchbasecollectiongroups/collectiongroup-8b927db5-ca80-4f06-9fdb-eada1fde87f3 created
      couchbasecluster/cb-example updated
      Cleaning up old resources...

      Output of kubectl get couchbasebuckets: 

      Prateeks-MacBook-Pro:bin prateekkumar$ kubectl get couchbasebuckets
      NAME                                          MEMORY QUOTA   REPLICAS   IO PRIORITY   EVICTION POLICY   CONFLICT RESOLUTION   AGE
      bucket-00e2c78f-512c-4b9b-84ca-81600563eea1   200Mi          1          low           valueOnly         seqno                 54s
      bucket-e9968ae4-ce0d-4aca-88a6-44a2a72154c2   100Mi          1          low           valueOnly         seqno                 55s
      default                                       100Mi          1          low           valueOnly         seqno                 4m33s 

      It shows 3 buckets.

      Moreover, the UI has 2 buckets only. (Screenshot attached)

      Is that expected? 

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            simon.murray Simon Murray
            prateek.kumar Prateek Kumar (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty