Personal tools

Difference between revisions of "Installation"

From PhotoVoltaic Logger new generation

Jump to: navigation, search
m (Installation)
m ({{PVLngRepo}})
Line 19: Line 19:
 
* [[Core installation instructions|Installation instructions]] for {{PVLngRepo}}
 
* [[Core installation instructions|Installation instructions]] for {{PVLngRepo}}
 
* [[Scripts installation instructions|Installation instructions]] for {{PVLngScriptsRepo}}
 
* [[Scripts installation instructions|Installation instructions]] for {{PVLngScriptsRepo}}
 
== {{PVLngRepo}} ==
 
 
At 1st find the document root of your web server, usually <tt>/var/www/htdocs</tt>, <tt>/var/htdocs</tt>, <tt>/srv/www/htdocs</tt> ...
 
 
If you want to run only PVLng on your server, just install PVLng direct into the document root.
 
 
If you have more running on your server, setup a own document root for PVLng.
 
 
=== Install with Git ===
 
 
==== Stable ====
 
 
If your system have Git installed, it will be simplest way to clone the Github repositories from GitHub.
 
 
Go into the directory, you will PVLng install to and execute
 
 
# wget -qO - <nowiki>https://raw.github.com/KKoPV/PVLng/master/install</nowiki> | bash
 
 
The installer will ask for your MySQL credentials, install the basic SQL script and create a basic configuration file with this credentials.
 
 
==== Development ====
 
 
If you are interested in the latest development version, you can also direct install the development branch with
 
 
# wget -qO - <nowiki>https://raw.github.com/KKoPV/PVLng/develop/install</nowiki> | bash
 
 
Open afterwards your installation in your browser to finalize the setup.
 
 
=== Manual installation ===
 
 
Just download the archive and extract it direct on your server.
 
 
# wget -O master.zip <nowiki>https://github.com/KKoPV/PVLng/zipball/master</nowiki>
 
# unzip master.zip
 
# mv PVLng-master/* .
 
# rm -r master.zip PVLng-master
 
 
=== Database setup ===
 
 
Create a database for PVLng if you want. (This is ''recommend'', but not required)
 
 
All PVLng specific tables have a <tt>pvlng_</tt> as prefix.
 
 
Import the SQL file <tt>sql/pvlng.sql</tt> into your database.
 
 
==== From command line ====
 
 
# mysql -u[username] -p[password] [database] <sql/pvlng.sql
 
 
This will install all the required tables, a predefined set of channel types, a view and some functions.
 
 
==== Via Web frontend ====
 
 
PVLng have Adminer installed by default.
 
 
<blockquote>Adminer (formerly phpMinAdmin) is a full-featured database management tool written in PHP. Conversely to phpMyAdmin, it consist of a single file ready to deploy to the target server.
 
<cite>http://www.adminer.org</cite></blockquote>
 
 
<nowiki>http://your.domain.here/adminer/</nowiki>
 
 
Choose <tt>SQL-Query > File upload > Execute</tt>
 
 
=== Configuration ===
 
 
Prepare the configuration file:
 
 
# cp config/config.php.dist config/config.php
 
 
Fill in <tt>config.php</tt> at least your database credentials.
 
 
=== Finalize ===
 
 
Open afterwards your installation in your browser to finalize the setup.
 
  
 
== {{PVLngScriptsRepo}} ==
 
== {{PVLngScriptsRepo}} ==

Revision as of 11:14, 7 April 2014

Hardware requirements

  • A server, which fits the software requirements :-)
  • Some sensors, like 1-Wire sensors, watt meters
  • Solar inverter which supports either

Software requirements

  • Operating system with support of periodic job scheduling (for example *nix with cron)
  • MySQL ≥ 5.1.* (supports table partitions, views, trigger, functions, procedures and events)
  • PHP ≥ 5.3.*
  • Web server with PHP support, tested with Apache, Litespeed and Nginx (recommended)

Installation

The system is devided into 2 repositories, the PVLng core repo with web frontend and API and the PVLng-Scripts repo with the data aquisition scripts.

PVLng-scripts repository

Install with Git by cloning

# git clone https://github.com/KKoPV/PVLng-scripts.git

or download an archive

# wget -O master.zip https://github.com/KKoPV/PVLng-scripts/zipball/master
# unzip master.zip
# mv PVLng-scripts-master/* .
# rm -r master.zip PVLng-scripts-master

Afterwards prepare the configuration file with

# cp PVLng.conf.dist PVLng.conf

Fill in at least your API key, you can find it on the information page.

There are some examples in the Category:Scripts.