(→Install and configure database) |
|||
Line 42: | Line 42: | ||
make | make | ||
sudo make install | sudo make install | ||
+ | |||
+ | ==Database== | ||
+ | ===Creating database before first run=== | ||
+ | Download database file at: http://wiki.enymind.fi/demo/chronogrid_live.sql | ||
===Install and configure database=== | ===Install and configure database=== | ||
Line 64: | Line 68: | ||
FLUSH PRIVILEGES; | FLUSH PRIVILEGES; | ||
− | + | ==Running live web server== | |
Run command at terminal to start as server: | Run command at terminal to start as server: | ||
./chromolive_1.0.xxxx_amd64.bin -m server -c config.cfg | ./chromolive_1.0.xxxx_amd64.bin -m server -c config.cfg | ||
Line 72: | Line 76: | ||
Then navigate browser to: http://localhost:8080/live/index.php | Then navigate browser to: http://localhost:8080/live/index.php | ||
− | |||
− | |||
− | |||
− | |||
==Configuring service== | ==Configuring service== |
Revision as of 08:26, 21 March 2013
Contents
Running service
Currently supports only amd64 and compatible architecture systems.
Prerequisites (Ubuntu 12.04 LTS Server)
- libtcmalloc-minimal0
- libboost-system1.46.1
- libboost-program-options1.46.1
- libboost-filesystem1.46.1
- libtbb2
- libonig2
- libmcrypt4
- libc-client2007e
- memcached
- libcloog-ppl0
- libicu48
- libcap2
- libgd2-xpm
- build-essential
sudo apt-get install libtcmalloc-minimal0 libboost-system1.46.1 libboost-program-options1.46.1 memcached sudo apt-get install libboost-filesystem1.46.1 libtbb2 libonig2 libmcrypt4 libc-client2007e libcloog-ppl0 sudo apt-get install libicu48 libcap2 libgd2-xpm build-essential
See complete list at ChronoLive Runtime ldd
Install libmemcached
wget http://launchpad.net/libmemcached/1.0/0.49/+download/libmemcached-0.49.tar.gz tar -xzvf libmemcached-0.49.tar.gz cd libmemcached-0.49 ./configure make sudo make install sudo cp libmemcached/.libs/libmemcached.so /lib/libmemcached.so.7
Install libevent
wget http://www.monkey.org/~provos/libevent-1.4.14b-stable.tar.gz tar -xzvf libevent-1.4.14b-stable.tar.gz cd libevent-1.4.14b-stable wget https://raw.github.com/facebook/hiphop-php/pre-hhvm/src/third_party/libevent-1.4.14.fb-changes.diff patch -p1 < libevent-1.4.14.fb-changes.diff ./configure make sudo make install
Database
Creating database before first run
Download database file at: http://wiki.enymind.fi/demo/chronogrid_live.sql
Install and configure database
sudo apt-get install mysql-server
During the installation it will ask the root user's password. Do not use root user with ChronoLive.
Create another user for ChronoLive.
After installation start mysql CLI with command:
mysql -u root -p
After login create new database:
CREATE DATABASE chronogrid_live;
And create new user:
CREATE USER 'chronolive'@'localhost' IDENTIFIED BY 'yourpassword'; GRANT ALL PRIVILEGES ON chronogrid_live.* TO 'chronolive'@'localhost'; FLUSH PRIVILEGES;
Running live web server
Run command at terminal to start as server:
./chromolive_1.0.xxxx_amd64.bin -m server -c config.cfg
Or as daemon:
./chromolive_1.0.xxxx_amd64.bin -m daemon -c config.cfg
Then navigate browser to: http://localhost:8080/live/index.php
Configuring service
Read more at: https://github.com/facebook/hiphop-php/wiki/Runtime-options
Example configuration file (config.cfg)
ServerVariables { dbhostname = localhost dbusername = chronogrid_live dbpassword = password123 dbdatabase = chronogrid_live uploaddir = /tmp logdir = /var/log/hhvm } Server { Port = 8080 DefaultDocument = index.php } AdminServer { Port = 8088 ThreadCount = 1 Password = gj34Us } Log { Level = Error UseLogFile = true File = /var/log/hhvm/error.log Access { * { File = /var/log/hhvm/access.log Format = %h %l %u %t \"%r\" %>s %b } } } StaticFile { FilesMatch { * { pattern = .*\.(dll|exe) headers { * = Content-Disposition: attachment } } } Extensions { css = text/css gif = image/gif html = text/html jpg = image/jpeg js = text/javascript old = text/javascript png = image/png txt = text/plain } }