Ticket #10130 (closed Bug: worksforme)

Opened 2 years ago

Last modified 2 years ago

blob support not available in mounted databases

Reported by: thet Owned by: witsch
Priority: blocker Milestone: 4.0
Component: Infrastructure Version:
Keywords: blobs Cc: davisagli

Description (last modified by thet) (diff)

when having plone installed in sepetrate zodb fs database, mounted in a mount point, uploading images or files does not work.

system: debian5, Plone 4.0b1dev-r33545 from trunk, Zope 2.12.3, Python 2.6.4 (r264:75706, Jan 28 2010, 12:56:34) [GCC 4.3.2]

here is the tracelog (note that the url-part grak is the mountpoint where the zodb is mounted)

2010-01-28 23:35:46 ERROR Zope.SiteErrorLog 1264718146.610.74251354703 http://localhost:8181/grak/gruene-akademie/portal_factory/Image/image.2010-01-28.1461823444/atct_edit
Traceback (innermost last):
  Module ZPublisher.Publish, line 135, in publish
  Module Zope2.App.startup, line 276, in commit
  Module transaction._manager, line 93, in commit
  Module transaction._transaction, line 322, in commit
  Module transaction._transaction, line 416, in _commitResources
  Module ZODB.Connection, line 558, in commit
  Module ZODB.Connection, line 606, in _commit
  Module ZODB.Connection, line 646, in _store_objects
Unsupported: Storing Blobs in <ZODB.FileStorage.FileStorage.FileStorage object at 0x9b54610> is not supported.

Change History

comment:1 Changed 2 years ago by thet

  • Description modified (diff)

comment:2 Changed 2 years ago by thet

  • Description modified (diff)

comment:3 Changed 2 years ago by kleist

  • Priority changed from minor to blocker

If this is reproducable, it must be a blocker.

comment:4 Changed 2 years ago by witsch

  • Cc davisagli added
  • Owner set to witsch
  • Status changed from new to assigned
  • Keywords blobs added

david just added blob support to  collective.recipe.filestorage and i assume the reason was the recent migration to blobs at his company, so i'm fairly positive this should actually not be a problem. have you configured a blobstorage for your additional filestorage (in zope.conf)?

ps: i'm cc'ing david hoping he's got more info without going in and recreating the setup first... :)

comment:5 Changed 2 years ago by davisagli

  • Status changed from assigned to closed
  • Resolution set to worksforme

You need to configure blobstorage for each mounted database.

Option 1 (non-ZEO): Add to the Zope instance part of your buildout, something like:

zope-conf-additional =
    <zodb_db grak>
        <filestorage >
          path ${buildout:directory}/var/filestorage/grak.fs
          blob-dir ${buildout:directory}/var/blobstorage-grak
        </filestorage>
        mount-point /grak
    </zodb_db>

(If you're already configuring your additional mountpoint this way, the only change is the addition of the blob-dir setting.)

Option 2 (with ZEO): Add via zope-conf-additional in the Zope instance part of your buildout:

zope-conf-additional =
    <zodb_db grak>
      <zeoclient>
        blob-dir ${buildout:directory}/var/blobstorage-grak
        shared-blob-dir on
        server 8100
        storage grak
        name grak_zeostorage
        var ${buildout:directory}/parts/zeoclient1/var
        cache-size 300MB
    </zeoclient>
    mount-point /grak
</zodb_db>

Again, we add blob-dir. The shared-blob-dir setting is also important if you're running ZEO and Zope on the same server and using the same blob directory for both. Also, add to the ZEO part of your buildout (which should use plone.recipe.zeoserver for Plone 4, rather than plone.recipe.zope2zeoserver), something like:

zeo-conf-additional =
    <filestorage grak>
      path ${buildout:directory}/var/filestorage/grak.fs
      blob-dir ${buildout:directory}/var/blobstorage-grak
    </filestorage>

The ZEO configuration also gets a new blob-dir setting. Note that with ZODB3 the syntax is different; I recommend just using option 3...

Option 3 (works for ZEO or non-ZEO): Use collective.recipe.filestorage. Adjust your buildout with the following:

[buildout]
...
parts =
    ...
    filestorage
    instance
# (it's important that filestorage comes before any parts install Zope or ZEO)

[filestorage]
recipe = collective.recipe.filestorage
blob-storage = var/blobstorage-%(fs_part_name)s
parts =
    grak

comment:6 Changed 2 years ago by thet

thanks, thats it. i didn't configure the blobstorage for that mountpoint.

Note: See TracTickets for help on using tickets.