Wowza 4.x – Multiple vhosts

The Wowza Streaming Engine software can be configured to run multiple virtual host (VHost) environments on a single server. This lets multiple users share a server in separate environments. Each VHost environment has its own set of configuration files, application folders, and log files and can be configured with its own system resource and streaming limitations

User guide: https://www.wowza.com/resources/WowzaStreamingEngine_UsersGuide.pdf
Tutorial referal made by me: https://www.wowza.com/forums/showthread.php?35355-VHost-ERROR

My example that i wanted to achieve:
new virtual host: vhost01
ipaddress : 192.168.10.17
streaming port: 1936

Step 1. add new virtual host to /conf/VHosts.xml

Step 2.Directory structure to copy the files to: this is what the structure should be.

Step 3. so the vhost01 structure should be placed in /usr/local/WowzaStreamingEngine/vhost01 if you look at the directory structure
note: if i look at step 1 the vhost01 should be placed in the config directory (${com.wowza.wms.ConfigHome}/vhost01) <= i will ignore this one

copy the files to /usr/local/WowzaStreamingEngine/vhost01 (just like the directory structure says and ignoring the directory class from the VHosts.xml

#note: you might want to remove your applications too in your new vhost directory. i was lazy

Step 4. The above changes only take place when you restart the wowza server. but first setup your log to follow problems that might occur

now you can restart the server from the browser : go to the streamingmanager (ip:8088). and restart the server.
restarting………. checking error log
darn:

Thats correct: the new vhost should run on a different port. lets set it to 1936 (page 63 from the user guide)

Refresh your browser: F5
you now can see under Server -> vhost01. click vhost01
then go on the left to Virtual Host Setup
click in the middle on Edit and change the Host Ports
Default Streaming / Streaming / * / 1935 / false
to
Default Streaming / Streaming / 192.168.10.17 (server ip) / 1936 / false
apply -> save -> restart vhost + check your error log again that is still running

error log is changing: from any ip to the new ip i have set:

now also port 5085 is present which is also available in the default vhost.

you know what?
press F5 in your browser and just restart the complete server.
this will activate the port change (1936). only the admin port is still present now

How do i get rid of the 5085 notice?

in your browser go to your vhost01 -> virtual host setup -> edit -> Host Ports and delete the line Default Admin from the Host Ports -> Save and restart the vhost after that. nothing happens.
go to server Setup and just restart the complete server
annnd gone. no more errors
to make sure. follow your access.log :

and restart the complete server to check if the vhosts are binded and if everything is starting. check the access.log and just restart it to check if the new vhost get binded

when i check the error.log after i have created an live application i get a new error:

i can solve this error by changing the file VHosts.xml in /usr/local/WowzaStreamingEngine/conf/VHosts.xml

from:

to:

 

this error looks to me of an error in the Setup. {comb.wowza.wms.ConfigHome} = /usr/local/WowzaStreamingEngine/conf but should be above the conf directory according to the directory structure.

it is working eventually, but some things aren’t documented correctly. To test a stream to the new vhost i add this address in my flme

where the ip is my server ip.
the port is from the new vhost
and live_vhost01 is just a test application i have setup unde the new vhost.

Note: sometimes the browser isnt updating after a restart. because i wanted to use the testplayer in wowza to test my new live stream and it wanted to connect to rtmp://192.168.10.17:5085. after an F5 it was corrected to 1936

You may also like...

Leave a Reply

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