Installation Error

Hi there,

I am trying to Setup Senaite on Ubuntu 18.04 as recommended by the installation guide (https://www.senaite.com/docs/installation.html). Tried a few times, learned a lot about Linux but failed here:

(senaite) senaite@yannik-VirtualBox:~/senaitelims$ which pip
/home/senaite/miniconda2/envs/senaite/bin/pip
(senaite) senaite@yannik-VirtualBox:~/senaitelims$ pip install -r requirements.txt
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
WARNING: The directory '/home/senaite/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
WARNING: The directory '/home/senaite/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
ERROR: Could not install packages due to an EnvironmentError: [Errno 13] Keine Berechtigung: '/home/senaite/.cache/pip/wheels/01/70/1e/b21a7af112e7f7348217c14e7ebb17a887ecea424bd928fc79'
Consider using the `--user` option or check the permissions.

(senaite) senaite@yannik-VirtualBox:~/senaitelims$ sudo pip install -r requirements.txt
sudo: pip: Befehl nicht gefunden
(senaite) senaite@yannik-VirtualBox:~/senaitelims$ 

Do you have any suggestions on this? Thanks a lot in advance!

Best, E.

Hi @Eoneath,

A warm welcome to the Senaite Community.

You are a getting a permissions error.

Make sure that your user has access to the directory or run pip with the --user option: pip install --user -r requirements.txt

Hi Ronald,

thanks for your reply! I know it´s a permissions error, but don´t know how to solve it. I just followed the path suggested by the guide. How can i set these permissions?

Does not work with the Ubuntu 18.04 Setup.

Best and thanks in advance, E

I already tried to give permissions to senaite with first with chmod and then with visudo setting senaite as a root…both failed

sudo pip does also not work, says there is no pip

You could either fix your permissions or ownership in the directory tree
/home/senaite/.cache/pip/wheels
or give the full path to pip, e.g.

sudo /home/senaite/miniconda2/envs/senaite/bin/pip install -r …

My suggestion would be to install Plone 4.3.19 from the unified installer
and make sure that you can get that to run first before adding the lims eggs

Thanks a lot for your reply. Changing permissions/ownership with chmod/chown failed, as well as sudo /home/senaite/miniconda2/envs/senaite/bin/pip install -r …

I am wondering, why I fail. I just follow the quide, using suggested version of ubuntu, and following all steps without errors so far…

I try to set it up without the lims eggs…

Plone can be installed on the unified installer but not started using /home/senaite/zinstance/bin/plonectl start i can also not see the zinstance folder…
Just following the guide all the steps. So what might be the problem?

You need sudo to look at those - Run the client in foreground to see the errors: Eg
sudo ${TARGET}/zeocluster/bin/plonectl client1 fg

Thanks for your reply. If I take your commands as above or use commands below

$ sudo /home/senaite/plone/zinstance/bin/plonectl start
sudo: /home/senaite/plone/zinstance/bin/plonectl: Befehl nicht gefunden

It says sudo: command not found.

Maybe I just install plone 4.3.1.9 as described in it´s own documentation, not following the one from senaite. Shouldn´t the guide work like a simple to follow cooking book?

Firstly you should install sudo fron the package manager if not already there. For
security reasons it runs and builds plone under a separate user.

I managed to run Plone using the guide here (and used settings discribed in senaite guide): https://docs.plone.org/4/en/manage/installing/installation.html

then I followed all the steps in the senaite guide. So installed the system dependencies and modified the buildout.cfg as described. Also added succesfully the requirements.

After executing $ PYTHONHTTPSVERIFY=0 buildout some packages fail to download and I cannot run bin/instance fg .
What could be the cause?
Edit [that´s the error while executing command]:

(senaite) senaite@yannik-VirtualBox:~/senaitelims$ PYTHONHTTPSVERIFY=0 buildout
Installing instance.
Download error on http://dist.plone.org: [Errno -2] Name or service not known -- Some packages may not be found!
Download error on http://download.zope.org/distribution/: timed out -- Some packages may not be found!
Download error on http://dist.plone.org/release/4.3.19: [Errno 101] Network is unreachable -- Some packages may not be found!
Getting distribution for 'z3c.pt>=2.2'.
Got z3c.pt 3.3.0.
Getting distribution for 'sourcecodegen>=0.6.14'.
Got sourcecodegen 0.6.14.
Getting distribution for 'plone.formwidget.contenttree==1.1.0'.
Got plone.formwidget.contenttree 1.1.0.
Getting distribution for 'z3c.relationfield==0.6.3'.
warning: no previously-included files matching '*.pyc' found anywhere in distribution
Got z3c.relationfield 0.6.3.
Getting distribution for 'plone.app.intid==1.0.5'.
warning: no previously-included files matching '*.pyc' found anywhere in distribution
Got plone.app.intid 1.0.5.
Getting distribution for 'five.intid==1.0.3'.
Got five.intid 1.0.3.
Getting distribution for 'zope.intid==3.7.2'.
Got zope.intid 3.7.2.
Getting distribution for 'zopyx.txng3.core'.
zip_safe flag not set; analyzing archive contents...
zopyx.txng3.core.normalization: module references __file__
zopyx.txng3.core.stopwords: module references __file__
zopyx.txng3.core.thesaurus: module references __file__
zopyx.txng3.core.converters.doc: module references __file__
zopyx.txng3.core.parsers.english: module references __file__
zopyx.txng3.core.parsers.experimental.pyparsing: module MAY be using inspect.stack
zopyx.txng3.core.tests.mock: module references __file__
zopyx.txng3.core.tests.testConverters: module references __file__
zopyx.txng3.core.tests.testIndex: module references __file__
zopyx.txng3.core.tests.testThesaurus: module references __file__
Got zopyx.txng3.core 3.6.2.
Getting distribution for 'dicttoxml'.
zip_safe flag not set; analyzing archive contents...
Got dicttoxml 1.7.4.
Getting distribution for 'werkzeug'.
Got Werkzeug 1.0.1.
Download error on https://pypi.python.org/simple/decorator/: [Errno -2] Name or service not known -- Some packages may not be found!
Couldn't find index page for 'decorator' (maybe misspelled?)
Getting distribution for 'decorator==3.4.2'.
While:
  Installing instance.
  Getting distribution for 'decorator==3.4.2'.
Error: Couldn't find a distribution for 'decorator==3.4.2'.

Download errors normally mean some Internet problem

After downloading several times it worked out! Now I can install Senaite. Thanks a lot for your great support!

1 Like

Hi, me again returning to Senaite…
On the Ubuntu Server I set up it says when entering $ which PIP I get as an result /home/senaite/miniconda2/bin/pip (and not: /home/senaite/miniconda2/envs/senaite/bin/pip what it says in the guide) I can workaround this with sudo /home/senaite/miniconda2/envs/senaite/bin/pip install -r

but then I fail with the $ which buildout cause it says for me /home/senaite/miniconda2/bin/buildout

How can I change this? Or change the standard pip?

Best

E

hello inus, i hope you are well,
I ran into a bit of trouble here when installing, Could you please look at this and help if you can? i am running it on ubuntu 18,0,4 GUI

(base) senaite@ubuntu:~/senaitelims$ PYTHONHTTPSVERIFY=0 buildout
Uninstalling unifiedinstaller.
Uninstalling zopepy.
Uninstalling backup.
Uninstalling repozo.
Uninstalling instance.
Installing instance.
Getting distribution for 'senaite.lims'.
Got senaite.lims 2.2.0.
Getting distribution for 'simplejson==2.5.2'.
In file included from /home/senaite/miniconda2/include/python2.7/Python.h:83,
                 from simplejson/_speedups.c:1:
simplejson/_speedups.c: In function ‘encoder_listencode_obj’:
/home/senaite/miniconda2/include/python2.7/object.h:439:18: warning: comparison of distinct pointer types lacks a cast
  439 |     (Py_TYPE(ob) == (tp) || PyType_IsSubtype(Py_TYPE(ob), (tp)))
      |                  ^~
simplejson/_speedups.c:2263:36: note: in expansion of macro ‘PyObject_TypeCheck’
 2263 |         else if (s->use_decimal && PyObject_TypeCheck(obj, s->Decimal)) {
      |                                    ^~~~~~~~~~~~~~~~~~
simplejson/_speedups.c:2263:61: warning: passing argument 2 of ‘PyType_IsSubtype’ from incompatible pointer type [-Wincompatible-pointer-types]
 2263 |         else if (s->use_decimal && PyObject_TypeCheck(obj, s->Decimal)) {
/home/senaite/miniconda2/include/python2.7/object.h:439:60: note: in definition of macro ‘PyObject_TypeCheck’
  439 |     (Py_TYPE(ob) == (tp) || PyType_IsSubtype(Py_TYPE(ob), (tp)))
      |                                                            ^~
/home/senaite/miniconda2/include/python2.7/object.h:437:50: note: expected ‘PyTypeObject *’ {aka ‘struct _typeobject *’} but argument is of type ‘PyObject *’ {aka ‘struct _object *’}
  437 | PyAPI_FUNC(int) PyType_IsSubtype(PyTypeObject *, PyTypeObject *);
      |                                                  ^~~~~~~~~~~~~~
zip_safe flag not set; analyzing archive contents...
simplejson.tests.__init__: module references __file__
Got simplejson 2.5.2.
Getting distribution for 'senaite.jsonapi==2.2.0'.
Got senaite.jsonapi 2.2.0.
Getting distribution for 'senaite.impress==2.2.0'.
Got senaite.impress 2.2.0.
Getting distribution for 'senaite.app.supermodel==2.2.0'.
Got senaite.app.supermodel 2.2.0.
Getting distribution for 'senaite.app.spotlight==2.2.0'.
Got senaite.app.spotlight 2.2.0.
Getting distribution for 'senaite.app.listing==2.2.0'.
warning: no files found matching '*.rst'
warning: no previously-included files matching '*' found under directory 'src/senaite/app/listing/tests'
warning: no previously-included files matching '*' found under directory 'webpack'
warning: no previously-included files matching '*.pyc' found under directory 'src'
Got senaite.app.listing 2.2.0.
Getting distribution for 'senaite.core==2.2.0'.
warning: no previously-included files matching '*' found under directory 'docs'
warning: no previously-included files matching '*' found under directory 'src/senaite/app/listing'
warning: no previously-included files matching '*' found under directory 'src/senaite/app/spotlight'
warning: no previously-included files matching '*' found under directory 'src/senaite/app/supermodel'
warning: no previously-included files matching '*.pyc' found under directory 'src'
warning: no previously-included files matching '*' found under directory 'webpack'
  File "build/bdist.linux-x86_64/egg/senaite/core/skins/senaite_scripts/member_is_client.py", line 17
    return "Clients" in member_groups
SyntaxError: 'return' outside function

  File "build/bdist.linux-x86_64/egg/senaite/core/skins/senaite_scripts/getDisplayView.py", line 11
    return value
SyntaxError: 'return' outside function

  File "build/bdist.linux-x86_64/egg/bika/lims/skins/bika/guard_handler.py", line 10
    return wf_guard_handler(context, transition_id)
SyntaxError: 'return' outside function

  File "/home/senaite/buildout-cache/eggs/tmpSGydhH/senaite.core-2.2.0-py2.7.egg/bika/lims/skins/bika/guard_handler.py", line 10
    return wf_guard_handler(context, transition_id)
SyntaxError: 'return' outside function

  File "/home/senaite/buildout-cache/eggs/tmpSGydhH/senaite.core-2.2.0-py2.7.egg/senaite/core/skins/senaite_scripts/getDisplayView.py", line 11
    return value
SyntaxError: 'return' outside function

  File "/home/senaite/buildout-cache/eggs/tmpSGydhH/senaite.core-2.2.0-py2.7.egg/senaite/core/skins/senaite_scripts/member_is_client.py", line 17
    return "Clients" in member_groups
SyntaxError: 'return' outside function

Got senaite.core 2.2.0.
Version and requirements information containing plone:
  [versions] constraint on plone: 4.3.19
  Base installation request: 'Plone', 'senaite.lims', 'simplejson', 'Pillow', 'plone.recipe.zope2instance'
  Requirement of plone.recipe.zope2instance==4.4.1: ZODB3>=3.9
  Requirement of plone.recipe.zope2instance==4.4.1: Zope2>=2.12.1
  Requirement of plone.recipe.zope2instance==4.4.1: zc.recipe.egg
  Requirement of plone.recipe.zope2instance==4.4.1: mailinglogger
  Requirement of plone.recipe.zope2instance==4.4.1: setuptools
  Requirement of plone.recipe.zope2instance==4.4.1: zc.buildout
  Requirement of senaite.lims: Plone==5.2.7
  Requirement of Plone==4.3.19: wicked
  Requirement of Plone==4.3.19: plone.app.theming
  Requirement of Plone==4.3.19: plone.app.openid
  Requirement of Plone==4.3.19: plone.app.iterate
  Requirement of Plone==4.3.19: plone.app.dexterity
  Requirement of Plone==4.3.19: plone.app.caching
  Requirement of Plone==4.3.19: Products.CMFPlone
  Requirement of Plone==4.3.19: Products.CMFPlacefulWorkflow
  Requirement of Plone==4.3.19: setuptools
  Requirement of senaite.core==2.2.0: plone.app.jquerytools
  Requirement of senaite.core==2.2.0: plone.subrequest
  Requirement of senaite.core==2.2.0: plone.resource
  Requirement of senaite.core==2.2.0: plone.jsonapi.core
  Requirement of senaite.core==2.2.0: plone.app.z3cform
  Requirement of senaite.core==2.2.0: plone.app.relationfield
  Requirement of senaite.core==2.2.0: plone.app.referenceablebehavior
  Requirement of senaite.core==2.2.0: plone.app.iterate
  Requirement of senaite.core==2.2.0: plone.app.dexterity
  Requirement of senaite.core==2.2.0: plone.api
While:
  Installing instance.
Error: The requirement ('Plone==5.2.7') is not allowed by your [versions] constraint (4.3.19)

Hi @dessmunyiva

Senaite 2.x runs on Plone 5.2.7 and you have installed Plone 4.3.19, please install Plone 5.2.7 unless you want to run Senaite Health which is still using Senaite 1.3.x and runs on Plone 4.3.20

Thank you so so much, i was trying to install the senaite LIMS for our Quality Check LAB… let me try and get back to you. thanks again

Thanks All,

I’m facing the same issue. How do I set the initial Plone installation to 4.3.19?

Hi @etiennemahe

Please download and use the Plone 4.3.19 Unified installer file