How To Trim and Export and Import the Xtream Codes / XTREAM UI Database as SQL or gzip manually

You can trim your Database and remove the useless entries. This will clear the tables client_logs and user_activity,

1. Install WinSCP
2. Install Putty
3. connect with WinSCP to your Server
4. open Putty
5. Connect to the Database

mysql -u root -p

At the Enter password: prompt, well, enter mySQL Root Password

6. Select Xtream Codes Database

mysql> USE xtream_iptvpro;

7. Trim your Database and remove the useless entries with:

mysql> TRUNCATE TABLE client_logs;
mysql> TRUNCATE TABLE user_activity;
mysql> TRUNCATE TABLE user_activity_now;
mysql> TRUNCATE TABLE reg_userlog;
mysql> TRUNCATE TABLE epg_data;
mysql> TRUNCATE TABLE streams_sys;
mysql> TRUNCATE TABLE stream_logs;
mysql> TRUNCATE TABLE streams_options;

mysql> exit;

8. Export Xtream Codes Database as gzip manually

mysqldump -u root -p xtream_iptvpro | gzip > XtreamBackup.sql.gz

Export Xtream Codes Database with Timestamp and as gzip manually

mysqldump -u root -p xtream_iptvpro | gzip > XtreamBackup_$(date "+%b_%d_%Y_%H_%M_%S").sql.gz

At the Enter password: prompt, enter again mySQL Root Password

9. Download with WinSCP the Backup File from /root Folder to your local PC

Importing the DB Dump into the new DB

As .sql file

mysql -u root  -p xtream_iptvpro < [filename].sql

As gunzip archived sql (.sql.gz) File

gunzip < databasefile.sql.gz | mysql -u root -p xtream_iptvpro
or
zcat databasefile.sql.gz | mysql -u root -p xtream_iptvpro

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.