Difference between revisions of "Wowza Server/Setup & Install"

From SETV Springfield Technical Wiki
Jump to: navigation, search
m (Common Issues)
m (SSL on Wowza)
Line 51: Line 51:
 
A combination of the steps outlined [https://vanmarion.nl/blog/blog/ssl-letsencrypt-wowza-4-x-server-frontend/ HERE] and [https://markandruth.co.uk/2017/10/23/using-letsencrypt-with-wowza-media-server HERE] were used to set it up on the current server. The idea being you install Certbot, download a custom script, run certbot for the wowza.ssdcougars.tv domain, run the custom script to convert the certbot .pem keys into a JKS store (A Java file, Wowza runs entirely in Java). You then enable a cron job to do this automatically before the LetsEncrypt/Certbot keys expire every 3 months.
 
A combination of the steps outlined [https://vanmarion.nl/blog/blog/ssl-letsencrypt-wowza-4-x-server-frontend/ HERE] and [https://markandruth.co.uk/2017/10/23/using-letsencrypt-with-wowza-media-server HERE] were used to set it up on the current server. The idea being you install Certbot, download a custom script, run certbot for the wowza.ssdcougars.tv domain, run the custom script to convert the certbot .pem keys into a JKS store (A Java file, Wowza runs entirely in Java). You then enable a cron job to do this automatically before the LetsEncrypt/Certbot keys expire every 3 months.
  
<code>0 5 * * * root /usr/bin/certbot renew --standalone --pre-hook 'systemctl stop WowzaStreamingEngine' --post-hook '/usr/local/WowzaStreamingEngine/java/bin/java -jar /usr/bin/wowza-letsencrypt-converter-0.1.jar /usr/local/WowzaStreamingEngine/conf/ssl/ /etc/letsencrypt/live/; systemctl start WowzaStreamingEngine'</code>
+
<code><s>0 5 * * * root /usr/bin/certbot renew --standalone --pre-hook 'systemctl stop WowzaStreamingEngine' --post-hook '/usr/local/WowzaStreamingEngine/java/bin/java -jar /usr/bin/wowza-letsencrypt-converter-0.1.jar /usr/local/WowzaStreamingEngine/conf/ssl/ /etc/letsencrypt/live/; systemctl start WowzaStreamingEngine'</s></code>
 +
 
 +
Basically, you use Certbot to create the normal SSL certificate.
 +
 
 +
Then you use <code>/usr/local/WowzaStreamingEngine/lib/wowza-letsencrypt-converter-0.1.jar</code> to convert the standard certificates into a Java readable format. The <code>jksmap.txt</code> is a mapping text telling Wowza where to look for the files. The info listed in this TXT file must match what is listed in <code>/usr/local/WowzaStreamingEngine/conf/VHosts.xml</code>
 +
 
 +
You need to find the SSL attributes and make sure that <code><SSLConfig></code> matches the relevant file paths. (Check the guide liked above for further details and examples)
 +
 
 +
The Wowza JAVA SSL file is located under <code>/usr/local/WowzaStreamingEngine/conf/ssl/wowza.ssdcougars.tv.jks</code>
  
 
== Common Issues ==
 
== Common Issues ==

Revision as of 17:34, 24 April 2018

This page is to describe how Wowza was installed.

Quick Points:

  • Linux Debian 8
  • Basic LAMP Installation (Linux, Apache, MySQL, PHP)
  • Wowza Streaming Engine .runpackage
  • Media is stored on external drive /media/vod1
  • /media/vod1 is network discoverable via SAMBA sharing
  • FTP access was enabled to two folders on the /media/vod1 drive

Wowza Install instructions

  • Navigate to the folder that contains the downloaded Linux package and then execute the following commands, depending on your platform. Then, follow the wizard instructions.[1]

64-bit Linux systems

sudo chmod +x WowzaStreamingEngine-4.7.1-linux-x64-installer.run sudo ./WowzaStreamingEngine-4.7.1-linux-x64-installer.run

During the installation process, you'll be asked:

  • To accept the terms of the license agreement.
  • To enter a valid product license key. If you acquired a new license key, you'll find it in the email that you received from Wowza Sales. If you have a previous version of the Streaming Engine software installed, you may be able to use the license key found in the [install-dir]/conf/Server.license file.
  • To create a user name and password for an Administrator account. You'll use this account to sign in to the browser-based Wowza Streaming Engine Manager. The user name and password values are case-sensitive.
  • To confirm or change the install location. By default, Wowza Streaming Engine installs files in the following directories: Linux: /usr/local/WowzaStreamingEngine-4.7.1/ (as the root user)

Start the software as a service (Linux)

To start Wowza software as a service on Linux, you must be the root user with sudo access. If these instructions don't apply to your Linux distribution, consult your Linux manual.

  1. In a terminal window, enter one of the following commands, depending on your Linux distribution: sudo service WowzaStreamingEngine start -OR- /etc/init.d/WowzaStreamingEngine start
  2. Confirm that the engine is running by opening a web browser and entering the following URL: http://[wowza-ip-address]:1935 For [wowza-ip-address], use the IP address or domain of the local or remote Wowza server. For example: http://localhost:1935 The browser should display the Wowza Streaming Engine software version number. If not, check to see if the server software installed correctly and that TCP port 1935 is open on your router, firewall, and in your iptables.
  3. After the Wowza Streaming Engine server software is running, start Wowza Streaming Engine Manager. In a terminal window, enter one of the following commands, depending on your Linux distribution: sudo service WowzaStreamingEngineManager start -OR- /etc/init.d/WowzaStreamingEngineManager start

Updating Wowza

  1. SSH Into Server[2]
  2. cd /usr/local/WowzaStreamingEngine/updates
  3. Get download link from wowza.com -- sign in and go to Downloads, Right Click and Copy Link Address
  4. wget https://store.wowza.com/downloads/user/5984a69bef0fd/WowzaStreamingEngine-Update-X.X.X.zip
  5. unzip WowzaStreamingEngine-Update-X.X.X.zip -d WowzaStreamingEngine-Update-X.X.X
  6. cd WowzaStreamingEngine-Update-X.X.X/linux
  7. chmod a+x *.sh
  8. service WowzaStreamingEngineManager stop
  9. service WowzaStreamingEngine stop
  10. ./update.sh
  11. service WowzaStreamingEngine start
  12. service WowzaStreamingEngineManager start

SSH on Wowza

Follow this LINK and follow the instructions. [3]

You MUST have Open-JDK-8 installed and it is a pain in the ass. As of this writing, this has been done, so no need to worry.

SSL on Wowza

For security JWPlayer now requires HTTPS on all streams and sites with HTTPS enabled. This changes the port number the service streams (from 1935 to 443) and requires scripting and cron jobs to actively renew it.

A combination of the steps outlined HERE and HERE were used to set it up on the current server. The idea being you install Certbot, download a custom script, run certbot for the wowza.ssdcougars.tv domain, run the custom script to convert the certbot .pem keys into a JKS store (A Java file, Wowza runs entirely in Java). You then enable a cron job to do this automatically before the LetsEncrypt/Certbot keys expire every 3 months.

0 5 * * * root /usr/bin/certbot renew --standalone --pre-hook 'systemctl stop WowzaStreamingEngine' --post-hook '/usr/local/WowzaStreamingEngine/java/bin/java -jar /usr/bin/wowza-letsencrypt-converter-0.1.jar /usr/local/WowzaStreamingEngine/conf/ssl/ /etc/letsencrypt/live/; systemctl start WowzaStreamingEngine'

Basically, you use Certbot to create the normal SSL certificate.

Then you use /usr/local/WowzaStreamingEngine/lib/wowza-letsencrypt-converter-0.1.jar to convert the standard certificates into a Java readable format. The jksmap.txt is a mapping text telling Wowza where to look for the files. The info listed in this TXT file must match what is listed in /usr/local/WowzaStreamingEngine/conf/VHosts.xml

You need to find the SSL attributes and make sure that <SSLConfig> matches the relevant file paths. (Check the guide liked above for further details and examples)

The Wowza JAVA SSL file is located under /usr/local/WowzaStreamingEngine/conf/ssl/wowza.ssdcougars.tv.jks

Common Issues

"Loading Player..."

Check the Wowza URL in the Wordpress post. Make sure there is not even a space or new line after .m3u8

No incoming streams seen, no videos play after a reboot/power outage

Try to sign into the Wowza Management Portal, and make sure the licences are active. Sign in, if it asks to enter license keys, just press SUBMIT or ACTIVATE

Cross-Domain Access Denied

Check the Wowza SSL Certificate, it probably expired and will need to be manually renewed.

Sources

  1. https://www.wowza.com/docs/how-to-install-and-configure-wowza-streaming-engine#installWowza
  2. https://www.wowza.com/docs/how-to-update-your-wowza-streaming-engine-installation
  3. https://markandruth.co.uk/2017/10/23/using-letsencrypt-with-wowza-media-server