calendarserver fails to start

Bug #1361130 reported by F. Coers
32
This bug affects 6 people
Affects Status Importance Assigned to Milestone
pip
Invalid
Undecided
Unassigned
calendarserver (Ubuntu)
Confirmed
Undecided
Unassigned
python-cryptography (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

package calendarserver fails to start.

When starting service calendar server with the default configuration (and also with a previously working config for 12.04-calendarserver 3.2), the service fails to start with the following error message:

Reading configuration from file: /etc/caldavd/caldavd.plist
An error has occurred: 'list index out of range'
Please look at log file for more information.

Info:

calendarserver:
  Installed: 5.2+dfsg-1
  Candidate: 5.2+dfsg-1
  Version table:
 *** 5.2+dfsg-1 0
        500 http://ch.archive.ubuntu.com/ubuntu/ trusty/universe i386 Packages
        100 /var/lib/dpkg/status

Description: Ubuntu 14.04.1 LTS
Release: 14.04

Log:
Log opened.
2014-08-25 11:21:20+0200 [-] ControlSocket starting on '/var/run/caldavd/caldavd.sock'
2014-08-25 11:21:20+0200 [-] Traceback (most recent call last):
2014-08-25 11:21:20+0200 [-] File "/usr/bin/twistd", line 14, in <module>
2014-08-25 11:21:20+0200 [-] run()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/scripts/twistd.py", line 27, in run
2014-08-25 11:21:20+0200 [-] app.run(runApp, ServerOptions)
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 642, in run
2014-08-25 11:21:20+0200 [-] runApp(config)
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/scripts/twistd.py", line 23, in runApp
2014-08-25 11:21:20+0200 [-] _SomeApplicationRunner(config).run()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 380, in run
2014-08-25 11:21:20+0200 [-] self.postApplication()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/scripts/_twistd_unix.py", line 193, in postApplication
2014-08-25 11:21:20+0200 [-] self.startApplication(self.application)
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/scripts/_twistd_unix.py", line 390, in startApplication
2014-08-25 11:21:20+0200 [-] app.startApplication(application, not self.config['no_save'])
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 658, in startApplication
2014-08-25 11:21:20+0200 [-] service.IService(application).startService()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/application/service.py", line 282, in startService
2014-08-25 11:21:20+0200 [-] service.startService()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/twisted/application/service.py", line 282, in startService
2014-08-25 11:21:20+0200 [-] service.startService()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/txdav/base/datastore/subpostgres.py", line 505, in startService
2014-08-25 11:21:20+0200 [-] initdb = self.initdb()
2014-08-25 11:21:20+0200 [-] File "/usr/lib/python2.7/dist-packages/txdav/base/datastore/subpostgres.py", line 269, in initdb
2014-08-25 11:21:20+0200 [-] return which(self._initdb)[0]
2014-08-25 11:21:20+0200 [-] IndexError: list index out of range

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in calendarserver (Ubuntu):
status: New → Confirmed
Revision history for this message
Romain Petit (chlabelek) wrote :

Add the following lines in your caldavd.plist:
    <key>UseDatabase</key>
    <false/>

Revision history for this message
Patrick Bourgeois (ke5ebs) wrote :

I am having this same issue with the same log error I have tried adding the above line suggested by Romain Petit but to no avail

Patrick

Revision history for this message
Joachim Schwender (jschwender) wrote :

Same issue, same error message on wily, calendarserver 5.2.2+dfsg-2ubuntu amd64, default configuration. Suggestion #2 did not help. Package is not usable.

Revision history for this message
Battant (mparchet) wrote :

Hello,

to solve this issue, I have upgrade my ubuntu version from ubuntu 14.04 LTS to ubuntu 15.10.

Could you fixe this issues so the calendarserver of ubuntu 14.04 LTS version could start ?

Best regards

Battant

Revision history for this message
Battant (mparchet) wrote :

Hello,

I have another problem with calendarserver on ubuntu 15.10 and 16.04 LTS

https://answers.launchpad.net/ubuntu/+source/calendarserver/+question/291446

Thanks for your help

Best regards

Battant

Revision history for this message
Battant (mparchet) wrote :

Hello,

Here is my configuration :

 lsb_release -rd
Description: Ubuntu 16.04 LTS
Release: 16.04
 apt-cache policy calendarserver
calendarserver:
  Installed: 7.0+dfsg-2
  Candidate: 7.0+dfsg-2
  Version table:
 *** 7.0+dfsg-2 100
        100 /var/lib/dpkg/status
     7.0+dfsg-1 500
        500 http://archive.ubuntu.csg.uzh.ch/ubuntu xenial/universe amd64 Packages

Step to reproduce :

Install the calendarserver package on ubuntu 7.0 on ubuntu 16.04 LTS and follow the REeadme file at :

/usr/share/doc/calendarserver/README.Debian

For more information see :

https://answers.launchpad.net/ubuntu/+source/calendarserver/+question/291443

Actual result :

When I enter this command in a terminal :

systemctl status calendarserver.service
● calendarserver.service - LSB: Calendar and Contacts Server
   Loaded: loaded (/etc/init.d/calendarserver; bad; vendor preset: enabled)
   Active: active (exited) since mer. 2016-04-20 10:57:58 CEST; 10h ago
     Docs: man:systemd-sysv-generator(8)
  Process: 1545 ExecStart=/etc/init.d/calendarserver start (code=exited, status=
    Tasks: 0 (limit: 512)

Warning: Journal has been rotated since unit was started. Log output is incomple

why is there the message ; "bad; vendor preset: enabled)"

For more information see :
https://answers.launchpad.net/ubuntu/+source/calendarserver/+question/291632

Expend result :

Calendarserver 7.0 work

Could you help me please to fix this bug ?

Tanks for your support

Best regards

Battant

Revision history for this message
Battant (mparchet) wrote :

Hello,

If I look the calendarserver log

calendarserver[18669]: File "/usr/lib/python2.7/dist-packages/OpenSSL/rand.py", line 11, in <modu
: from OpenSSL._util import (
   File "/usr/lib/python2.7/dist-packages/OpenSSL/_util.py", line 6, in <modu
  calendarserver[18669]: from cryptography.hazmat.bindings.openssl.binding import Binding

 calendarserver[18669]: File "/usr/lib/python2.7/dist-packages/cryptography/hazmat/bindings/openss
 calendarserver[18669]: error=-1)
 calendarserver[18669]: File "/usr/lib/python2.7/dist-packages/cryptography/hazmat/bindings/openss calendarserver[18669]: ffi.def_extern(name=name, **kwargs)(func)
 calendarserver[18669]: AttributeError: 'CompiledFFI' object has no attribute 'def_extern'
 systemd[1]: Started LSB: Calendar and Contacts Server.

and try this line you get this error

 sudo pip install openssl
[sudo] password for mparchet:
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
  File "/home/mparchet/.local/lib/python2.7/site-packages/pip/__init__.py", line 16, in <module>
    from pip.vcs import git, mercurial, subversion, bazaar # noqa
  File "/home/mparchet/.local/lib/python2.7/site-packages/pip/vcs/mercurial.py", line 9, in <module>
    from pip.download import path_to_url
  File "/home/mparchet/.local/lib/python2.7/site-packages/pip/download.py", line 39, in <module>
    from pip._vendor import requests, six
  File "/home/mparchet/.local/lib/python2.7/site-packages/pip/_vendor/requests/__init__.py", line 53, in <module>
    from .packages.urllib3.contrib import pyopenssl
  File "/home/mparchet/.local/lib/python2.7/site-packages/pip/_vendor/requests/packages/urllib3/contrib/pyopenssl.py", line 54, in <module>
    import OpenSSL.SSL
  File "/usr/lib/python2.7/dist-packages/OpenSSL/__init__.py", line 8, in <module>
    from OpenSSL import rand, crypto, SSL
  File "/usr/lib/python2.7/dist-packages/OpenSSL/rand.py", line 11, in <module>
    from OpenSSL._util import (
  File "/usr/lib/python2.7/dist-packages/OpenSSL/_util.py", line 6, in <module>
    from cryptography.hazmat.bindings.openssl.binding import Binding
  File "/usr/lib/python2.7/dist-packages/cryptography/hazmat/bindings/openssl/binding.py", line 68, in <module>
    error=-1)
  File "/usr/lib/python2.7/dist-packages/cryptography/hazmat/bindings/openssl/binding.py", line 57, in wrapper
    ffi.def_extern(name=name, **kwargs)(func)
AttributeError: 'CompiledFFI' object has no attribute 'def_extern'

I have send a bug ticket heare ?

https://github.com/pyca/cryptography/issues/2909

Note It seems that the same problem is present on python with Homebrew on mac os x

Could you help me please to fix this issue ?

Best regards

Battant

Revision history for this message
Battant (mparchet) wrote :
Changed in python-cryptography (Ubuntu):
status: New → Invalid
Changed in pip:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.