owncloud-archive / rados

Use CEPH as primary storage via librados
15 stars 7 forks source link

Could not create object: Could not write to 'urn:oid:20' #1

Open alexm opened 9 years ago

alexm commented 9 years ago

Steps to reproduce

  1. ceph osd pool create owncloud 512 512
  2. chmod go+rX /etc/ceph /etc/ceph/ceph.conf /etc/ceph/ceph.client.admin.keyring
  3. Install phprados and restart apache so rados extension is loaded.
  4. cd /var/www/owncloud/apps && git clone https://github.com/owncloud/rados.git
  5. cd /var/www/owncloud && sudo -u www-data php occ app:enable rados
  6. Browse http://www.example.com/owncloud/index.php/apps/files/
  7. Upload a file.

    Expected behaviour

File should be uploaded to ceph pool named owncloud.

Actual behaviour

Error is shown: Could not create object: Could not write to 'urn:oid:20'

Server configuration

Operating system: ubuntu server 14.04.3

Web server: apache2 2.4.7-1ubuntu4.5

Database: mysql-server 5.5.44-0ubuntu0.14.04.1

PHP version: php5 5.5.9+dfsg-1ubuntu4.11

ownCloud version: 8.1.3 (stable)

Updated from an older ownCloud or fresh install: new install

List of activated apps:

Enabled:
 - activity: 2.0.2
 - files: 1.1.10
 - files_external: 0.2.3
 - files_locking: 
 - files_pdfviewer: 0.7
 - files_sharing: 0.6.2
 - files_texteditor: 0.4
 - files_trashbin: 0.6.3
 - files_versions: 1.0.6
 - files_videoviewer: 0.1.3
 - firstrunwizard: 1.1
 - gallery: 0.6.0
 - provisioning_api: 0.2
 - rados: 0.0.1
 - templateeditor: 0.1
 - updater: 0.6
Disabled:
 - encryption
 - external
 - user_external
 - user_ldap
 - user_webdavauth

The content of config/config.php:

$CONFIG = array (
  'instanceid' => 'oc8n4e86xbqo',
  'passwordsalt' => '...',
  'secret' => '...',
  'trusted_domains' => 
  array (
    0 => 'www.example.com',
  ),
  'datadirectory' => '/var/www/owncloud/data',
  'overwrite.cli.url' => 'http://www.example.com/owncloud',
  'dbtype' => 'mysql',
  'version' => '8.1.3.0',
  'dbname' => 'owncloud',
  'dbhost' => 'localhost',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'owncloud',
  'dbpassword' => '...',
  'logtimezone' => 'UTC',
  'installed' => true,
  'loglevel' => 1,
  'objectstore' => 
  array (
    'class' => 'OCA\\Rados\\RadosStore',
    'arguments' => 
    array (
    ),
  ),
);

Are you using external storage, if yes which one: no

Are you using encryption: no

Are you using an external user-backend, if yes which one: no

Client configuration

Browser: Firefox 41.0

Operating system: ubuntu desktop 15.04

Logs

Web server error log

www.example.com:80 1.2.3.4 - - [22/Sep/2015:14:10:21 +0200] "POST /owncloud/index.php/apps/files/ajax/upload.php HTTP/1.1" 200 931 "http://www.example.com/owncloud/index.php/apps/files?dir=%2Fdirectori" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:40.0) Gecko/20100101 Firefox/40.0"

ownCloud log (data/owncloud.log)

{"reqId":"mBWJJtLFPg\/EZPrs9\/ov","remoteAddr":"1.2.3.4","app":"objectstore","message":"Could not create object: Could not write to 'urn:oid:20'","level":3,"time":"2015-09-22T12:10:21+00:00"}
alexm commented 9 years ago

FWIW, I tried all examples in https://github.com/ceph/phprados/tree/master/examples (had to tweak some bits) and they did work fine. So it seems that phprados is working fine and I'm starting to wonder if I need to run oc 8.2.x instead of current stable.

distributedOne commented 9 years ago

I do have a work-around for this issue:

https://gist.github.com/jgalvez/694f506877bf6f408aa0

However, I have no idea why this works.

alexm commented 9 years ago

But it actually did work for me too :+1: