Bika LIMS Installation - jean/Bika-LIMS GitHub Wiki
- Introduction
- Linux Installation Steps
- Linux Installer Script
- Upgrading Bika LIMS
- Windows Installation Steps
- OS X Yosemite Installation Steps
- Enable Error Reporting
If you have any issues you should read the following pages carefully:
The most commonly used OS for running Plone and Bika LIMS is Linux, although this process should be fairly similar for all systems on which Plone is supported.
You can paste the following command directly into a terminal:
sudo apt-get install build-essential python-dev git-core libffi-dev \
libpcre3-dev gcc autoconf libtool pkg-config zlib1g-dev libssl-dev \
libexpat1-dev libxslt1.1 gnuplot libpcre3 libcairo2 libpango1.0-0 \
libgdk-pixbuf2.0-0
The version numbers of dependencies are known to be valid in Ubuntu 12.04, 14.04, and Debian Wheezy. If you use a different distribution or version, you may need to find the versions of these packages which are provided with your system.
Download the latest stable release of the Plone Unified Installer from http://plone.org/products/plone/releases and unpack the file. The following installation command will be sufficient for most purposes:
./install.sh --target=/usr/local/Plone --build-python zeo
The user running that command should be able to write to the target directory.Ideally, it should be a user dedicated to running the Bika software.
Note: If you receive an lxml error, you may need to include the --static-lxml
flag in the above command.
In your new Plone
folder, you will see a folder named zeocluster
. Change directory into this folder, and edit buildout.cfg
. Find the section beginning with eggs=
, and add bika.lims
to the existing entries.
eggs =
Plone
Pillow
bika.lims
Save the file, and then run bin/buildout
again. Buildout will download and install all remaining dependencies.
Note: In buildout.cfg
, indentation should be consistent. Mixing tabs and spaces may also cause errors.
Verify that the installer builds successfully. An error will be reported in case of failure, and the exit status will be non-zero (in bash, echo $?
will return the exit status of the previous command).
In case of success, the script output will include a list of found versions like this:
*************** PICKED VERSIONS ****************
[versions]
Babel = 1.3
...
plone.jsonapi.core = 0.4
*************** /PICKED VERSIONS ***************
Note: If any downloads are interrupted, simply run bin/buildout
again. The process will be resumed.
If the buildout finished successfully, an adminPassword.txt
file will be created automatically inside the Plone instance folder. It contains the super-user credentials you'll need to login with.
Note: This user should be used to create the Bika instance, but should not be used subsequently as it is not a regular Bika user. Create a Bika administrator user instead.
To start Plone in debug mode, run this command:
bin/plonectl fg
Note any error messages, and take corrective action if required. If no errors are encountered, you can press Control+C to exit.
Open a browser and go to http://localhost:8080/. Select Add Plone Site, ensure that the Bika LIMS option is checked, then submit the form.
bin/plonectl start
Open a browser and go to your Bika LIMS instance: http://localhost:8080/Plone
If a new release of the LIMS is made available, the following procedure will upgrade your existing installation to use the new packages.
Please read the Releases life-cycle documentation before upgrading your Bika LIMS instance.
Make a full backup of your instance before continuing:
bin/snapshotbackup
Run buildout with the -n
option, to retrieve the latest version of Bika LIMS and its dependencies.
bin/buildout -n
Note: Don't do this in production, as you may get a set of versions that don't work together. For production, you want to explicitly pin down all versions used.
bin/plonectl restart
Start Plone and login to your site as admin. Go to site-setup, and click Add-ons
. Find Bika LIMS in the list of activated addons, and click the "bika.lims" upgrade button.
Download the latest version of the Plone 4.3 Unified Installer from http://plone.org/products/plone/releases. Execute the installer and follow through the steps.
Note: For this guide we will assume the default location: C:\Plone43
Open C:\Plone43\buildout.cfg
in a text editor
Add bika.lims
to the eggs
section:
eggs =
Plone
Pillow
Products.PloneHotfix20130618
bika.lims
Save and close the file, start cmd
as Administrator (Click start, type "cmd
", and press CTRL+SHIFT+ENTER), and then run bin/buildout
. Buildout will download and install all remaining dependencies.
cd C:\Plone43
bin\buildout
Verify successful build from the output of the installer script, which should include a list of found versions like this:
*************** PICKED VERSIONS ****************
[versions]
bika.lims = 3.0
...
pyphen = 0.9.1
*************** /PICKED VERSIONS ***************
Note: The PICKED VERSIONS
block above indicates a successful buildout. If errors appear while buildout is installing dependencies, you can safely ignore them if this message is displayed.
Note: If the download is interrupted, simply run bin/buildout
again. The process will be resumed.
Note: If you see the following error: Error: Couldn't install: cffi 0.8.2 Refer to: Troubleshooting: A) Dependencies
Note: If you see the following error: Error 5: Access is denied Refer to: Troubleshooting: B) Privileges
Navigate to the Plone root directory
cd C:\Plone43
Plone and Windows do not always play well together. Install, Start and bring your newly created instance to the Foreground (this should stop the default Plone 4.3 Service)
bin\instance.exe install
bin\instance.exe start
bin\instance.exe fg
Note: If you see the following error: OSError: cannot load library libcairo.so.2
Refer to: Troubleshooting: A) Dependencies
When you see INFO Zope Ready to handle requests
the server is ready.
Open a browser and go to http://localhost:8080/. Select Add Plone Site, ensure that the Bika LIMS option is checked, then submit the form.
Congratulations!! you have a successful build of Bika LIMS on Windows.
If you are having trouble starting bin\instance.exe fg
as follows:
The program seems already to be running. If you believe not,
check for dangling .pid and .lock files in var/.
You can try the following steps:
- Find the running process id by opening the
.pid
file within your instance'svar/
directory. - Open the Windows Task Manager and stop the running process with the above identifier.
- Delete all
.pid
and.lock
files in your instance'svar/
directory. - Start your instance.
OR
- Run
services.msc
- Search for Plone 4.3
- Try starting or stopping it along with your instance
A) Dependencies You need to install some dependencies manually.
Download and install bika_dependencies(Plone 4.3.1).exe from https://github.com/zylinx/bika.dependencies This fixes the fact that Plone's buildout cannot compile the libraries required by weasyprint. It installs the pre-compiled binaries into System32 and Plone's installation folder instead.
B) Privileges
Open Explorer >> Navigate to C:\
>> Right-Click on the Plone43
directory >> select Properties.
Select the Security Tab >> Click Edit >> Check Full Control Allow for necessary User / Group
Click Apply
We need homebrew to install some dependencies. Open a terminal and install brew
with this command:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
After the installation of brew
we need to install some packages, so:
brew install Caskroom/cask/xquartz
brew install cairo pango gdk-pixbuf libxml2 libffi
Download and install Plone 4.3.3 OS X installer from official the Plone repository (https://launchpad.net/plone/4.3/4.3.3/+download/Plone-4.3.3-64.dmg) because the 4.3.4 doesn’t have the OS X package. Compiling from source gives many errors during compilation, and I want to keep the system as clean as possible. Install Plone with the zeocluster
option, then open a terminal and
cd /Applications/Plone/zeocluster
nano buildout.cfg
replace
extends =
base.cfg
versions.cfg
# http://dist.plone.org/release/4.3.3-xxxxxxx/versions.cfg
# If you change your Plone version, you'll also need to update
# the repository link below.
find-links +=
http://dist.plone.org/release/4.3.3-xxxxx
with
extends =
base.cfg
# versions.cfg
http://dist.plone.org/release/4.3.4/versions.cfg
# If you change your Plone version, you'll also need to update
# the repository link below.
find-links +=
http://dist.plone.org/release/4.3.4
then
./bin/buildout
This will upgrade your Plone to the last stable version, it take some time depending on your connection and system.
Edit buildout.cfg again:
nano buildout.cfg
and replace
eggs =
Plone
Pillow
with
eggs =
Plone
Pillow
bika.health (or bika.lims it depend on your choice)
then
./bin/buildout
If no errors are shown, simply start the zeocluster server and clients:
./bin/plonectl start
Point your browser at http://localhost:8080 and create your Bika site.
If you have problems that are hard to diagnose or reproduce, or if you just want to help us find and fix errors faster, please consider adding the following lines to your buildout's eggs=
section. It's the easiest way to contribute!
eggs =
...
raven
Then, in all [client]
or [instance]
sections, insert this:
event-log-custom =
%import raven.contrib.zope
<logfile>
path ${buildout:directory}/var/client1/event.log
level INFO
max-size 5 MB
old-files 5
</logfile>
<sentry>
dsn http://90723864025d4520b084acee225ddb8a:[email protected]/2
level ERROR
</sentry>
Finally, add raven 4.0.4 into the [versions]
section
[versions]
...
raven = 4.0.4
Run bin/buildout
, and restart Plone.