How to clean up Zitadel after botched import
This issues pretty much explains what I tried to do: https://github.com/zitadel/zitadel/issues/10417
0. I exported data from old Zitadel.
1. I tried importing but because the preferred language contained
en-u-rg-uszzzz
, the import failed
2. After replacing all en-u-rg-uszzzz
with en
, I tried importing again
3. However, various constraint checks failed and so the imported org missed certain settings and thus the user's lacked the domain
4. I removed the imported organization and tried importing once again, but this time there were even more errors and the organization did not appear at all.
Now I am stuck in a situation where I can't see the imported organization in the GUI and no users, but neither can I import it because it exists somewhere internally. I get errors like these:
GitHub
[Bug]: Import saves data even when it fails · Issue #10417 · zita...
Preflight Checklist I could not find a solution in the documentation, the existing issues or discussions I have joined the ZITADEL chat Environment ZITADEL Cloud Version v3.3.2 Database PostgreSQL ...
4 Replies
Hi @wlinna, I'm an AI assistant for ZITADEL. While a team member reviews this question, I'll see if I can find relevant sources for your question.
Answer
I wasn't able to find a direct answer about cleaning up after a botched import, here are some relevant sources:
1. Couldn't import human user that was previously deleted via console : This discussion mentions that import doesn't work for users previously deleted, and suggests the issue is related to ZITADEL checking user IDs even when users don't exist in the console.
2. [Proposal] rework import/export : This issue discusses limitations with the current export/import architecture and suggests workarounds including importing objects without IDs to let ZITADEL generate new ones, or executing against a fresh database.
Feel free to tag @Ask Inkeep with additional questions.
Got it. Tagging @Rajat for additional help.
I suppose it just isn't possibly right now (?)
hey @wlinna thaanks for the question, i will look into it
I have since then learned that many of those errors occur even when importing to a fresh Zitadel instance. Please see my other thread:
https://discord.com/channels/927474939156643850/1413118165151518730