...
This section provides examples of installing and configuring ECSS-10 for a system with a single server and for a cluster of two servers.
Initial system installation without redundancy with one server
Якорь | ||||
---|---|---|---|---|
|
Initial data
Информация |
---|
Initial data Integration of the ECSS-10 Class 5 software switch (SSW) on 1 physical server with support for SIP with the following parameters per load:
|
...
Server name (host) | Role | Interface | Address | Port |
---|---|---|---|---|
Static addresses of the software switch | ||||
ecss1 | Server management interface (port 2000 ssh) | net.10 | 10.0.10.11/24 | 2000 |
ecss2 | Server management interface (port 2000 ssh) | net.10 | 10.0.10.12/24 | 2000 |
ecss1 | Core addres (ecss-core) | net.20 | 10.0.20.11/24 | 5000 |
ecss2 | Core addres (ecss-core) | net.20 | 10.0.20.12/24 | 5000 |
ecss1, ecss2 | Gateway address | net.10 | 10.0.10.1 | - |
ecss1, ecss2 | DNS server addresses | net.10 | 10.0.10.1, 8.8.8.8 | - |
ecss1, ecss2 | NTP server addresses | net.10 | 10.136.16.211, 10.136.16.212 | 123 |
Internal addresses of the software switch | ||||
ecss1 | virtual address of eccs1 host software adapter | net.20:SIP1 | 10.0.20.31/24 | - |
ecss2 | virtual address of eccs2 host software adapter | net.20:SIP2 | 10.0.20.32/24 | - |
ecss1 | backup virtual address of eccs2 host software adapter on eccs1 host | net.20:SIP2 | 10.0.20.32/24 | - |
ecss2 | backup virtual address of eccs1 host software adapter on eccs2 host | net.20:SIP1 | 10.0.20.31/24 | - |
ecss1, ecss2 | MySQL database virtual address (ecss-mysql) | net.10:MYSQL | 10.0.10.10/24 | 3306 |
Connecting to network
The topology of connecting the server to the network to ensure redundancy is recommended to be done using 2 switches.
...
Server network interfaces are also included in pairs in switches, on which port aggregation (port-channel) is configured in LACP mode. For example, eth0 and eth1 are included to first switch (port-channel 1), and eth2 and eth3 — to the second (port-channel 2).
Configuring network
Install the software switch according to the parameters specified in the technical specification. In this example, it is assumed that the required operating system is already installed.
...
A single address for accessing the MySQL database is defined for all cluster nodes, for example, the ecss-mysql address 127.0.0.1. Thus, the uniformity condition is fulfilled, in which all cluster nodes have completely identical data about the current state of the dynamic components of the software switch (for example, call history).
Preparing system network interfaces
According to the technical specification, the system has 4 network interfaces. Information about their status can be viewed using the ifconfig or ip a command:
...
Без форматирования |
---|
sudo apt update sudo apt upgrade |
Software installation and configuration
Предупреждение | ||
---|---|---|
| ||
Do NOT install the packages as ssw user. |
...
sudo apt install aptitude atop ethtool htop iotop mc minicom mtr-tiny nmap pptpd pv screen ssh tftpd vim sngrep tshark cpanminus gnuplot libgraph-easy-perl debconf-utils |
Installing ecss-mysql package
The installation begins with the deployment of the MySQL server and the integration of the ecss-mysql database.
...
sudo apt install ecss-mysql |
Configuring ecss-dns-env package
Before installing the ecss-mysql package, you will be prompted to configure environment variables for services in dnsmasq. Configuration manager will prompt to select the sections to configure, do not select anything.
Configuring ecss-mysql package
When installing the package, the following data will be requested:
...
sudo systemctl status mysql ● mysql.service - MySQL Community Server |
Installing the ecss-node package
Installing the ecss-node package:
...
To generate certificates, select manual method. All questions can be answered as suggested by default.
Installing ecss-media-server, ecss-media-resources, ecss-restf, ecss-web-conf packages
Next, ecss-media-server, ecss-media-resources, ecss-restf, ecss-web-conf and other packagesare installed in any order:
ecss-media-server, ecss-media-resources
Без форматирования |
---|
sudo apt install ecss-media-server ecss-media-resources |
...
realm — defines the address for registration on the core. Default entry point: port 5000, address: 127.0.0.1.
ecss-restfs
Без форматирования |
---|
sudo apt install ecss-restfs |
...
Questions | Answers |
---|---|
Use TTS service | No |
Configure phone book | No |
Configure speech recognition service | No |
Choose nothing | Ok |
ecss-web-conf
Без форматирования |
---|
sudo apt install ecss-web-conf |
...
Questions | Answers |
---|---|
Input IP address or hostname of MySQL db for web-conf DB | 127.0.0.1 |
Input port of MySQL db for web-conf DB | 3306 |
Input IP address or hostname for ECSS-10 with http_terminal | 127.0.0.1 |
Input port SSW http_terminal | 9999 |
Input login for SSW http_terminal | admin |
Input password for SSW http_terminal | password |
Configuring security. SSH
Configuring SSH server:
sudo nano /etc/ssh/sshd_config |
...
Без форматирования |
---|
sudo systemctl restart ssh.service |
Initial configuration
Start the necessary services.
...
After creating the domain, configure:
- routing;
- users;
- subscribers;
- trunks and bridges.
Initial installation of a redundant system in a cluster of two servers
Initial data
Информация | ||||
---|---|---|---|---|
| ||||
Technical specification: Integration of the ECSS-10 Class 5 software switch (SSW) on 2 physical servers with SIP support is required with the following parameters of the server group load:
|
...
Server name (host) | Role | Interface | Address | Port |
---|---|---|---|---|
External addresses of the software switch | ||||
ecss1 | Server management interface (port 2000 ssh) | bond2_ecss1_mgm | 10.0.3.237/24 | 2000 |
ecss2 | Server management interface (port 2000 ssh) | bond2_ecss2_mgm | 10.0.3.240/24 | 2000 |
ecss1 | Software Adapter interface of ecss1 host (ecss_pa_sip) | bond1_ecss1_pa | - | - |
ecss2 | Software Adapter interface of ecss2 host (ecss_pa_sip) | bond1_ecss2_pa | - | - |
ecss1 | Virtual address of the ecss1 host software adapter | VRRP:SIP1_Mr | 10.0.3.238/24 | - |
ecss2 | Virtual address of the ecss2 host software adapter | VRRP:SIP2_Mr | 10.0.3.241/24 | - |
ecss1 | Alternative virtual address of the ecss2 host software adapter on the ecss1 host | VRRP:SIP2_Bup | 10.0.3.241/24 | - |
ecss2 | Alternative virtual address of the ecss1 host software adapter on the ecss2 host | VRRP:SIP1_Bup | 10.0.3.238/24 | - |
Internal addresses of the software switch | ||||
ecss1 | Internal address of the ecss1 host | vlan2 | 192.168.1.1/24 | - |
ecss2 | Internal address of the ecss2 host | vlan2 | 192.168.1.2/24 | - |
ecss1 | Core address (ecss-core) | vlan2 | 192.168.1.1/24 | 5000 |
ecss2 | Core address (ecss-core) | vlan2 | 192.168.1.2/24 | 5000 |
ecss1 | Media server address (ecss-media-server (MSR)) | vlan2 | 192.168.1.1/24 | 5040 |
ecss2 | Media server address (ecss-media-server (MSR)) | vlan2 | 192.168.1.2/24 | 5040 |
ecss1 | MySQL Database Virtual Address | vlan2:mysql (VRRP) | 192.168.1.10/24 | 3306 |
Connecting to network
The topology of connecting the server to the network to ensure redundancy is recommended to be done using 2 switches.
...
All 4 physical network interfaces are connected into 1 aggregated link (bond). Server port aggregation is configured in 802.3ad mode. Network cards aggregated groups with same rate and duplex are created. With such a combination, the transmission uses all channels in active aggregation according to the IEEE802.3ad standard. The choice on which interface to send a packet is determined by policy. By default, it is XOR policy, also xmit_hash policy can be used. For more information, see Netplan section.
Requirements:
- Ethtool support in driver to obtain information about speed and duplex on each network interface;
- IEEE802.3ad standard support on switch.
Server network interfaces are also included in pairs in switches, on which port aggregation (port-channel) is configured in LACP mode. For example, eth0 and eth1 are included to first switch (port-channel 1), and eth2 and eth3 — to the second (port-channel 2).
Configuring network
Install the software switch according to the parameters specified in the technical specification. In this example, it is assumed that the required operating system is already installed.
...
Предупреждение | ||
---|---|---|
| ||
Note that while editing netplan, you must follow the YAML markup rules:
→ Section |network → Subsection |_'_'bonds: → Subsection of the bonds section description |_'_'_'_'bonded_one: → etc. |_'_'_'_'...
|
Example of netplan for active-backup mode
Netplan for ecss1 server interfaces (/etc/netplan/ecss_netplan.yaml) | Netplan for ecss2 server interfaces (/etc/netplan/ecss_netplan.yaml) | ||||
---|---|---|---|---|---|
|
|
Example of netplan for 802.3ad mode
Netplan for ecss1 server interfaces (/etc/netplan/ecss_netplan.yaml) | Netplan for ecss2 server interfaces (/etc/netplan/ecss_netplan.yaml) | ||||
---|---|---|---|---|---|
|
|
Apply parameters with the command:
sudo netplan apply |
Configuring /etc/hosts
After configuring netplan, specify that the internal address 192.168.1.X belongs to the corresponding ecssX server. To do this, configure /etc/hosts.
...
Accessing ecss2 from ecss1 | Accessing ecss1 from ecss2 |
---|---|
ping ecss2 PING ecss2 (192.168.1.2) 56(84) bytes of data. | ping ecss1 PING ecss1 (192.168.1.1) 56(84) bytes of data. |
Operating system software update
To install the ECSS-10 system, add the ELTEX repository:
...
Без форматирования |
---|
sudo apt update sudo apt upgrade |
Software installation and configuration
Install all the proposed packages:
...
Без форматирования |
---|
sudo apt install ifenslave-2.6 keepalived attr |
Installing the ecss-mysql package
To install, run the command:
Без форматирования |
---|
sudo apt install ecss-mysql |
Configuring the ecss-dns-env package
Before installing the ecss-mysql package, you will be prompted to configure environment variables for services in dnsmasq. The customizer will prompt you to select the sections to configure. Choose broker and mysql.
Questions | Replies for ecss1 | Replies for ecss2 |
---|---|---|
Secondary broker address | 192.168.1.2 | 192.168.1.2 |
mysql address | 192.168.1.10 | 192.168.1.10 |
Configuring the ecss-mysql package
During installation, the customizer will ask questions, replies are given in the table below. Note that the password is the same for both hosts on which mysql is installed.
...
Блок кода |
---|
sudo mysql -uroot -p -e 'show slave status \G;' | grep -E "Slave_IO_Running:|Slave_SQL_Running:" Enter password: Slave_IO_Running: Yes Slave_SQL_Running: Yes |
Editing keepalived.conf
Next step is to edit global configuration file keepalived.conf. The contents are the same on both hosts.
...
Then /etc/keepalived/mysql.conf are created on both hosts.
Creating VRRP for MySQL
/etc/keepalived/mysql.conf for ecss1 | /etc/keepalived/mysql.conf for ecss2 |
---|---|
# Configuring mysql for first node: vrrp_script check_mysql { script "/usr/bin/mysql --defaults-file=/etc/mysql/debian.cnf -e 'SELECT 1;'" user root interval 2 fall 1 timeout 2 } vrrp_instance MySQL { state MASTER # Initial state at start interface net.10 # Name of the network interface, on which VRRP will operate virtual_router_id 10 # Unique router id (0..255) priority 100 # Priority (0..255) the higher the more advert_int 1 # Notification sending interval (sec) preempt_delay 60 # Master wait interval at daemon start (sec) at BACKUP initial state unicast_src_ip 10.0.10.11 # Own real IP address unicast_peer { 10.0.10.12 # Neighbour real IP address } virtual_ipaddress { # Virtual IP address and a mask # dev - network interface on which virtual address will operate # label - virtual interface label (for ease of identification) 10.0.10.10/24 dev net.10 label net.10:mysql } track_script { check_mysql } } | # Configuring mysql for the second node: vrrp_script check_mysql { script "/usr/bin/mysql --defaults-file=/etc/mysql/debian.cnf -e 'SELECT 1;'" user root interval 2 fall 1 timeout 2 } vrrp_instance MySQL { state MASTER # Initial state at start interface net.10 # Name of the network interface, on which VRRP will operate virtual_router_id 10 # Unique router id (0..255) priority 50 # Priority (0..255) the higher the more advert_int 1 # Notification sending interval (sec) preempt_delay 60 # Master wait interval at daemon start (sec) at BACKUP initial state unicast_src_ip 10.0.10.12 # Own real IP address unicast_peer { 10.0.10.12 # Neighbour real IP address } virtual_ipaddress { # Virtual IP address and a mask # dev - network interface on which virtual address will operate # label - virtual interface label (for ease of identification) 10.0.10.10/24 dev net.10 label net.10:mysql } track_script { check_mysql } } |
...
ifconfig |
Installing the ecss-node package
Installing the ecss-node package:
...
Select manual mode for certificates generation. All questions can be answered with default answers by clicking "Enter" for all questions.
Installing and configuring the remaining ecss packages
Next, install all the necessary packages on both hosts (for more information on installing necessary and additional packages, see "Installation of ECSS packages"):
...
- msr_name is a parameter that defines the name of the msr. (it is recommended to set the name of the msr. and the host to which it belongs, for example, msr.ecss1);
- realm — defines the address for registration on the core. Default entry point: port 5000.
Configuring VRRP for SIP adapter
To configure VRRP for SIP adapter, create on both servers files, the view of which is shown below:
...
sudo systemctl restart keepalived.service |
Further configuring of the software switch
mycelium.config
Cluster name is set in the ecss-mycelium /etc/ecss/ecss-mycelium/mycelium.config package configuration:
...
Configuring cluster name (/etc/ecss/ecss-mycelium/mycelium1.config) |
---|
%%% -*- mode:erlang -*- |
Якорь | ||||
---|---|---|---|---|
|
epmd
Configuring epmd:
systemctl edit epmd.service |
...
systemctl daemon-reload systemctl restart epmd.service |
glusterfs
Configure glusterfs for ecss-restfs on the first host (ecss1), to do this, install the glusterfs-server and attr packages on both hosts:
...
df -h <...> |
Configuring security. SSH
Configuring SSH server:
Без форматирования |
---|
sudo nano /etc/ssh/sshd_config |
...
Без форматирования |
---|
systemctl restart ssh.service |
Configuring ecss-node package cluster
Start the necessary services:
...
It can be seen that the nodes have entered the cluster and the MSR has registered on the ecss-core node.
Configuring group of IP addresses (IP-set)
Configure SIP adapter according to the technical specification:
...
After creating the domain, configure:
- routing;
- users;
- subscribers;
- trunks.
Example of a primary system configuration using web configurator
Initial data
- System installation is complete;
- System is ready for further configuring;
- Interfaces are running.
...
- Subscribers with numbers 101, 102 , 103, 104 ,105, 106, 107, 108, 109, 110;
- Trunk towards the gateway.
Preparation for work
Figure 1 — Log in to the web configurator (authorization window)
...
Figure 2 —View of the web configurator workspace
Creating an operator account
After authorization, in order to increase security during the operation of the software switch, it is recommended to create accounts for operators, as well as to change the password for the admin user.
...
Figure 6 — Edit user dialog box
Creating a domain
To create a domain, log in to the Domains application. In the window that opens, create a domain, for this:
...
To edit current domain, it must be selected in the system. To switch to a domain, use the domain selection option (see point 2 in the figure View of the web configurator workspace).
After selecting the domain, according to the current system configuration, all applications will be available:
...
Figure 10 — Displaying applications in current system configuration
Creating IP-set (sip transport) and assigning it to a domain
To configure an interface, open the Clusters application.
...
Figure 14 — Configuration window for SIP transport
Creating subscribers
The Subscriber card application is used to create and edit subscriber parameters in the system.
...
Figure 16 — Example of identifying subscribers in a domain
Creating and applying routing contexts for a domain
Routing is responsible for finding the number and then addressing the call. At least one routing context must be configured for the system to operate correctly.
...
Figure 20 — Example of configuring routing context
Creating trunk
Якорь | ||||
---|---|---|---|---|
|
To create and edit trunk parameters in the system, use the Trunk manager application.
...
Figure 22 — Creating a trunk
Creating IVR script
Якорь | ||||
---|---|---|---|---|
|
To create IVR, use the IVR editor application.
...
Figure 25 — View of the IVR workspace
Completing routing configuration
To complete routing, open Routing manager application and in rules rule1 and rule3 adjust the corresponding routing results, and follow the steps below:
- rule1: select the "external" sub-item in the Result section. In the Value field of the Directions table add the trunk created earlier, then save the rule .
- rule3: select the "ivr" sub-item in the Result section. In the script field add the previously created ivr script, then save the rule and the context .
...
Figure 26 —Type of routing context
Configuring services
To configure the services, perform several actions:
...