
yp-web Installation
This section provides a comprehensive guide to setting up the WEB-UI (YP-WEB).
If the SDK software is installed from a binary package, then the 'yp-web-core' application is already installed.
If the SDK is being built from source files, then follow the instructions in the Building the Server with YP-WEB section.
Systemd Service Configuration
To ensure YP-WEB starts automatically and runs continuously, copy the yp-web-core.service file to the systemd directory, reload systemd, enable, and start the service.
mydir> sudo cp /usr/lib/yumapro/yp-web/yp-web-core.service /etc/systemd/system/
mydir> sudo systemctl daemon-reload
mydir> sudo systemctl enable yp-web-core
mydir> sudo systemctl start yp-web-core
Verify the service status:
mydir> sudo systemctl status yp-web-core
If YP-WEB fails to start, check the logs with:
mydir> journalctl -u yp-web-core --no-pager --lines=100
Web Server Configuration
To serve YP-WEB, a web server such as NGINX or Apache must be configured. The provided example configuration files are preconfigured to serve YP-WEB on port 8080 by default. Adjustments may be required based on deployment requirements and network settings.
NGINX Configuration (ypweb-nginx.conf):
Copy the example configuration:
mydir> sudo cp /usr/share/yumapro/util/ypweb-nginx.conf /etc/nginx/sites-available/yp-web
mydir> sudo ln -s /etc/nginx/sites-available/yp-web /etc/nginx/sites-enabled/
The default configuration listens on port 8080. If necessary, update ypweb-nginx.conf to use a different port.
Restart NGINX:
mydir> sudo systemctl restart nginx
Apache Configuration (ypweb-apache2.conf):
Before configuring Apache, ensure that the required mod_proxy
,
mod_proxy_http
and mod_proxy_wstunnel
modules are enabled. If these
modules are not enabled, Apache will fail to start with an error related to the
ProxyPass
directive.
To enable the necessary modules, run:
sudo a2enmod proxy
sudo a2enmod proxy_http
sudo a2enmod proxy_wstunnel
sudo systemctl restart apache2
Once the modules are enabled, proceed with the configuration:
Copy the example configuration:
mydir> sudo cp /usr/share/yumapro/util/ypweb-apache2.conf /etc/apache2/sites-available/yp-web.conf
mydir> sudo a2ensite yp-web.conf
The default 'yp-web' configuration listens on port 8080. If needed, modify ypweb-apache2.conf to change the port. Otherwise make sure port '8080' is enabled in the Apache2 configuration file, usually '/etc/apache2/ports.conf'. Add the like 'Listen 8080' to this file.
Restart Apache:
mydir> sudo systemctl restart apache2
Launching YP-WEB
Once the systemd service and web server are configured, follow these steps:
Ensure the YP-WEB core service is running:
mydir> sudo systemctl status yp-web-core
Ensure the web server is running:
If using NGINX:
mydir> sudo systemctl status nginx
If using Apache:
mydir> sudo systemctl status apache2
Start the NETCONF server
If you don’t have a NETCONF server running, refer to Starting netconfd-pro for detailed instructions.
For a basic setup, you can start netconfd-pro as follows:
mydir> netconfd-pro --access-control=off --log-level=debug2
--access-control='off' disables user authentication and access control.
--log-level='debug2' sets a detailed logging level for debugging.
To check if the NETCONF server is running, use:
mydir> ps aux | grep netconfd-pro
Ensure `yangcli-gw` is active.
If you don’t have a yangcli-gw application running, refer to yangcli-gw Getting Started for detailed instructions.
For a basic setup, you can start yangcli-gw as follows:
Basic example:
mydir> yangcli-gw
Verify that `yangcli-gw` is running:
mydir> ps aux | grep yangcli-gw
If yangcli-gw fails to start, check the logs for any errors:
mydir> journalctl -u yangcli-gw --no-pager --lines=100
Access YP-WEB through your browser: Open http://<server_ip>:8080 to access the web interface.