[ZODB-Dev] [ZODB 3.8/Blob] Error in rename_or_copy_blob()
Andreas Jung
lists at zopyx.com
Mon Apr 26 06:34:30 EDT 2010
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi there,
a customer site is running Plone 3.3 w/ plone.app.blob.
While creating a 'File' instance we get the following error:
2010-04-26T13:17:07 ERROR Zope.SiteErrorLog 1272277027.360.157502129415
http://www.deisa.eu/test-project/conversions/@@generate/generate
Traceback (innermost last):
Module ZPublisher.Publish, line 125, in publish
Module Zope2.App.startup, line 238, in commit
Module transaction._manager, line 93, in commit
Module transaction._transaction, line 325, in commit
Module transaction._transaction, line 432, in _commitResources
Module ZODB.Connection, line 762, in tpc_finish
Module ZEO.ClientStorage, line 1088, in tpc_finish
Module ZEO.ClientStorage, line 1134, in _update_cache
Module ZODB.blob, line 772, in rename_or_copy_blob
IOError: [Errno 13] Permission denied:
'/home/plone/Plone/zeocluster/var/blobstorage/0x00/0x00/0x00/0x00/0x00/0x07/0x4c/0xf0/0x0385b9291ea836aa.blob'
The Plone processes is running as user 'plone' (nothing related to
setuid/effective-user) and all files and directories are owned by
'plone'. I could even create a new file from the debugger inside
rename_or_copy_blob() inside the
/home/plone/Plone/zeocluster/var/blobstorage/0x00/0x00/0x00/0x00/0x00/0x07/0x4c/0xf0
directory.
The related code in blob.py is:
759 def rename_or_copy_blob(f1, f2, chmod=True):
760 """Try to rename f1 to f2, fallback to copy.
761
762 Under certain conditions a rename might not work, e.g. because
the target
763 directory is on a different partition. In this case we try to
copy the
764 data and remove the old file afterwards.
765
766 """
767 try:
768 os.rename(f1, f2)
769 except OSError:
770 copied("Copied blob file %r to %r.", f1, f2)
771 file1 = open(f1, 'rb')
772 file2 = open(f2, 'wb')
^^^^^^^^^^^^^^^^^^^^^^^
773 try:
774 utils.cp(file1, file2)
775 finally:
776 file1.close()
777 file2.close()
778 remove_committed(f1)
779 if chmod:
780 os.chmod(f2, stat.S_IREAD)
Is this a known problem and how can this be fixed.
Andreas
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkvVbDYACgkQCJIWIbr9KYxusgCfWt7Q2GZ+JAY2vuafeI/VdY+m
nXcAn3HV5Xiagaw2ARyvQIntYA7NxzMJ
=TZvA
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lists.vcf
Type: text/x-vcard
Size: 316 bytes
Desc: not available
Url : http://mail.zope.org/pipermail/zodb-dev/attachments/20100426/f1c62506/attachment.vcf
More information about the ZODB-Dev
mailing list