Hi, I’m running a Seafile server on a Raspberry Pi 1 Model B. I found that I couldn’t run the latest published release of the server and tried to build it myself.
My Pi is running a fresh buster install. I managed to complete the build process successfully, but I cannot run the server yet. The problem is:
Starting seahub at port 8000 ...
Traceback (most recent call last):
File "/media/hdd/seafile/seafile-server-7.1.5/check_init_admin.py", line 351, in <module>
rpc = RPC()
File "/media/hdd/seafile/seafile-server-7.1.5/check_init_admin.py", line 284, in __init__
import ccnet
ModuleNotFoundError: No module named 'ccnet'
I found out that the ccnet module is located at:
$ find . -name ccnet*
./seafile/lib/python2.7/site-packages/ccnet
...
I guess it should be under …/python3.6, like in the released builds. One more thing, python 2.7 is still default on buster; the build3 script always calls the python3 binary, but could there be something else missing…?
Finally, kudos to developers for this piece of software and to @jobenvil for all these years providing Raspberry Pi releases. Thanks in advance for your help.
1 Like
@jaragunde Yes, you are right. Firstly, the problem is related to the fact that your python directory is called python2.7. Secondly, not only the name is wrong. It means, that you compiled Seafile using python2.7 and Seahub doesn’t work anymore with python2.7.
There is an easy workaround. You could temporaly link your python binary to python3 before to execute the build3.sh script. That mean, wehn you type just python -V
, it should be Python 3.*.*
(bigger than python3.5).
When you get a working release, post it to upload it to the GitHub repository. We miss arm6 (i.e. for Pi model B). I can give you guidance.
Thanks for your help! Unfortunately, while the build seems to be successful, the error persists:
Default python is now 3.7.3:
$ python -V
Python 3.7.3
Python modules were built to the expected place:
$ find . -name ccnet*
./seafile/lib/python3.7/site-packages/ccnet
...
Still, same error when launching seahub:
$ ./seahub.sh start
Starting seahub at port 8000 ...
Traceback (most recent call last):
File "/media/hdd/seafile/seafile-server-7.1.5/check_init_admin.py", line 351, in <module>
rpc = RPC()
File "/media/hdd/seafile/seafile-server-7.1.5/check_init_admin.py", line 284, in __init__
import ccnet
ModuleNotFoundError: No module named 'ccnet'
Although, if I rename the python lib directory to the same name used in a released build, the error is different:
$ mv ./seafile/lib/python3.7/ ./seafile/lib/python3.6
$ ./seahub.sh start
Starting seahub at port 8000 ...
Error:Seahub failed to start.
Please try to run "./seahub.sh start" again
@jaragunde you are on the right path. The mv
movement was necessary to reach the properly libs. Now this is fixed and ccnet
is found.
Probably is some python module, that you are still missing. Set daemon = False
to see seahub errors
$ /home/seafile # cat conf/gunicorn.conf.py
import os
daemon = True
#daemon = False uncomment this line to debug seahub when doesn't start. comment daemon = True
workers = 2
# default localhost:8000
bind = "0.0.0.0:8000"
# Pid
pids_dir = '/media/sda/seafile/pids'
pidfile = os.path.join(pids_dir, 'seahub.pid')
# Logging
logs_dir = '/media/sda/seafile/logs'
errorlog = os.path.join(logs_dir, 'gunicorn_error.log')
accesslog = os.path.join(logs_dir, 'gunicorn_access.log')
# for file upload, we need a longer timeout value (default is only 30s, too short)
timeout = 12000
limit_request_line = 8190 # nuevo con minor upgrade 7.-7.1
and start again seahub manually… ./seahub.sh start
Remember to revert changes after that.
You are right, there are more missing python modules:
ModuleNotFoundError: No module named 'pymysql'
ModuleNotFoundError: No module named 'django.core.urlresolvers'
The former was fixed with apt install python3-pymysql, but I haven’t found a solution to the django error yet. So far, I made sure I had installed the new dependencies specified in the 7.1.x upgrade guide.
I have to get back to work, I’ll read you back later. Thanks again for your help .
@jaragunde I sent you via pm the whole requirements.txt
problematic, which is limited to the seahub tag v7.1.5
build.