Table of Contents
- Watch the Migration Video
- Before You Begin
- What Actually Transfers
- Exporting the Old Database
- The Two Migration Methods
- After the Success Message
- Bringing Main and Load Balancers Online
- Fixing VODs That Do Not Play
- Moving an Existing Xtream-Masters Panel
- Cutting Over Without Downtime
- Paths and Commands Reference
- Troubleshooting
- FAQ
Watch the Migration Video
The short version first: the Migrate Database button, the two options behind it, and the password reset that finishes the job.
How to Migrate Your IPTV Panel Database to a New Server, XUI, XtreamUI and Xtream Codes
- The Migrate Database button in the Master CMS Panel and the two options behind it
- Remote connection versus placing a
backup.sqlfile on the server - Finishing the job with MasterAdmin, Reset Admin Password, then bringing servers online
Before You Begin
A migration needs somewhere to migrate to. The destination panel must already be installed and reachable on the new server, because the Migrate Database button lives on that server's page in the CMS and does not exist until the install is finished.
Prerequisite: the new server must already be installed
If you have not built the destination server yet, do that first. The official tip is to reinstall the server on Ubuntu 24.04 before you start, and the install itself takes about two minutes. There is a separate video walkthrough covering server requirements, the SSH-based install and port setup.
Read the Ubuntu install guideBeyond that, have these ready before you start:
- Your old panel's database credentials, meaning host, port, database name, username and password.
- The source panel type, whether XUI, XtreamUI, NXT, Xtream Codes or Streamcreed. The schema mapping differs per panel, so this is not a cosmetic dropdown.
- SSH access to the old server, if you are exporting a dump rather than connecting remotely.
- SSH or SFTP access to the new server, so you can place the backup file in
/root.
What Actually Transfers
Everything that matters, and nothing that does not.
| Transfers automatically | Does not transfer |
|---|---|
|
Users and lines Bouquets and categories Live streams Movies and series records Resellers Panel settings |
On-disk VOD files, see the VOD section Logos, EPG files and custom branding assets The admin password, which must be reset |
Supported source panels are XtreamUI, XUI (XUI.ONE), NXT, Streamcreed and other panels in the Xtream Codes family. The migration tool is built into the panel itself, so there are no external scripts, no paid consultants and no hand-edited SQL. If you are coming from a panel outside that family, such as 1-Stream, the schema has to be converted first, which is what the 1-Stream database conversion service handles.
Exporting the Old Database
Skip this section if your old server's database is directly reachable from the new server, because the remote connection method reads it in place and no dump file is created.
Otherwise, SSH into your old server and export:
Standard exportOn XtreamUI, XUI.ONE and Xtream Codes family panels the database is commonly named xtream_iptvpro with the user user_iptvpro, though this varies by installer and version. If yours differs, the credentials live in the old panel's own config file inside its installation directory, so read them there rather than guessing.
For a large database with tens of thousands of lines or long EPG history, use flags that keep the dump consistent without locking your live panel while it runs:
Large database, consistent and non-blockingA compressed .sql.gz file is accepted by the migration, so there is no need to decompress it on the destination.
ls -lh backup.sql and tail -n 5 backup.sql. A valid dump ends with a "Dump completed" comment line. A truncated dump, typically from a disk that filled mid-export, which is common on a panel server with months of logs, will import without complaint and silently lose everything after the cut-off point. You will discover this later by user count, which is the worst possible time.
The Two Migration Methods
In the Master CMS Panel, open your new server and click Migrate Database. Two options are offered. They produce an identical result, so choose on network access rather than preference.
A Remote Connection
No export and no upload, since the system reads your old database directly.
- Enter your old database details: host, port, name, user, password.
- Pick your source panel.
- Click Migrate.
Your old panel keeps serving subscribers throughout, because reading the database does not interrupt streaming.
B Database Backup File Recommended
- Export the database on the old server:
mysqldump -u USER -p DB_NAME > backup.sql
- Put the file on the new server at:
/root/backup.sqlA compressed
/root/backup.sql.gzworks too. Upload it with SCP or SFTP:scp backup.sql root@YOUR_SERVER_IP:/root/backup.sql - Pick your source panel, then click Migrate.
/root on the destination server. If you have seen older instructions involving a web path and a streaming-port URL, they do not apply to the current flow. One file, one location, one click.
rm /root/backup.sql. That file contains every subscriber credential you own, and there is no reason to leave a plain-text copy sitting on a production server.
After the Success Message
The migration is not finished when the progress bar is. Three short steps complete it.
1 Reset the admin password
Click MasterAdmin, then Reset Admin Password, and set a new one. The admin account has to be reset explicitly, which is precisely why you cannot log in yet. This is expected, not a fault.
2 Set a custom panel port, if you want one
Optional. In the Master CMS dashboard you can set a custom panel port with the Edit Port button. Otherwise the admin panel answers on the default, port 7709.
3 Log in with your admin ID
Open the panel on your port and log in with the password you just set.
Bringing Main and Load Balancers Online
With the data in place, start the streaming infrastructure.
Main server
- Open Manage Server and edit the main server.
- Set the SSH password.
- Click Main Server Option, then Restart Service.
Load balancers
- Edit each balancer and set its SSH password.
- Click LB Server Option, then Re-install Balancer.
Allow up to two minutes per balancer, then refresh to confirm status. If you are adding balancers for the first time, the load balancer setup guide covers traffic distribution and sizing.
/home/ on the balancer, then reboot the server. If it stays down, run bash /home/xtreamaster/start_services.sh and bash /home/xtreamaster/start_services_debug.sh and read the error, which usually names the problem directly.
If the main server or a balancer service is down after the migration, open the settings page and click the Update Tables button, then bring the servers online again using the steps above.
Fixing VODs That Do Not Play
This is the one thing the database migration cannot do for you, and the single biggest source of post-migration confusion. Your movie and episode records migrate. The files do not, because each panel stores them in a different folder.
Bring your load balancers online first and wait until they show online, then do the file work.
Method 1: Move the VOD folder (quick and recommended)
Use this if your old panel had VOD files stored locally on the server. That includes directly uploaded files, symlinked movies and episodes, and URL-downloaded content, meaning VODs you added by URL that the panel then downloaded and stored locally. Simply moving the files to the correct path makes everything work instantly.
All movies and episodes live in a single folder. Here is where each panel keeps them:
| Panel | VOD path (movies and episodes) |
|---|---|
| Xtream UI | /home/xtreamcodes/iptv_xtream_codes/movies/ |
| XUI | /home/xui/content/vod/ |
| NXT | /home/nxt/content/vod/ |
| Xtream-Masters | /home/xtreamaster/movies/ (destination) |
Run these steps on every server where VOD files exist, which means the main server and each load balancer that stores VODs:
- SSH into the server.
- Check whether the old folder exists and has files:
ls -la /home/xtreamcodes/iptv_xtream_codes/movies/
- Move the files, using the path that matches your old panel:
mv /home/{old_panel_path}/vod_folder/* /home/xtreamaster/movies/
- Set correct permissions:
chown -R xtreamaster:xtreamaster /home/xtreamaster/movies/
- Repeat on the next server until all are done.
- Test playback from the Movies or Series page in the admin panel.
No re-encoding is needed. Ownership is not optional either: files left owned by root or xtreamcodes will sit on disk, show correctly in the panel, and still refuse to play.
Method 2: Re-encode all VODs
Use this only if you imported VODs directly using server file paths and every original source URL is still valid and accessible. Test a few source URLs manually first. If any are offline or changed, use Method 1 instead.
- Go to Mass Tools, then Advanced Tools.
- Click Proceed Mass Encoding.
- Wait for it to finish, which can take hours for a large library, and review any failed encodings in the log.
Moving an Existing Xtream-Masters Panel
Everything above covers migrating into the panel from a different system. If you are already running Xtream-Masters and simply want to move to new hardware, or re-install the main server, that is a restore rather than a migration, and it uses the panel's own backup system.
- Back up your data. In your panel admin open Backup, click Generate Backup Now, then download the file from
/home/xtreamaster/backups/. - Set up the new server in the Master CMS Panel: delete the old main server, add the new one (or re-install its OS) and enter the SSH details, then wait for the installation to finish. Installing the new server on Ubuntu 24.04 is the recommended path.
- Restore. Upload
backup.sql.gzto/home/xtreamaster/backups/, log in withadmin / admin, then open Backup and click Restore Backup. - Load balancers. Open Manage Server and, for each balancer, click its option and choose Restart Service. Allow up to two minutes.
- Reboot the main server as the final step.
If the main server IP changed, logging in to the Master CMS updates it automatically. You can also set a new IP by hand under Edit Main Server, and remember to update the A record in your DNS.
Restoring a large database quickly
The panel's own Restore Database button is fine for typical databases. For a large one, restoring over SSH is faster and more reliable. Backups live in /home/xtreamaster/backups/ with names like 1772301302.sql.gz:
The database port is 7999. Your database username, password and name are shown in the Master CMS: log in with your xm: account and edit your main server, and the details appear in the modal.
Cutting Over Without Downtime
Here is the real advantage of migrating to a separate new server: your old panel never stops. That turns a nerve-wracking overnight maintenance window into an ordinary afternoon.
- Install and migrate while the old panel serves normally. Nothing your subscribers touch has changed.
- Verify against live data, checking user counts, bouquets and a sample of lines and streams. You have a running reference to compare against, which an in-place reinstall would not give you.
- Test playback on the new server directly by IP and port before any subscriber is pointed at it.
- Check the DNS fields on the new main server under Servers, since Users CDN, Private Users CDN and Proxy IP or DNS [All] must point at the main server IP. A playlist that loads while nothing plays is nearly always one of these three.
- Switch DNS if your subscribers connect by hostname. Lower the TTL a day beforehand so the change propagates quickly.
- Keep the old server for a few days after cutover. It costs one more billing cycle and buys you a rollback that costs nothing to use.
If you are migrating away from a cracked panel, do not reuse the old machine. A fresh server is the entire point, since keeping the old operating system keeps whatever shipped with the crack.
Paths and Commands Reference
Everything in one place, for when you are mid-migration and do not want to scrub back through a video timeline.
| What | Where or command |
|---|---|
| Export old database | mysqldump -u USER -p DB_NAME > backup.sql |
| Export, large database | mysqldump --single-transaction --quick --routines -u USER -p DB_NAME > backup.sql |
| Backup file location | /root/backup.sql or /root/backup.sql.gz, on the new server |
| Upload command | scp backup.sql root@YOUR_SERVER_IP:/root/backup.sql |
| Delete dump after migrating | rm /root/backup.sql |
| Admin panel port | 7709 by default (HAProxy) |
| Streaming port | 8080 HTTP, 8443 SSL (Nginx) |
| MySQL port | 7999 |
| Panel backups folder | /home/xtreamaster/backups/ |
| Restore a large backup | zcat /home/xtreamaster/backups/FILE.sql.gz | mysql -u DB_USER -pDB_PASS -P 7999 DB_NAME |
| VOD destination | /home/xtreamaster/movies/ |
| VOD source, Xtream UI | /home/xtreamcodes/iptv_xtream_codes/movies/ |
| VOD source, XUI | /home/xui/content/vod/ |
| VOD source, NXT | /home/nxt/content/vod/ |
| Fix VOD ownership | chown -R xtreamaster:xtreamaster /home/xtreamaster/movies/ |
| Service debug scripts | bash /home/xtreamaster/start_services.shbash /home/xtreamaster/start_services_debug.sh |
| Start main server | Manage Server, Main Server Option, Restart Service |
| Start load balancer | Manage Server, LB Server Option, Re-install Balancer |
Troubleshooting
"Migration completed but I cannot log in"
Expected behaviour. Click MasterAdmin, then Reset Admin Password, set a new password, and log in on port 7709 or your custom port. Nothing is broken.
"The migration cannot find my backup file"
The file must be on the new server at /root/backup.sql, or /root/backup.sql.gz if compressed. Confirm with ls -lh /root/backup.sql on the destination. Uploading it to the old server, or to a different directory, is the usual cause.
"Remote Connection cannot reach my old database"
The old MySQL is either bound to 127.0.0.1 or firewalled. You can open it temporarily to the new server's IP only, never to 0.0.0.0, or simply switch to the backup file method, which exists for exactly this case and is the recommended option anyway.
"The import ran but the user count is wrong"
Suspect a truncated dump. Re-export with --single-transaction --quick, confirm the file ends with the "Dump completed" line, and migrate again. A partial dump imports without error and silently drops whatever came after the cut.
"A load balancer will not come online"
Remove the old panel's leftover install folder from /home/ on that balancer and reboot it. If it stays down, check for a full disk with df -h, clear space, then run the service scripts and read the error:
"Data is there but streams do not play"
Check in this order: main server service restarted, load balancers online, SSH passwords set on both, and the three DNS fields on the main server all pointing at the main server IP. Streams failing while the panel UI works is nearly always infrastructure state or DNS, not data.
"MAC devices load the playlist but nothing plays"
A MAC device uses the playlist DNS for streaming, not the panel DNS. Review all three DNS fields on the main server, watching for typos and for a DNS record pointing at a load balancer instead of the main server, then enable MAG Security under General Settings, Stalker Portal tab. Wait two to three minutes and test again.
"Movies show in the panel but return an error"
The files did not move, or they moved without ownership, or they were only moved on one of several servers. See Fixing VODs and repeat the move on every server that stores VOD files.
