[ZODB-Dev] zeo, data.fs permissions
Mark McEahern
mark@mceahern.com
Fri, 30 Aug 2002 22:49:14 -0500
Hi, I'm trying to install ZEO2 (the latest version 2.0b1). Here's a rough
outline of what I've done. I have Red Hat 7.3:
1. Build Python 2.1.3 RPMs from the SRPM.
2. Install Python 2.1.3 RPM and devel RPMs generated in step 1.
3. Build Zope 2.5.1 RPMs from the SRPM.
4. Install Zope 2.5.1 and zserver RPMs generated in step 3.
5. Unpack ZEO 2.0b1 tarball in /var/tmp -- generating /var/tmp/ZEO
6. In a bash shell:
# so python2.1 can find zope libs.
export PYTHONPATH='/usr/share/zope/lib/python'
cd /usr/share/zope
sudo python2.1 lib/python/ZEO/start.py -p 9000 -u zope
Output:
Traceback (most recent call last):
File "lib/python/ZEO/start.py", line 248, in main
storages['1'] = FileStorage(fs or env.fs)
File "/home/mark/rpm/BUILD/Zope-2.5.1-src/lib/python/ZODB/FileStorage.py",
line 240, in __init__
IOError: [Errno 13] Permission denied: '/usr/share/zope/var/Data.fs'
which is not surprising given that /usr/share/zope/var/Data.fs has mode 600
(rw- --- ---). If I do this:
# This is a drastic measure to see if I can trample roughshod
# over the permission error.
chown -R zope:zope /usr/share/zope/var
chmod -R +rw /usr/share/zope/var
It starts after I do that, but I doubt my drastic approach is a good one.
Also, shouldn't I have to put the custom_zodb.py in the Zope folder BEFORE
starting ZEO? (The docs/ZopeREADME.txt talks about running start.py BEFORE
custom_zodb.py.) I'm just trying to get ZEO and Zope running on the same
server. This is what my custom_zodb.py looks like:
# custom_zodb.py in Zope install directory (/usr/share/zope)
from ZEO.ClientStorage import ClientStorage
port = 9000
Storage = ClientStorage(('localhost', port))
After I put the custom_zodb.py in the Zope folder, start ZEO, and then start
Zope, I can access Zope, but I'm not sure how to tell that it's actually
using ZEO. In the ZMI/Control Panel/Database Management tab, I don't see
anything about Client Storage, for instance. Here's what it says:
<zmi>
The Database Manager allows you to view database status information. It also
allows you to perform maintenance tasks such as database packing and cache
management.
Database Location /var/zope/var/Data.fs
Database Size 2.0M
Click pack to pack the Zope database, removing previous revisions of objects
that are older than days.
</zmi>
Also, why is there a Data.fs in /var/zope/var AND in /usr/share/zope/var?
(Revealing my ignorance again.)
Well, I appreciate any insights anyone can share with me.
Thanks,
// mark
-