Migrating Your FiveM City to New Hardware Without Data Loss

Migrating Your FiveM City to New Hardware Without Data Loss

Moving a live FiveM server requires careful preparation. Rushing the process can lead to corrupted player data, broken script states, or an offline server with a mismatched IP address. Proper planning ensures your community experiences only a brief maintenance window. Here is the exact method for transitioning a city to new infrastructure.

Pre-Migration Audit

Before making any changes, review your current setup thoroughly. Access txAdmin, open the Live Console, and record your exact FXServer artifacts build number to replicate it on the new machine. Inspect your server.cfg file to note every ensure line and confirm the precise load order. If your community utilizes items from a FiveM script store, document the active versions so you can maintain consistency rather than attempting upgrades during the move.

Securing a Reliable Backup

Perform these steps on your live server during low-traffic periods prior to provisioning the destination machine. Never rely on a backup generated midway through a transfer.

Database Export

Dump your complete oxmysql database using the appropriate command structure:

mysqldump -u DB_USER -p DB_NAME --single-transaction --routines --triggers > fivem_$(date +%Y%m%d).sql

The single-transaction flag is vital for InnoDB tables because it prevents table locks during the dump, allowing your server to remain online. Transfer the resulting file off-box immediately via SFTP or object storage.

Resources and Server Data

Transfer your resources and server-data folders to the new machine using rsync from the source box:

rsync -avz --progress /path/to/resources/ newserver:/path/to/resources/ rsync -avz --progress /path/to/server-data/ newserver:/path/to/server-data/

Run a secondary rsync synchronization right before the final cutover to catch any files modified since the initial transfer.

Configuring the New Host

Install the identical FXServer artifacts build you recorded during your initial audit. Avoid defaulting to the newest build unless your previous environment already used it, as silent compatibility changes can break standalone FiveM resources or complex frameworks like QBCore and ESX.

Performing a Staged Dry Run

Launch the new server independently on a non-standard port while keeping it detached from your public DNS records. Monitor the txAdmin live console closely for errors. Common issues at this stage include incorrect resource startup sequences, missing console variables, or database connection refusals caused by permission errors.

Test a complete boot cycle, join with a test profile, and verify complex systems like housing, inventories, and phones load properly from the database. Testing resource performance using monitoring scripts helps catch regressions before players log in.

Maintenance Window and Player Communication

Select a time when your player concurrency is lowest, such as late night or early morning depending on your region. Provide at least twenty-four hours of notice within your community Discord, followed by a thirty-minute warning. Leverage txAdmin scheduled announcements to broadcast in-game countdowns to ensure everyone stays informed.

DNS and IP Cutover

If players connect via direct IP addresses, announce the replacement address clearly after the move. Communities using domain-based A records should update their DNS settings during the cutover window, reducing Time-To-Live values beforehand for faster propagation.

Your Cfx.re server listing is tied directly to your license key, meaning the public hub listing will automatically reclaim its place once the new machine connects. Manual re-registration is unnecessary.

Establishing a Rollback Plan

Leave the original server instance intact and stopped for at least forty-eight hours following the cutover. Avoid wiping or decommissioning the old host immediately. If unexpected issues emerge on the new hardware, such as kernel-related bugs or database anomalies, you can revert your DNS records instantly and restore service in minutes. Decommission the old machine only after confirming long-term stability under full player loads.

More FiveM script guides

Running Multiple FiveM Servers: Dev, Main and Event Instances Without Doubling Your Workload
Guide
Running Multiple FiveM Servers: Dev, Main and Event Instances Without Doubling Your Workload
Mastering FiveM Weather and Time Sync for City Immersion
Guide
Mastering FiveM Weather and Time Sync for City Immersion
Balancing Your FiveM Economy: Pricing Assets Without Ruining Progression
Guide
Balancing Your FiveM Economy: Pricing Assets Without Ruining Progression
Guide published · Jun 16, 2026 Browse every FiveM article →