Browse docs
Database, Backup, and Restore
Crime System stores configuration, ownership, progress, running operations and audit history across several table groups. A copy of the resource folder is therefore not a complete backup.
What creates the schema
| Owner | Shipped behavior | Important scope |
|---|---|---|
Config.AutoExecuteQuery | Enabled | Main Crime tables and migrations |
Config.HeistPersistence.enabled | Enabled with its own persistence | Heist definitions and player plans |
Config.HeistPersistence.autoMigrate | Enabled | sky_crime_heist_definitions, sky_crime_heist_plans, and planning locations |
Config.PvPEvents.autoMigrate | Enabled | PvP event and template state |
import.sql | Manual alternative for most main tables | Does not replace the separate heist-table migration |
Persistence groups
Territory configuration, Drug Creator entries and items, heist definitions, laboratory sites and other reusable definitions describe what can exist.
Laboratories, campers, business state, workers, equipment, treasury, inventory, access and organization facilities describe who owns and operates a system.
Plants, batches, reputation, contacts, heat, market state, routes, territory influence and PvP registration survive normal reconnects according to their lifecycle.
Heist plans, work orders, darknet orders, drug threats and raids may contain time-sensitive state. Restore them only together with the definitions and ownership rows they reference.
Ledgers, sales, market actions, reports and optional interrogation logs explain past mutations. Keep them when you need traceability.
Safe update workflow
Stop new gameplay
Use a maintenance window and prevent players from starting heists, trades, work orders or raids during the backup.
Back up database and files
Capture the Crime tables plus the installed config folder, heist JSON files and intentional exports.
Apply the update
Keep automatic migrations enabled unless you deliberately maintain every schema yourself. Follow the current changelog's changed-file instructions.
Verify startup
Read the first migration or startup error. Do not continue testing when one table group failed.
Verify saved state
Check one organization, heist plan, Creator entry, owned facility and player progression record.
Run fresh gameplay
Create a new activity and complete it as a regular player before reopening the server.
Import and restore are different
| Action | Intended use | Important effect |
|---|---|---|
/jobconfigimport sky_crimesystem | Apply loaded Lua values to supported saved configuration | Can change organizations and membership model; does not import Drug Creator or heist definitions |
| Restore shipped defaults | Rebuild registered organization setup and settings | Clears configuration history and can remove organizations not present in registered defaults |
| Database restore | Recover a known consistent server state | Must match the related resource files and schema version |
See Configuration and Changelog.