HVAC Wiki

All things related to HVAC

User Tools

Site Tools


suppliers:hvac.io:vigilia:installation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
suppliers:hvac.io:vigilia:installation [2018/06/08 18:45] – [Vigilia Server Installation] frozenlocksuppliers:hvac.io:vigilia:installation [2020/07/22 15:01] – old revision restored (2015/07/30 01:52) 95.91.41.38
Line 1: Line 1:
-====== Vigilia Server Installation ======+====== Installation ======
  
-//**Requires a Viglia Server licence**. To use the official HVAC.IO servers instead, jump to [[.:recording]].//+For self-hosted version only. To use the HVAC.IO servers instead, [[https://hvac.io/registration|create an account]] and jump to [[#Loggers]].
  
 The installation is separated in 3 main components: The installation is separated in 3 main components:
Line 7: Line 7:
   * [[#Database]]   * [[#Database]]
   * [[#Vigilia Server]]   * [[#Vigilia Server]]
-  * [[.:recording#client_side_loggers|Loggers]]+  * [[#Loggers]]
  
 They can all be installed on the same machine, or on separate servers and devices, depending on your network architecture. They can all be installed on the same machine, or on separate servers and devices, depending on your network architecture.
  
- 
-Once this is done, you might want to take a look at [[#Adding Vigilia as a Service]] 
 ===== Database ===== ===== Database =====
-For the time being, Vigilia only supports TokuMX.+For the time being, Vigilia only supports [[http://www.tokutek.com/tokumx-for-mongodb/|TokuMX]].
 It is a fork of MongoDB, which features mind boggling increase in performance and reduction in the database size. It is a fork of MongoDB, which features mind boggling increase in performance and reduction in the database size.
 (The choice was not made lightly; we tried many databases before settling with this one.) (The choice was not made lightly; we tried many databases before settling with this one.)
  
  
-TokuMX is supported on **64-bit Linux only**, but virtual image should work too.+TokuMX is supported on **64-bit Linux only**, but virtual image should work too.
  
 We recommend to use SSD drives, as their increased speed directly translate in how fast Vigilia will react. We recommend to use SSD drives, as their increased speed directly translate in how fast Vigilia will react.
 250 to 500 Go should be plenty of space to store many years of data for networks composed of hundreds of thousands of objects. (Tokumx compression is really useful for this!) 250 to 500 Go should be plenty of space to store many years of data for networks composed of hundreds of thousands of objects. (Tokumx compression is really useful for this!)
  
-To install TokuMX, add the following [[https://launchpad.net/~exponea/+archive/ubuntu/tokumx|PPA]] and enter the following in your shell : 
  
-<code> sudo apt install tokumx-enterprise </code>+Download and install by following the instructions on this [[http://www.tokutek.com/tokumx-for-mongodb/download-community/|page]].
  
-(Alternatively, you can try to follow the official instructions on this [[https://www.percona.com/doc/percona-tokumx/installation.html|page]].) 
- 
-Once the database is installed, make sure everything works as intended by running the command 
-**mongo** in the shell. 
- 
-The command should be recognized AND it should connect successfully.  
- 
-{{:suppliers:hvac.io:vigilia:installation:tokumx-shell.png?|}} 
- 
-You can stop the process by pressing Ctrl-C in the shell. 
 ===== Vigilia Server ===== ===== Vigilia Server =====
  
 For maximum speed, we recommend you install the Vigilia server on the same machine as the database. For maximum speed, we recommend you install the Vigilia server on the same machine as the database.
  
-Vigilia server runs on [[http://www.java.com|Java]], meaning it can work on Linux, Windows and Mac.+Vigilia server runs on [[www.java.com|Java]], meaning it can work on Linux, Windows and Mac.
  
  
Line 66: Line 53:
  
 <code> java -jar vigilia-server.jar <port number> </code>  <code> java -jar vigilia-server.jar <port number> </code> 
-(where <port number> is the port you want to use. If you don't know which one to take, use 47900.) +(where <port number> is the port you want to use.)
- +
-After a few seconds, the server should be up and running.  +
-You can now take your browser and go to: +
-<code> http://localhost:<port number> </code> +
- +
-=== Create Admin Account === +
- +
-If Vigilia is able to connect to the database, you will be invited to create an account. +
-The first account created will have the administrator rights. +
- +
-=== Load License === +
- +
-Now that you have the administrator rights, you should load the license files. +
-On the upper right, you should see your username. Click on it and go to **Server Administration**. Then click on **License**. Select the license files and click upload. +
- +
-You should see something similar to this: +
- +
-{{:suppliers:hvac.io:vigilia:installation:license.png|}} +
- +
-=== Configure Service (optional) === +
- +
-If you want the application to start automatically when your server boot up, you should make sure to [[#Adding Vigilia as a Service|create a service]] (shown below), or configure your web server (like Tomcat) to use vigilia-server.jar. +
- +
-=== Good to Go === +
- +
-Once your Vigilia server is up and running, you can follow the steps to [[suppliers:hvac.io:vigilia:recording|record a BACnet network]]. +
- +
- +
-===== Adding Vigilia as a Service ===== +
-==== (Upstart Users) ==== +
- +
- +
-You might want to make sure the Vigilia server always starts as soon as the server boots, or that it restores itself in case of a crash. +
- +
-For this, you'll have to add Vigilia as a service. +
- +
-Start by creating a file named "**vigilia.conf**"+
- +
-Open it and paste the following: +
- +
- +
-<code bash vigilia.conf> +
- +
-description "Vigilia Server" +
-author "Christian Fortin, HVAC.IO" +
- +
-start on runlevel [2345] +
-stop on runlevel [!2345] +
- +
- +
-#Respawn the process if it crashes +
-#If it respawns more than 10 times in 60 seconds stop +
-respawn +
-respawn limit 10 60 +
- +
-expect fork +
- +
-#replace PATH-TO-THE-JAR with something like /home/hvacio/vigilia +
-#replace PORT with the desired port number +
-script +
-    cd PATH-TO-THE-JAR +
-    java -jar vigilia-server.jar PORT & +
-end script +
- +
-</code> +
- +
-Now, once you replaced PATH-TO-THE-JAR and PORT with their correct values, move the file to /etc/init: +
- +
-<code> +
-sudo mv vigilia.conf /etc/init/vigilia.conf +
-</code> +
- +
-That's it! +
-Now reboot and Vigilia should start automatically. +
- +
-To get more info about Upstart and services, see http://upstart.ubuntu.com/cookbook/+
- +
- +
-===== Troubleshooting ===== +
- +
-==== Database Crash ==== +
- +
-If you database is becoming quite large (thousands of files in the dbpath), it's possible that your OS is going to refuse opening that much files simultaneously. +
- +
-In Linux, you can change the number of allowed files by editing the file ''/etc/security/limits.conf'' and adding the following lines :+
  
-<code> +Obviously, if you want the application to start automatically when your server boot up, you should make sure to create a service, or configure your web server (like Tomcat) to use vigilia-server.jar.
-tokumx soft nofile 1000000 +
-tokumx hard nofile 1000000 +
-</code>+
  
  
 +===== Loggers =====
suppliers/hvac.io/vigilia/installation.txt · Last modified: 2020/10/04 01:53 by 173.249.2.13