# Xibo windows server 2012

**URL:** https://community.xibo.org.uk/t/xibo-windows-server-2012/18791
**Category:** Get Help
**Created:** [May 9, 2019, 2:20pm UTC](https://community.xibo.org.uk/t/xibo-windows-server-2012/18791 "2019-05-09T14:20:51Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![Skidoo](https://community.xibo.org.uk/letter_avatar_proxy/v4/letter/s/bc8723/32.png) [@Skidoo](https://community.xibo.org.uk/u/Skidoo)
#### Post date: [May 9, 2019, 2:45pm UTC](https://community.xibo.org.uk/t/xibo-windows-server-2012/18791/3 "2019-05-09T14:45:10Z")

</div>

My notes:

XIBO 2.0 Manual Software Installation Guide  
This guide will explain every step for installing Xibo 2.0.x on IIS 8 on WINDOWS SERVER 2012 r2 Standard 64Bit. Reference Xibo document from site: [https://xibo.org.uk/docs/setup/xibo-on-a-web-server](https://xibo.org.uk/docs/setup/xibo-on-a-web-server)  
Xibo Server requirements:  
• MySQL 5.6 or 5.7 (only)  
• A web server (iis)  
• PHP 5.6+ (Recommend PHP7.2)  
• PHP-CLI 5.6+ (Recommend PHP7.2)  
• PHP PHAR support  
• ZeroMQ bindings for PHP  
• URL Rewriting  
• Virtual Hosts or dedicated web server (modify DocumentRoot)  
• CRON/Scheduled Tasks [https://xibo.org.uk/docs/setup/xtr-routine-tasks](https://xibo.org.uk/docs/setup/xtr-routine-tasks)  
Confirm that all required server Settings and Features are enabled

If you were using IIS 10, the PHP manager will not recognize the IIS 10 as the IIS 8 and earlier is the only PHP supported version. You will need to use the one compiled from this link.

[https://onedrive.live.com/redir?resid=47DF1DC3942D52B3!2357&authkey=!APYPwnsyjJm4zDw&ithint=file%2Cmsi](https://onedrive.live.com/redir?resid=47DF1DC3942D52B3!2357&authkey=!APYPwnsyjJm4zDw&ithint=file%2cmsi)

Install Microsoft Web Platform Installer from Windows  
[https://www.microsoft.com/web/downloads/platform.aspx](https://www.microsoft.com/web/downloads/platform.aspx)  
Download and install x64 installer  
After installation is complete - Launch the new application  
Click on the “Products” tab  
Add the following Products:  
URL Rewrite 2.1  
MySQL Windows 5.1  
MySQL Connector/Net  
PHP 5.6  
Windows Cache Extension 2.0 for PHP 7.2 in IIS Express (may not need this)  
.NET 4.5 for Windows 8  
.NET 3.5 for Windows 8  
PHP Manager for IIS (only works if IIS is not version 10)

Click Finish & Exit

MYSQL:

Mysql 5.6 or 5.7 download from community and install  
[https://dev.mysql.com/downloads/file/?id=467267497](https://dev.mysql.com/downloads/file/?id=467267497)  
I setup the SQL server as a Server type role  
Root account password is: Xiborootpassword  
Important: CMS Installation fails against MySQL 5.7  
Edit the “my-default.ini” file located in the mysql installation folder  
Remove “STRICT\_TRANS\_TABLES” from sql-mode  
Or do this if error occurs during Xibo installation try changing it to:  
sql-mode = “NO\_AUTO\_CREATE\_USER,NO\_ENGINE\_SUBSTITUTION”

Launch “Files and Folders” and perform the following:

In this Manual web site is: Default Web Site you can use which you want in IIS  
Extract all Xibo CMS Files to C:\PHP\_FILES - And Give Permission for IUSR and IIS\_IUSR

IMPORTANT:  
Apply the bug fixes manually (or wait for release Xibo CMS 2.0.2) which I did and it worked for fresh installation and migration (with some additional minor changes).Ignore the docker file as it won’t be used in this type of Windows installation.

> <https://github.com/xibosignage/xibo-cms/commit/e3a1c93e03a598e18415da0042da356b1d9fdc14>

Failure to make these changes may result in having this error during the final installation:

SQLSTATE[220001] String data, right truncated:

Create directory for your Library Files C:\XIBO\_LIB - And Give Permission for IUSR and IIS\_IUSR

IIS Settings  
Launch IIS Manager  
Default Web Site -\> Basic Settings-Change Physical path to your XiboFiles folder in this manual C:\PHP\_FILES\web

Default Web Site-\> Request Filtering  
Edit Feature Settings…  
Set Maximum Query String (Bytes) to 4096 (otherwise you will get datatables.ajax error)  
Set Maximum allowed content length (Bytes) (3000000 to 30000000) (Add one more zero)

Default Web Site-\>URLRewrite  
Import Rules  
Browse the Configuration files and import the .htaccess file in C:\PHP\_FILES\web  
Click “Import”  
(remove the problem line and import by placing a “#” comment in the front of the code)  
Click on “Apply” to make changes

Default Web Site-\>MimeTypes -\> Add (.woff = font/x-woff ) _ **If missing** _  
Default Web Site-\> MimeTypes -\> Add (.woff2 = font/woff2 ) _ **If missing** _

Default Web Site-\>Default Document  
Move to the top of the list “index.php”

Default Web Site-\>PHP Manager-Select Checkbox If Not optimal PHP configuration detected-View recommendations  
Default document \<===== \*\*\* This should not be an issue if step performed above is done \*\*\*  
monitorChangesTo (otherwise you will get HTTP 500 error when start install.php)

Default Web Site-\>Handler Mappings  
Edit PHP\_via\_FastCGI  
Click on “Request Restrictions”  
Select Verbs tab and choose “All verbs”. (Otherwise you will get HTTP 405 error when try to save a setting in portal)  
IMPORTANT: You need the double quotes for start and end of the line of php.exe path, othervise windows won’t let you save the setting for Handler Mappings for Php)

Default Web Site-\>PHP Manager  
Edit Configuration file: PHP.ini (DefaultWebSite-Php Manager-Php.ini)

Add line in [PHP] section:  
extension=php\_fileinfo.dll

Change other lines as below in PHP.ini;  
post\_max\_size=200M  
upload\_max\_filesize=200M  
max\_execution\_time=120

SMTP = [yourdomain.com](http://yourdomain.com)  
smtp\_port = 25  
sendmail\_from =xibo@yourdomain.com  
mail.add\_x\_header = On

Now save the file and close notepad

Skip this SMTP setup as not required so skip down to ZeroMq section

Sending Mail in PHP (If your environment doesn’t have a SMTP server)  
Xibo uses PHPMail to connect your local SMTP Server Application but PHPMail cannot send directy from itself. You need a 3rd party smtp server for sending mail from php.  
I am using sendmail.exe  
Download and extract all sendmail files to a folder ex.C:\Sendmail

modify files as below;  
sendmail.ini (samples for office 365mail setting, use your smtp provider setting)

smtp\_server=[smtp.office365.com](http://smtp.office365.com)  
smtp\_port=25  
smtp\_ssl=tls  
default\_domain=[yourdomain.com](http://yourdomain.com)  
error\_logfile=error.log (it creates a text file in sendmail folder to track errors.)  
debug\_logfile=debug.log (it creates a text file in sendmail folder to track errors.)  
[auth\_username=your@domain.com](mailto:auth_username=your@domain.com)  
auth\_password=password of your email

You also need to modify PHP.ini for your mail settings;  
PHP.ini  
[mail function]  
sendmail\_path =“C:\sendmail\sendmail.exe”

ZeroMq  
No Need to install Any Seperate Server for Zero Mq

Php Xmr Settings  
Download zero mq package from [php.net](http://php.net) 91 (this is PHP 5.6 and must be x86 even in x64 Windows)

[https://windows.php.net/downloads/pecl/releases/zmq/1.1.3/](https://windows.php.net/downloads/pecl/releases/zmq/1.1.3/)

[http://windows.php.net/downloads/pecl/releases/zmq/1.1.2/php\_zmq-1.1.2-5.6-nts-vc11-x86.zip](http://windows.php.net/downloads/pecl/releases/zmq/1.1.2/php_zmq-1.1.2-5.6-nts-vc11-x86.zip) 387

copy php\_zmq.dll to your ext folder in PHP installation (ex. C:\Program Files (x86)\PHP\v5.6\ext)  
copy libzmq.dll to your PHP installation folder (ex. C:\Program Files (x86)\PHP\v5.6)

If your package is wrong you could get error. You can check from Windows Event Viewer-Application Logs (PHP Warning: PHP Startup: Unable to load dynamic library ‘C:\Program Files (x86)\PHP\v5.6\ext\php\_zmq.dll’ - The specified module could not be found.)

Modify php.ini

[PHP]  
extension=php\_zmq.dll

Xibo Cms Side

Copy from C:\PHP\_FILES\vendor\xibosignage\xibo-xmr  
or Create new file as the below content  
config.json content:

{  
“listenOn”: “tcp://127.0.0.1:50001”,  
“pubOn”: [“tcp://yourip:9505”, “tcp://yourip:50002”],  
“debug”: true  
}

copy the file in to C:\PHP\_FILES\vendor\bin folder.  
in same folder open command prompt (Pressing Shift and right mouse key and select Open Command prompt from here)

run the command: iisreset  
run the command: php xmr.phar  
you will get debug console with information on xmr events  
if everything is correct you will get a screen like this

C:\PHP\_FILES\vendor\bin\>php xmr.phar  
[2017-05-04 22:13:19] xmr.INFO: Starting up - listening for CMS on tcp://127.0.0.1:50001. [] []  
[2017-05-04 22:13:19] xmr.INFO: Bind to tcp://yourip:9505 for Publish. [] []  
[2017-05-04 22:13:19] xmr.INFO: Bind to tcp://yourip:50002 for Publish. [] []  
[2017-05-04 22:13:49] xmr.DEBUG: Heartbeat… [] []  
[2017-05-04 22:14:19] xmr.DEBUG: Heartbeat… [] []  
[2017-05-04 22:14:49] xmr.DEBUG: Heartbeat… [] []  
[2017-05-04 22:15:19] xmr.DEBUG: Heartbeat… [] []  
Note: Dont forget to run “php xmr.phar” command when you restart your server

CMS Settings for Zeromq  
Settings-Displays-XMR Private Address: tcp://127.0.0.1:50001  
Settings-Displays-XMR Public Address: tcp://x.x.x.x:9505  
Displays-Display Setting for your display group-Edit-XMR Public Address:tcp://x.x.x.x:9505  
After players get those settings you will see XMR Status: Connected (tcp://x.x.x.x:9505, last activity 04.05.2017 12:23:22) It will update every 30 seconds

FOR UPGRADING EXISTING XIBO:

(In 2.0.0 or later upgrading the CMS can be done by your web server administrator from the terminal. In versions earlier than 2.0.0 upgrading is completed in a wizard and can be done by the CMS administrator).  
Please check the release notes for the version you want to upgrade to before starting the upgrade.  
Steps  
You should always take a backup before upgrading your CMS Installation.  
• If upgrading to 1.8 series, ensure your environment meets the requirements for installation. If it does not then correct that before continuing.  
• Backup settings.php from your installation (found in web/settings.php )  
• Manually take a backup of your database  
• Replace your existing installation with the new version from the tar.gz or zip file. Do not copy over the top.  
• Add security access to new installation files for users IUSR & IIS\_IUSRS (exclude “Full Control” &“Special Access”)  
• Removing STRICT\_TRANS\_TABLES from sql-mode  
• Browse to [http://localhost/](http://localhost/) as confirm all setting pass  
If any issues are encountered - resolve them before proceeding.  
• Replace your backup settings.php file in your Xibo installation directory  
• Close browser  
• Open a command terminal  
• cd into your installation folder C:\PHP\_FILES  
• Run this command: php vendor\bin\phinx migrate -c phinx.php

If there isn’t any verbose conversion data showing do this.  
I was successful with following these steps. [Upgrading to xibo v2, unable to do database migrations](https://community.xibo.org.uk/t/upgrading-to-xibo-v2-unable-to-do-database-migrations/18074)  
Here is how:

1. Copy folder “app” from “vendor\robmorgan\phinx” to “vendor\bin”
2. Copy folder “src” from “vendor\robmorgan\phinx” to “vendor\bin\app”
3. In folder “vendor\bin” using Notepad edit file “phinx”:  
change line  
$app = require DIR . ‘/…/app/phinx.php’; to be this $app = require DIR . ‘/app/phinx.php’;
4. In folder “vendor\bin\app” using Notepad edit file “phinx.php”:  
change line  
$autoloader = require DIR . ‘/…/src/composer\_autoloader.php’; to be this $autoloader = require DIR . ‘/src/composer\_autoloader.php’;
5. change directory to C:\PHP\_FILES\

Run this command: php vendor\bin\phinx migrate -c phinx.php  
Couple of seconds later, migration is complete and I can login to my Xibo.  
Now Xibo 2.0.x is running with PHP 5.6

FOR FRESH INSTALLATION

launch browser and connect to your ip address: [http://localhost](http://localhost)

confirm all checks are good and start installation

---

_[View the full topic](https://community.xibo.org.uk/t/xibo-windows-server-2012/18791)._
