MiCyte

← The wiki

98 — Taking your data with you

BuiltRendered from 98-taking-your-data-with-you.md in the public repository. Edits belong there.

This page states how to take a complete copy of an instance's records and files, how to check the copy, how to load it into another store, and how to move a website, domain and mail. The archive is a copy of the records; it is not a way to run an instance. The published package does not include a host that serves an instance to a browser.

The instance archive

One zip file, micyte-instance-<msn>-<YYYYMMDD>.zip. Its format, micyte-instance-archive version 1, is defined, written and read by micyte/adapters/sql/instance_archive.py:

micyte-instance-<msn>-<day>/ README.md what the archive is manifest.json every entry, with its size and SHA-256 documents/<sandbox>/<name>.json one per document, in the store's JSON shape files/<sandbox>/<slot> <title> one per kept file, its exact bytes

  • It contains every document filed under the instance's msn, in every sandbox. A shared sandbox the instance reads but does not own (for example a registrar or a taxonomy kept by its host) is not included.
  • Kept files (a signed PDF, a photograph) are written as files. The manifest carries what a store needs besides the bytes.
  • Documents and the manifest are JSON. Nothing in the archive needs MiCyte to be read.
  • All version hashes use one identity policy (MOS_CANONICAL_HASH); the manifest records which.

Getting the archive

FromHow
An instance FND hostsProfile → Your data → Download your data, signed in with the account's full sign-in (a finance sign-in is refused). Built on request, one at a time, up to 512 MB of content. For a larger instance or a closed account, FND's operator writes the same archive.
A store file you holdpython -m micyte.adapters.sql.instance_archive export --db store.sqlite3 --msn <msn> --out instance.zip. The store is opened read-only.

Checking it

python -m micyte.adapters.sql.instance_archive inspect micyte-instance-<msn>-<day>.zip

inspect checks every entry against the manifest's size and SHA-256, re-hashes every document and compares the result with the version its id names, and rebuilds every file into rows and compares them with the stored document. It prints one line, or a refusal naming the damaged entry.

Loading it into another store

Install the wheel from the latest release of MiCyte/MiCyte (Python 3.13 or later), then:

python -m micyte.adapters.sql.instance_archive import micyte-instance-<msn>-<day>.zip --db copy.sqlite3

  • The store is created if it does not exist.
  • Nothing is written until every entry is checked. A damaged entry, a forged document or a different identity policy is refused and the store is left unchanged.
  • A store that already holds documents of the same instance is refused.
  • After writing, every document is read back and compared; the command exits 1 if any differs.

The result is a store readable through the library, not a running instance.

Your website

A website is not in the archive. If the site is published from a repository you control, that repository is your copy. If the host keeps the site's files, ask the host for a copy of the site as last published.

Moving the domain and mail

These steps happen at your domain registrar and mail provider, not in MiCyte. In this order the site and mail keep working during the move:

  1. Copy the DNS zone. Record every entry (website addresses; for mail MX, SPF, DKIM and DMARC) and create them at the new DNS host.
  2. Unlock the domain at the current registrar and request the transfer authorization code. A registrar may refuse a transfer for a period after registration or a previous transfer.
  3. Start the transfer at the new registrar with the code, and confirm the registrars' emails.
  4. Move mail. Point MX at the new provider once its mailboxes exist, and copy each old mailbox over IMAP while the old provider still serves it.

Status

PieceState
Archive format, export, inspect, importBuilt. micyte/tests/unit/test_an_export_round_trips.py checks an exact round trip, that only the instance's own documents are included, and that nothing is written before everything is checked.
Download for a client of FNDBuilt.
Operator exportBuilt.
Serving an instance yourselfNot built. The published package has no host.