Restore IPTV MW from the backup
Follow this points if you created a backup and upgraded the system. Now you want to set up the system with the old data but new software.
Note: If the project involves only TV channels, it is more efficient to install a new demo database and configure the TV channels and devices using SQL.
Installation process
Step by step:
Install a new IPTV SW:
Install the new IPTV MW .run fie
Copy backup files:
Copy back the backup folder to this newly installed server. For example, copy it to the folder root/install (create that folder install)
Prepare the files:
If installation is from Centos6 then open default.ini file and copy one section to the new default.ini, path: /var/www/portal_base/application/etc/profiles/default.ini
Locate this section in the old default.ini
file and paste it into the new one—its exact position within the file doesn’t matter. These are the old menu links, and we need their IDs to ensure the new Manager links them correctly. Centos 7 instalaltions don’t need this step any more.
Copy images:
Use MC tool to copy images from backup to the new server in the location:
/var/www/portal_base/data/profiles/default/images/
Run command to clear old images from temporary folders.
rm -rf /var/www/portal_base/data/terminals/global/images/db*
Set database from the backup:
Run commands to upload the old database. Where you see a .sql you write the name of your database:
cd /root/install
mysql --user=root --password=centos
DROP DATABASE iptv;
CREATE SCHEMA iptv DEFAULT CHARACTER SET utf8;
SET NAMES utf8;
USE iptv;
SOURCE iptv_backup.sql
Continue pasting next commands below.
Run commands to polish the old database to work on the new one:
update Info set SortID = 1 where ( Id > 0 ) AND ( ( SortID is NULL ) OR ( SortID = 0 ) );
update ShopItem set SortID = 1 where ( Id > 0 ) AND ( ( SortID is NULL ) OR ( SortID = 0 ) );
update MinibarItems set sort_id = 1 where ( Id > 0 ) AND ( ( sort_id is NULL ) OR ( sort_id = 0 ) );
exit
Run the command to refresh the database. If you get any errors about the duplicated IPs or MAC, you will need to delete them from the old manager and import the database again.
Command to refresh the database:
dbr
Open the IPTV manager and check how it looks like. If it opens and data are there, then it is ok. You will edit other small details later.
Set the Device licence back: Find old licence if it is the same server, otherwise create a new one and set it in Streamron.
Copy back the streams:
Copy all streams from the streamer:
Path: /opt/nevron/streamer/r12440/conf/guardian/db
Delete the old database folder to ensure you only have the new streams.
You can use the MC (Midnight Commander) tool to copy files from the backup folder to the new location. Here are the key commands in MC: F8 key is to delete, F5 is to copy, TAB to jump sides
Restore the DVB card numbering in
hal.db
If the server is identical, you can simply copy the hal.db
file back to restore the card numbering. However, if you're using a new server, this approach won't work. If you've upgraded from CentOS 6, the hal.db
file exists but is located in a different directory. In this case, you'll need to generate a new hal.db
file and then copy the contents from the old file into the new one. How to generate, check the guide here.
Path: /etc/streamer_hal.db
Restart the streamer:
systemctl restart streamer
Prepare STB FW:
Check on the current production server what STB models they have.
Upload proper STB FW on the server and ask IT guys to connect all stbs online (if possible)
Configuration process
Set server’s configurations back:
Set network IPs:
Check in the backup file and set the same IPs back with the nmt tool.
Type command:
nmtui
Install DW service:
We don’t need to have two, so reinstall or delete the old one from the DW. Then open the DW to check if it is a XWayland screen error.
Check DHCP and set the same as in backup file.
Edit the IPs and pools:
nano /etc/dhcp/dhcpd.conf
Restart with the command:
systemctl restart dhcpd
Check resources.ini file and set back if it was IP or MAC based IPTV system
Map the data folder
Stop the streamer:
systemctl stop streamer
Move data folder into Home folder:
mv /data /home/data
Create a link between the folders:
ln -s /home/data /data
Reboot the server:
reboot
Check chrony config and set it back.
Edit the IP inside the file to set the server’s DNS range and mask.
Restart the named service with the command:
systemctl restart chronyd
Check named (DNS):
Compare the files and edit the IPs to match the backup. Add any new .zone files you may have in the backup. Check the etc/named/ folder and the /etc/named.conf file.
Edit through the ssh tool with the commands:
nano /etc/named/base.ntv.zone
nano /etc/named/nevron.tv.zone
nano /etc/named/nevronitv.si.zone
nano /etc/named/iptv.local.zone
nano /etc/chrony.conf
Restart the named service with the command:
systemctl restart named
Check Firewall:
In old Centos 6 the firewall was named iptables.
Check files in the folder and add all ports you need: /etc/firewalld/zones/.
Check if ports are the same as in backup:
nano /etc/firewalld/zones/public.xml
Check if this file exists. Only specific clients use it like Silversea.
There you need to set the IP they use and the LAN card is from the management network, not iptv.
nano /etc/firewalld/zones/direct.xml
Restart the firewall with the command:
systemctl restart firewalld
Check if firewall was prior to reinstall turned on or off and set the same.
Check cronjobs
Check in Hourly or monthly cron file if there are any new lines added.
Set clearing logs and refresh of services:
Run command:
crontab -e
It will open the file in vi tool where you paste the line:
0 2 * * 0 /usr/local/bin/restart_services.sh
Set Rover service:
Check the device settings and set it back as it was.
Path: /opt/nevron/rover/conf/eas.conf and stb.conf
You can edit through WinSCP or the ssh terminal:
nano /opt/nevron/rover/conf/eas.conf
nano /opt/nevron/rover/conf/stb.conf
You can copy both, then restart the rover service:
systemctl restart rovergw
Equip devices:
When you copy the database, you need to run the command which will insert all device's IPs and MAC in the DHCP file. Run the command: (Or press the Equip All button in the Manager)
iptv stb:registered:equip-all
Check Swank and Anuvu script:
Set the paths and links back as they were. Check if there are new scripts for them and set it up. Don’t use the old ones. On NAS we store scripts in folder /RR/Integracije
Check NHI and set it back as it was (bootable).
Edit the file setting.xml, don’t copy the old file. Edit the last paragraph and the settings how bills are refreshed and how devices are rebooted.
Restart nhi with the command:
systemctl restart nhi.service
Set bootable:
systemctl enable nhi.service
Restart all those services and reboot the server. This way you will see if you set them bootable.
Check and set back and other systems they have , for example Ship position, Sambashare link…
Upgrade the STBS with the latest FW.
Check STB configurations:
Check if they have the homepage set and all the remote, drivers, settings as before. Check in the backup files what the stbs had set before the upgrade. This is made for the pre-caution if you maybe deleted all configuration with the STB upgrade.
Streamron Headend checkup:
Login to streamer and start the server process, check the streams' status. Check in Streamer if all live channels work and if link for VoD is the right one.
Do a check-up on STBs:
Check if STBS have the same rs232 driver set, same remote and if it’s enabled the driver and the remote.
IMPORTANT: They need to confirm it is working because they could switch the TVs in the meantime. It happens a lot on older projects. OR the new FW is not supporting the settings they had before. That why they need to test.
Design change process
You can ask our design team to do a checkup and adjust to the new design layout.
Prepare design to the new layout:
Meanwhile, STBS are updating, check the HTML client in the browser and adjust the design to the new version. You will probably need to change the icons.
Set the new welcome template:
Set a new Welcome message and test it.
New welcome message is under localization key: template_default
Where you can paste also the logo image, size approx 1920x300px.
Enable the new template under System → Menu settings → Conf: Welcome → Menu appearance → Screen Type → Half screen
Change old placeholders:
In the top left corner of the dashboard, you'll see the welcome message. Update the placeholders to reflect the new room or guest data placeholders.
Path: System - Content Settings - Localization menu
Find key: infoHeaderWelcomeText and Edit it by setting the new placeholders.
Copy new icons: Set new icons 176x176px
Internal path: NAS: Release folder \Axon-hotel\Icons\axon-dash-176x165-rounded
Copy file default.en.overrides.po:
Set translation for the Administration menus (You can copy old file).
Path: /var/www/portal_base/application/manager/languages/default.en.overrides.po
Copy the file from the backup and overrun it over the new one.
Edit file manager.json: Set the menu rights (manager.json) but you can’t copy old file. Edit from true, to false if you want to hide the menu.
Disable the menus we don’t use any more on HTML 2: news, games, internet, survey, bills, messages
Disable old Info channel menu (On centos 6 ): If you see an older Info channel menu on the STB screen, you need to go to the SQL - Table Info . Sort by ID and find the Info channel. Usually is ID 9 and disable it by changing its parameter Enabled from 1 to 0.
Change button colors:
System - Menu settings - Conf:dashboard = You have focused and unfocused color buttons, stroke color..
System - Menu settings - Conf:General = You have focused and unfocused color buttons, stroke color..
System - Menu settings - Menu:Welcome = You have focused and unfocused color buttons, stroke color..
System - Menu settings - Menu:TV = You have focused and unfocused color buttons, stroke color..