data
Migrate the payload — the application data that no package owns and translation therefore cannot carry: uploads, document roots, /opt application trees, database files. Package translation reproduces the operating system; data handles what the workload exists to serve. It runs entirely locally, calls no API, and never moves a byte itself — it emits runbooks the operator runs.
Two phases:
# 1. discover — what non-distro data is on the source, and how to move it
vrtmv data discover --image centos7.vmdk
vrtmv data discover --root /mnt/vm --json
# 2. plan — emit runbooks for the paths you choose
vrtmv data plan --root /mnt/vm \
--copy /srv/www --copy /var/lib/mysql -o vrtmv-data-out
discover
Walks the source’s data roots (/var, /opt, /srv, /home, /usr/local, …; never /etc — that’s drift’s job), asks the packaging backend “does any package own this?” for every file, and groups everything unowned into candidate locations. Volatile and cache trees (/var/cache, /var/log, /tmp, the package DBs themselves) are pruned; symlinks are never followed.
Each location is classified and given a recommendation:
| Recommendation | Meaning |
|---|---|
| byte-copy | Plain data — safe to copy byte-for-byte, and attestable. |
db-export (engine) | A database data directory — its on-disk files must not be raw-copied across versions or engines. Routed to a logical export/import instead. |
LOCATION SIZE FILES RECOMMENDED
/var/lib/mysql 8.0 KiB 1 db-export (mysql)
/home/appuser/uploads 4.0 KiB 1 byte-copy
/srv/www/site 14 B 1 byte-copy
plan
Takes the paths you select with --copy (repeatable) and writes four artifacts to -o <out>:
| Artifact | What it is |
|---|---|
vrtmv-data-copy.sh | The byte-copy runbook — rsync -aHAX --numeric-ids per data path. |
vrtmv-data-manifest.sha256 | Per-file sha256 of the source, sha256sum -c-compatible — the byte-parity attestation. |
vrtmv-db-runbook.md | Step-by-step export/import commands for each detected database, with vendor references. |
vrtmv-data-attestation.json | The machine-readable attestation record (paths, hashes, verify verdicts). |
A path that matches a database signature is always routed to the DB runbook, never to a raw copy — even if you pass it to --copy.
Attestation
The manifest proves the copy is byte-identical. After copying, on the target:
sha256sum -c vrtmv-data-manifest.sha256 # every line must say OK
Optionally, point the tool at a destination tree and it re-hashes it for you, marking each file match / differ / missing in the attestation JSON (it still never performs the copy or the dump):
vrtmv data plan --root /mnt/vm --copy /srv/www --verify-dest /mnt/target/srv/www -o out
Databases
Detected by their vendor-documented on-disk data directory (and, for relocated dirs, a distinctive marker file). The runbook emits the supported dump/restore for each:
| Engine | Export → Import |
|---|---|
| PostgreSQL | pg_dumpall → psql |
| MySQL / MariaDB | mysqldump --all-databases → mysql |
| MongoDB | mongodump → mongorestore |
| Redis | redis-cli SAVE + copy dump.rdb |
| Elasticsearch | snapshot → restore |
| InfluxDB | influx backup → influx restore |
| Cassandra | nodetool snapshot → sstableloader |
| etcd | etcdctl snapshot save → restore |
Every command is a real vendor-documented procedure, cited in the emitted runbook — Vrtmv surfaces the steps; the operator runs them.
| Flag | Purpose |
|---|---|
--root / --image / --ssh | The source (see Sources). |
--copy <path> | A guest path to include (repeatable). |
--verify-dest <dir> | Re-hash this destination tree to attest byte-parity locally. |
-o, --out <dir> | Output directory for the runbooks + manifest. |
--json | Also print the attestation JSON to stdout. |