[CalendarServer-users] Almost running CalServer on Centos 5.4
markus.stuermer at informatik.uni-erlangen.de
Wed Feb 3 14:07:41 PST 2010
Below is my init script, although I doubt it is still fully compliant with the newer SUSE specifications. We recently upgraded that machine, and it seems to still work. You will have to adapt at least the CALUSER and the PATHROOT, perhaps even further paths. You will also see that I have a quite strict policy of killing all processes that did not follow the TERM signal after a few seconds…
We had a discussion about how to get iMiP invitations working recently, perhaps you can find it in the archives. This was the approach I did, and there might be a better one, unfortunately we never got comments from the developer side. I doubt that we get it at the first attempt this time, but let's try:
- you'll need a user, by default com.apple.calendarserver, in your accounts.xml (or whatever authentication scheme you use)
- that user needs admin privileges, so add its GUID to the AdminPrincipals section in your caldavd.plist
- Enable iMiP in caldavd.plist's iMiP section and provide the password you gave com.apple.calendarserver (and, if different, the username). You'll further need to configure POP3/IMAP and SMTP.
At the time I did that I also had to apply a small patch, but I hope this isn't necessary anymore. Better try without first and let me know if you get a python exception…
Good luck and best regards,
>>> SNIP >>>
### BEGIN INIT INFO
# Provides: caldav
# Required-Start: $network $syslog
# Required-Stop: $network $syslog
# Default-Start: 3 5
# Default-Stop: 0 1 2 4 6
# Description: Calendar server Demon
### END INIT INFO
DESC="Apple Calendar Server"
CALOPTIONS="caldav -f PATHROOT/conf/caldavd.plist -o ProcessType=Combined"
test -s /etc/rc.status && \
# First reset status of this service
case "$1" in
echo -e "Starting $DESC"
startproc -u "$CALUSER" -p $PIDFILE $DAEMON $CALOPTIONS
echo -n "Stopping $DESC"
killproc -TERM -p $PIDFILE $SERVICE
killall -u "$CALUSER" /usr/bin/python >/dev/null 2>&1
if [ "$?" == "0" ]; then
killall -9 -u "$CALUSER" /usr/bin/python
<<< SNAP <<<
Am 03.02.2010 um 22:10 schrieb Peter Huetmannsberger:
> thank you for sharing this. Would you be able to mail me your init Skript. There is not that much difference between the SuSE and the CentOS startup skripts.
> Also it would be interesting to see what you set your paths to.
> Thank you.
> I don't seem to have any luck with sending out invitations.
> All the best
> On Wed, 3 Feb 2010, Markus Stürmer wrote:
>> Hi Peter!
>> I'm running DCS on a recent openSUSE. I got caldav working without cd-ing into its directory from my init.d by setting appropriate environment variables. I had to adapt my PATH and LD_LIBRARY_PATH environment variables (both pointing into the memcached directory), and my PYTHONPATH is multiple terminal lines long, as I am using the original data structure created by the run script.
>> Am 03.02.2010 um 21:09 schrieb Peter Huetmannsberger:
>>> On Tue, 2 Feb 2010, Guy wrote:
>>>> you should be able to just add -r 4538 to the end of the "svn co" commands
>>> Thank you, that did it, I can now log on, see the dates in Sunbird and in my Iphone. Great!
>>> I would like to add that some of the problems may arise that I am running an x86_64 bit version of Centos. Ans some things get installed in /usr/lib others in /usr/lib64
>>> I still have many questions though. Sorry.
>>> 1) It only works if I start the program in the folder I built it.
>>> i.e. cd /root/downloads/ical-4538/CalendarServer/
>>> /usr/bin/caldavd -X -f /etc/caldavd/caldavd.plist
>>> If I start it from anywhere else I get an error from twist about not knowing caldavd as an option.
>>> 2) I get the following error now:
>>> File "/root/downloads/ical-4538/CalendarServer/twistedcaldav/sql.py", line 303, in _db_execute
>>> 2010-02-03 20:54:27+0100 [-] [caldav-8009]
>>> 2010-02-03 20:54:27+0100 [-] [caldav-8009] File "/root/downloads/ical-4538/CalendarServer/twistedcaldav/sql.py", line 85, in _db
>>> sqlite3.OperationalError: unable to open database file
>>> Checking what I had:
>>> [root at ical caldavd]# rpm -qa | grep sqlite
>>> I don't see a problem there. But then it is all new ground for me.
>>> In any case, thanks for your help. Now I need to see if it all works the way I want to.
>>> All the best
>>> calendarserver-users mailing list
>>> calendarserver-users at lists.macosforge.org
> Please note that my email has changed to:
> huetmann at violine.at
More information about the calendarserver-users