You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I set the tenant to have the drop_after option, then dropped the tenant, after that,i shut down CNOSDB and restarted it, but I cannot recover the tenant and it says tenant not found. However, when I create the tenant, it says tenant already exists.
To Reproduce
start CNOSDB ./target/debug/cnosdb run -M singleton --config ./config/config_8902.toml
in client:
public ❯ create tenant aaa with drop_after='1d';
Query took 0.016 seconds.
public ❯ drop tenant aaa;
+--------------------------------------------------------------------------------+
| tips |
+--------------------------------------------------------------------------------+
| This tenant will drop after 86400s |
| If you want to delete this tenant immediately, you need to do something extra: |
| 1)recover tenant "aaa"; |
| 2)alter tenant "aaa" unset drop_after; |
| 3)drop tenant "aaa"; |
+--------------------------------------------------------------------------------+
Query took 0.015 seconds.
shutdown CNOSDB
restart CNOSDB
in client:
public ❯ SELECT * FROM cluster_schema.tenants;
+-------------+----------------------------------------------------------------------------------------------+
| tenant_name | tenant_options |
+-------------+----------------------------------------------------------------------------------------------+
| cnosdb | {"comment":"system tenant","limiter_config":null,"drop_after":null,"tenant_is_hidden":false} |
+-------------+----------------------------------------------------------------------------------------------+
Query took 0.014 seconds.
public ❯ create tenant aaa with drop_after='1d';
422 Unprocessable Entity, details: {"error_code":"030009","error_message":"The tenant aaa already exists"}
public ❯ recover tenant aaa;
422 Unprocessable Entity, details: {"error_code":"030010","error_message":"The tenant aaa not found"}
public ❯
Expected behavior
I need to recover tenant after I restart CNOSDB,otherwise I can‘t drop that tenant immediately
Additional context
No response
The text was updated successfully, but these errors were encountered:
paradox0503
changed the title
After shutting down cnosdb, tenant cannot be restored after restarting
After shutting down cnosdb, tenant cannot be recovered after restarting
Nov 25, 2024
Describe the bug
I set the tenant to have the drop_after option, then dropped the tenant, after that,i shut down CNOSDB and restarted it, but I cannot recover the tenant and it says tenant not found. However, when I create the tenant, it says tenant already exists.

To Reproduce
start CNOSDB
./target/debug/cnosdb run -M singleton --config ./config/config_8902.toml
in client:
shutdown CNOSDB
restart CNOSDB
in client:
Expected behavior
I need to recover tenant after I restart CNOSDB,otherwise I can‘t drop that tenant immediately
Additional context
No response
The text was updated successfully, but these errors were encountered: