Is Kolibri Central server down?

I’ve been trying to download several bits of content (KA and PhET) on Kolibri for the past hour but it’s not working, doesn’t even start.
Just wondering if there is a problem with the central server and if I should try later.

Best,
Clementine

Hi @clementine,

We are sorry to hear you are experiencing problems downloading channels. Do you see the Importing content... progress bar as in the image below?

The import operation above is running as we speak on one of ours testing machines, so Kolibri Studio (Central Server) is up and working correctly.

Could you upload the kolibri.log and debug.log files here (both are located in your home directory, inside the ./kolibri folder):

This will help us debug the problem you are experiencing.

Hi @radia-matic

Thanks for your prompt response.
I’ve uploaded a screenshot of where I get stuck. The dark purple bar is rotating in reality (this is not captured by the screenshot).

regarding the logs, ./kolibri/debug.log is blank
and here is what I get in ./kolibri/kolibri.log:

INFO 2018-01-30 21:23:33,870 cli Going to daemon mode, logging to /home/pi/.kolibri/server.log
INFO 2018-01-30 21:23:34,445 utils Started new MESSAGEPROCESSOR thread ID#coffee-pluto-lion-muppet
INFO 2018-01-30 21:23:34,447 utils Started new SCHEDULER thread ID#solar-happy-hotel-michigan
INFO 2018-01-30 21:23:34,451 utils Started new WORKERMESSAGEHANDLER thread ID#echo-emma-saturn-aspen
INFO 2018-01-30 21:23:35,561 ping Attempting a ping.
INFO 2018-01-30 21:23:35,642 ping data: {“platform”: “Linux-4.9.59-v7±armv7l-with-debian-9.3”, “mode”: “”, “version”: "0$
INFO 2018-01-30 21:23:36,251 ping Ping succeeded! (response: {}) Sleeping for 1440.0 minutes.
WARNING 2018-01-30 21:27:00,839 api Did not find language code None in our le_utils.constants!
WARNING 2018-01-30 21:27:00,846 api Did not find language code None in our le_utils.constants!
INFO 2018-01-30 21:27:06,880 importchannel Downloading data for channel id 197934f144305350b5820c7c4dd8e194

As you can see, the downloading command was fired at 21:27, and I’m doing the CP of the log now at 21:41. Nothing as moved since then.

Hello,

The problem is still not solved.
I reinstalled Kolibri and now none of the content packages is installing.
It looks as if the app was hanging when I hit the download button.

For info, I installed Kolibri using PIP (both times) on the raspberry pi (latest Rasbian Jessie OS).

When Kolibri starts I get the following message:
Your models have changes that are not yet reflected in a migration, and so won’t be applied.
Run ‘manage.py makemigrations’ to make new migrations, and then re-run ‘manage.py migrate’ to apply them.

Could these un-applied migrations be a cause for this problem?

Best,
Clementine

Hi @clementine,

Sorry for not following up your issue earlier.
I think your issue could be similar to this one here: https://github.com/learningequality/kolibri/issues/3028#issuecomment-356428642

Basically, you can run:

> python (or python 3 if that's how you installed Kolibri)
>> import urllib3
>> urllib3.__version__

to see if your urllib3 version is lower than 1.22.

If the version of urllib3 is lower than 1.22, then you can upgrade it to 1.22 by doing:

> pip install urllib3==1.22 (or pip3 install urllib3==1.22 if you installed Kolibri with Python 3)

On the other hand, we are actively developing and will have a 0.7.1 release soon to resolve this issue.

Please feel free to let me know if you have any further questions.

Regards,
Lingyi

Hi @lingyi

I’ve tried this fix but unfortunately, it didn’t work in my case.
I have urllib3.version >> 1.22 yet still the same hanging.

One thing I didn’t mention in this thread is that it used to work on my system at the beginning, I downloaded 2 content threads just after the install, and then it stopped working after this.
I reinstalled Kolibri completely and now it’s not working at all.

Hi @clementine,

I’m very sorry that it didn’t work.

Have you ever removed your ~/.kolibri folder?
If not, could you take a look at ~/.kolibri/content/databases to see what the files inside are? Does any of the files inside that folder end with .transfer?
Also, did you use Python 2 or Python 3 to install Kolibri?

If you run:

> kolibri shell
> import requests
> requests.__version__
> requests.__file__

could you copy and paste the output here?

Thank you so much! And sorry again about the inconvenience.

Hi @lingyi

I did remove the ~/.kolibri folder when I reinstalled Kolibri unfortunately.
But I still have .transfer files in the content/databases folder:
131e543dbecf5776bb13cfcfddf05605.sqlite3.transfer a53592c972a8594e9b695aa127493ff6.sqlite3.transfer
197934f144305350b5820c7c4dd8e194.sqlite3.transfer

I’m using python 3.

requests.version
2.9.1
requests.file
‘/usr/local/lib/python3.5/dist-packages/requests-2.9.1-py3.5.egg/requests/init.py’

I’m going to try and reinstall a new SD card today, to see if I can get to work again.
Will keep you posted.
Best,

Hi @clementine,

Thank you for the information! I think the problem could be caused by the version of requests. I tried to use requests 2.9.1 on my machine, and the same problem as you described here showed up. One thing I would recommend you to try is to remove your ~/.kolibri folder and then download our 0.7.1 release, in which you will be using our bundled requests 2.18.4 instead of your system package. You are now able to find it on PyPi: https://pypi.python.org/pypi/kolibri/, so please feel free to install Kolibri 0.7.1 through pip install kolibri==0.7.1.

Please do not hesitate to let me know if the problem still exists :slight_smile:

Regards,
Lingyi

Hi @lingyi

I’ve created a new SD card and tried reinstalling Kolibri.
I have the following problem now:

pip install kolibri==0.7.1.
Collecting kolibri==0.7.1.
Exception:
Traceback (most recent call last):
File “/usr/lib/python2.7/dist-packages/pip/basecommand.py”, line 215, in main
status = self.run(options, args)
File “/usr/lib/python2.7/dist-packages/pip/commands/install.py”, line 353, in run
wb.build(autobuilding=True)
File “/usr/lib/python2.7/dist-packages/pip/wheel.py”, line 749, in build
self.requirement_set.prepare_files(self.finder)
File “/usr/lib/python2.7/dist-packages/pip/req/req_set.py”, line 380, in prepare_files
ignore_dependencies=self.ignore_dependencies))
File “/usr/lib/python2.7/dist-packages/pip/req/req_set.py”, line 620, in _prepare_file
session=self.session, hashes=hashes)
File “/usr/lib/python2.7/dist-packages/pip/download.py”, line 821, in unpack_url
hashes=hashes
File “/usr/lib/python2.7/dist-packages/pip/download.py”, line 659, in unpack_http_url
hashes)
File “/usr/lib/python2.7/dist-packages/pip/download.py”, line 853, in _download_http_url
stream=True,
File “/usr/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/sessions.py”, line 501, in get
return self.request(‘GET’, url, **kwargs)
File “/usr/lib/python2.7/dist-packages/pip/download.py”, line 386, in request
return super(PipSession, self).request(method, url, *args, **kwargs)
File “/usr/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/sessions.py”, line 488, in request
resp = self.send(prep, **send_kwargs)
File “/usr/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/sessions.py”, line 609, in send
r = adapter.send(request, **kwargs)
File “/usr/share/python-wheels/CacheControl-0.11.7-py2.py3-none-any.whl/cachecontrol/adapter.py”, line 37, in send
cached_response = self.controller.cached_request(request)
File “/usr/share/python-wheels/CacheControl-0.11.7-py2.py3-none-any.whl/cachecontrol/controller.py”, line 111, in cached_request
resp = self.serializer.loads(request, cache_data)
File “/usr/share/python-wheels/CacheControl-0.11.7-py2.py3-none-any.whl/cachecontrol/serialize.py”, line 114, in loads
return getattr(self, “_loads_v{0}”.format(ver))(request, data)
File “/usr/share/python-wheels/CacheControl-0.11.7-py2.py3-none-any.whl/cachecontrol/serialize.py”, line 176, in _loads_v2
cached = json.loads(zlib.decompress(data).decode(“utf8”))
File “/usr/lib/python2.7/json/init.py”, line 339, in loads
return _default_decoder.decode(s)
File “/usr/lib/python2.7/json/decoder.py”, line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/lib/python2.7/json/decoder.py”, line 380, in raw_decode
obj, end = self.scan_once(s, idx)
MemoryError

When I use

pip3 install Kolibri

The installation is successful but then I get the following error when I try to start Kolibri:

kolibri start
Traceback (most recent call last):
File “.local/bin/kolibri”, line 7, in
from kolibri.utils.cli import main
File “/home/pi/.local/lib/python3.5/site-packages/kolibri/utils/cli.py”, line 22, in
from . import server # noqa
File “/home/pi/.local/lib/python3.5/site-packages/kolibri/utils/server.py”, line 6, in
import cherrypy
File “/home/pi/.local/lib/python3.5/site-packages/kolibri/dist/cherrypy/init.py”, line 64, in
from cherrypy._cperror import HTTPError, HTTPRedirect, InternalRedirect
File “/home/pi/.local/lib/python3.5/site-packages/kolibri/dist/cherrypy/_cperror.py”, line 118, in
from cgi import escape as _escape
File “/usr/lib/python3.5/cgi.py”, line 42, in
import html
File “/home/pi/.local/lib/python3.5/site-packages/kolibri/dist/html/init.py”, line 7, in
raise ImportError('This package should not be accessible on Python 3. ’
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.

Hi @clementine,

I’m very sorry that there are still problems in our 0.7.1 release. We are still trying to identify the issue and hoping to resolve this soon.
However, at this point of time, we think this issue could be related to PyPi, so I would suggest that you can go to our github release page: Release v0.7.1 · learningequality/kolibri · GitHub to download the whl file.
After that, please try:

pip3 uninstall kolibri
rm -r ~/.kolibri
pip3 install kolibri-0.7.1-py2.py3-none-any.whl (which is the whl file you just download from github)

Please let us know if there are still problems. Sorry about your experience with installing Kolibri and thank you for your patience.

Regards,
Lingyi

Hi @lingyi

I’ve tried this, but unfortunately, it didn’t solve the problem.
The error message at kolibri start is identical.

Also I wanted to mention that there is no ~/.kolibri folder at this stage.

Hi @clementine,

Can you show me the output of
ls -l /home/pi/.local/lib/python3.5/site-packages/kolibri/dist/?

Also, could you please extract the kolibri-0.7.1-py2.py3-none-any.whl file (you might be able to do this just by double clicking the file). Inside the extracted folder, please go to kolibri folder and then click dist folder. And then can you take a screenshot of what it is inside dist folder and upload it here?

Thank you so much!

Hi @lingyi

Here it is:

ls -l /home/pi/.local/lib/python3.5/site-packages/kolibri/dist/
total 292
-rw-r–r-- 1 pi pi 9316 Feb 5 23:09 args.py
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 builtins
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 certifi
drwxr-xr-x 6 pi pi 4096 Feb 5 21:31 cext
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 chardet
drwxr-xr-x 9 pi pi 4096 Feb 5 21:32 cherrypy
drwxr-xr-x 5 pi pi 4096 Feb 5 21:32 clint
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 colorlog
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 concurrent
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 copyreg
drwxr-xr-x 5 pi pi 4096 Feb 5 21:32 dateutil
drwxr-xr-x 18 pi pi 4096 Feb 5 21:32 django
drwxr-xr-x 4 pi pi 4096 Feb 5 21:31 django_filters
drwxr-xr-x 6 pi pi 4096 Feb 5 21:31 django_js_reverse
-rw-r–r-- 1 pi pi 19946 Feb 5 23:09 docopt.py
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 _dummy_thread
drwxr-xr-x 10 pi pi 4096 Feb 5 21:31 future
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 html
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 http
drwxr-xr-x 8 pi pi 4096 Feb 5 21:32 iceqube
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 idna
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 ifcfg
-rw-r–r-- 1 pi pi 0 Feb 5 23:09 init.py
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 ipware
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 jsonfield
drwxr-xr-x 6 pi pi 4096 Feb 5 21:32 kolibri_exercise_perseus_plugin
drwxr-xr-x 5 pi pi 4096 Feb 5 21:32 le_utils
drwxr-xr-x 4 pi pi 4096 Feb 5 21:31 libfuturize
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 libpasteurize
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 _markupbase
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 metaphone
drwxr-xr-x 8 pi pi 4096 Feb 5 21:32 morango
drwxr-xr-x 7 pi pi 4096 Feb 5 21:31 mptt
drwxr-xr-x 8 pi pi 4096 Feb 5 21:32 past
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 porter2stemmer
drwxr-xr-x 16 pi pi 4096 Feb 5 21:31 py2only
drwxr-xr-x 6 pi pi 4096 Feb 5 21:31 pyasn1
drwxr-xr-x 2 pi pi 4096 Feb 5 21:31 pycache
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 pytz
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 queue
-rw-r–r-- 1 pi pi 212 Feb 5 23:09 README
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 reprlib
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 requests
drwxr-xr-x 10 pi pi 4096 Feb 5 21:32 requests_toolbelt
drwxr-xr-x 9 pi pi 4096 Feb 5 21:32 rest_framework
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 rest_framework_csv
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 rsa
-rw-r–r-- 1 pi pi 30098 Feb 5 23:09 six.py
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 socketserver
drwxr-xr-x 13 pi pi 4096 Feb 5 21:32 sqlalchemy
drwxr-xr-x 4 pi pi 4096 Feb 5 21:32 tests
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 _thread
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 tkinter
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 tqdm
drwxr-xr-x 4 pi pi 4096 Feb 5 21:31 tzlocal
drwxr-xr-x 3 pi pi 4096 Feb 5 21:31 ua_parser
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 unicodecsv
drwxr-xr-x 6 pi pi 4096 Feb 5 21:32 urllib3
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 user_agents
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 winreg
drwxr-xr-x 3 pi pi 4096 Feb 5 21:32 xmlrpc

I extracted the kolibri-0.7.1-py2.py3-none-any.whl file using unzip and I found 2 folders. Not 100% sure which one is of interest to you so I’ve listed both contents:
ls -l kolibri-0.7.1.dist-info

total 920
-rw-r–r-- 1 pi pi 2895 Feb 2 06:22 DESCRIPTION.rst
-rw-r–r-- 1 pi pi 52 Feb 2 06:22 entry_points.txt
-rw-r–r-- 1 pi pi 3824 Feb 2 06:22 METADATA
-rw-r–r-- 1 pi pi 1265 Feb 2 06:22 metadata.json
-rw-r–r-- 1 pi pi 914045 Feb 2 06:22 RECORD
-rw-r–r-- 1 pi pi 8 Feb 2 06:22 top_level.txt
-rw-r–r-- 1 pi pi 110 Feb 2 06:22 WHEEL

ls -l kolibri/dist

total 232
-rw-r–r-- 1 pi pi 9316 Feb 2 06:18 args.py
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 certifi
drwxr-xr-x 6 pi pi 4096 Feb 6 10:01 cext
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 chardet
drwxr-xr-x 8 pi pi 4096 Feb 6 10:01 cherrypy
drwxr-xr-x 4 pi pi 4096 Feb 6 10:01 clint
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 colorlog
drwxr-xr-x 4 pi pi 4096 Feb 6 10:01 dateutil
drwxr-xr-x 17 pi pi 4096 Feb 6 10:01 django
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 django_filters
drwxr-xr-x 5 pi pi 4096 Feb 6 10:01 django_js_reverse
-rw-r–r-- 1 pi pi 19946 Feb 2 06:18 docopt.py
drwxr-xr-x 9 pi pi 4096 Feb 6 10:01 future
drwxr-xr-x 7 pi pi 4096 Feb 6 10:01 iceqube
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 idna
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 ifcfg
-rw-r–r-- 1 pi pi 0 Feb 2 06:18 init.py
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 ipware
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 jsonfield
drwxr-xr-x 5 pi pi 4096 Feb 6 10:01 kolibri_exercise_perseus_plugin
drwxr-xr-x 4 pi pi 4096 Feb 6 10:01 le_utils
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 libfuturize
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 libpasteurize
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 metaphone
drwxr-xr-x 7 pi pi 4096 Feb 6 10:01 morango
drwxr-xr-x 6 pi pi 4096 Feb 6 10:01 mptt
drwxr-xr-x 7 pi pi 4096 Feb 6 10:01 past
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 porter2stemmer
drwxr-xr-x 16 pi pi 4096 Feb 6 10:01 py2only
drwxr-xr-x 5 pi pi 4096 Feb 6 10:01 pyasn1
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 pytz
-rw-r–r-- 1 pi pi 212 Feb 2 06:18 README
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 requests
drwxr-xr-x 9 pi pi 4096 Feb 6 10:01 requests_toolbelt
drwxr-xr-x 8 pi pi 4096 Feb 6 10:01 rest_framework
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 rest_framework_csv
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 rsa
-rw-r–r-- 1 pi pi 30098 Feb 2 06:18 six.py
drwxr-xr-x 12 pi pi 4096 Feb 6 10:01 sqlalchemy
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 tests
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 tqdm
drwxr-xr-x 3 pi pi 4096 Feb 6 10:01 tzlocal
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 ua_parser
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 unicodecsv
drwxr-xr-x 5 pi pi 4096 Feb 6 10:01 urllib3
drwxr-xr-x 2 pi pi 4096 Feb 6 10:01 user_agents

Hi @clementine,

It looks that your current kolibri install in Python 3 is still from PyPi but the kolibri-0.7.1-py2.py3-none-any.whl is correct.

Do you mind trying this again just to confirm?

> pip3 uninstall -y kolibri

> ls -l /home/pi/.local/lib/python3.5/site-packages/kolibri/   [this command should get an error saying this directory doesn't exist. If in the command the directory still exist, please let me know]

> pip3 install kolibri-0.7.1-py2.py3-none-any.whl   [Instead of running pip3 install kolibri, you will have to install the specific file you downloaded from our github. Also, you will have to run this in the directory that kolibri-0.7.1-py2.py3-none-any.whl exists or replace the filename with the path to the file.]

> ls -l /home/pi/.local/lib/python3.5/site-packages/kolibri/dist    [please copy and paste the output of this command here.]

Thank you so much!

Regards,
Lingyi

Hi @lingyi

When I run this after uninstalling kolibri:

I don’t have an error message, as the directory still exists:

total 20
drwxr-xr-x 3 pi pi 4096 Feb 6 20:11 core
drwxr-xr-x 18 pi pi 4096 Feb 6 20:11 dist
drwxr-xr-x 6 pi pi 4096 Feb 6 20:11 locale
drwxr-xr-x 14 pi pi 4096 Feb 6 20:11 plugins
drwxr-xr-x 4 pi pi 4096 Feb 6 20:11 utils

Best,
Clementine

Hi @clementine,

thank you for the information! I think the problem here might be the new kolibri got installed to another directory.

Could you please run pip3 install kolibri-0.7.1-py2.py3-none-any.whl if you haven’t. After that, could you also run the following two commands and then paste the output here?

> pip3 --version
> pip3 show kolibri

thank you!

Best,
Lingyi

Sure,

pip3 --version
pip 9.0.1 from /usr/lib/python3/dist-packages (python 3.5)
pip3 show kolibri
Name: kolibri
Version: 0.7.1
Summary: Kolibri education platform for offline environments This static version bundles all dependencies.
Home-page: GitHub - learningequality/kolibri: Kolibri Learning Platform: the offline app for universal education
Author: Learning Equality
Author-email: info@learningequality.org
License: MIT
Location: /home/pi/.local/lib/python3.5/site-packages
Requires:

Hi @clementine,

Could you please show me the output of the commands?

>  ls -l /usr/lib/python3/dist-packages/kolibri

Does it say the directory doesn’t exist or show the content inside the directory?

and also

> python 3
>>> import kolibri
>>> kolibri.__file__

After that, if you do pip3 uninstall kolibri, before you enter y to the question Proceed (y/n)? what is the line right before this question?
For example, it might be something like

/usr/lib/python3/dist-packages/kolibri/utils/version.py

Thank you!

Sincerely,
Lingyi

ls -l /usr/lib/python3/dist-packages/kolibri

ls: cannot access ‘/usr/lib/python3/dist-packages/kolibri’: No such file or directory

kolibri.__file__

‘/home/pi/kolibri/init.py’

Before uninstalling the last line is:

/home/pi/.local/lib/python3.5/site-packages/kolibri/utils/version.py