core icon indicating copy to clipboard operation
core copied to clipboard

OC8 cron.php failing - createFile() on a non-object - Lucene LockManager

Open razyr opened this issue 11 years ago • 2 comments

We have two OC8 servers. One is an upgrade from OC7. The other is a fresh install.

Both systems are running on CentOS 7, Apache 2.4, PHP 5.4.16, Mariadb 5.5.41 The fresh install has only the default apps installed. The upgrade server has the default plus cal, contacts, tasks. Both systems are using Swift object storage

The servers appear to be functioning normally with the exception of cron.php.

Executing cron.php either through the cron service or the command line and as either the web user or root, the error is identical on both servers.

PHP Fatal error: Call to a member function createFile() on a non-object in /var/www/html/owncloud/apps/search_lucene/3rdparty/zendframework/zendsearch/library/ZendSearch/Lucene/LockManager.php on line 118 Unexpected error!

The fresh install server has very few files and zero traffic at the moment, so looking at the logs we can see

{"reqId":"8920d719253eb919c5b8cda3b32f96c6","remoteAddr":"","app":"objectstore","message":"Could not get object: urn:oid:344 could not be found. The API returned this HTTP response:\n\nHTTP\/1.1 404 Not Found\r\nContent-Length: 70\r\nContent-Type: text\/html; charset=UTF-8\r\nX-Trans-Id: txa27eb59e81d043c2b38b5-0054e34adb\r\nDate: Tue, 17 Feb 2015 14:06:19 GMT\r\nConnection: close\r\n\r\n<html><h1>Not Found<\/h1><p>The resource could not be found.<\/p><\/html>","level":3,"time":"2015-02-17T14:06:19+00:00"} {"reqId":"8920d719253eb919c5b8cda3b32f96c6","remoteAddr":"","app":"PHP","message":"Argument 1 passed to ZendSearch\\Lucene\\LockManager::obtainReadLock() must be an instance of ZendSearch\\Lucene\\Storage\\Directory\\DirectoryInterface, boolean given, called in \/var\/www\/html\/owncloud\/apps\/search_lucene\/3rdparty\/zendframework\/zendsearch\/library\/ZendSearch\/Lucene\/Index.php on line 380 and defined at \/var\/www\/html\/owncloud\/apps\/search_lucene\/3rdparty\/zendframework\/zendsearch\/library\/ZendSearch\/Lucene\/LockManager.php#116","level":3,"time":"2015-02-17T14:06:19+00:00"} {"reqId":"8920d719253eb919c5b8cda3b32f96c6","remoteAddr":"","app":"PHP","message":"Call to a member function createFile() on a non-object at \/var\/www\/html\/owncloud\/apps\/search_lucene\/3rdparty\/zendframework\/zendsearch\/library\/ZendSearch\/Lucene\/LockManager.php#118","level":3,"time":"2015-02-17T14:06:19+00:00"} {"reqId":"a541445484b197cacbf97e1c1a8f3d5d","remoteAddr":"","app":"objectstore","message":"Could not get object: urn:oid:345 could not be found. The API returned this HTTP response:\n\nHTTP\/1.1 404 Not Found\r\nContent-Length: 70\r\nContent-Type: text\/html; charset=UTF-8\r\nX-Trans-Id: tx232a6d81beca4eae892d6-0054e34ce6\r\nDate: Tue, 17 Feb 2015 14:15:02 GMT\r\nConnection: close\r\n\r\n<html><h1>Not Found<\/h1><p>The resource could not be found.<\/p><\/html>","level":3,"time":"2015-02-17T14:15:02+00:00"} {"reqId":"a541445484b197cacbf97e1c1a8f3d5d","remoteAddr":"","app":"PHP","message":"Argument 1 passed to ZendSearch\\Lucene\\LockManager::obtainReadLock() must be an instance of ZendSearch\\Lucene\\Storage\\Directory\\DirectoryInterface, boolean given, called in \/var\/www\/html\/owncloud\/apps\/search_lucene\/3rdparty\/zendframework\/zendsearch\/library\/ZendSearch\/Lucene\/Index.php on line 380 and defined at \/var\/www\/html\/owncloud\/apps\/search_lucene\/3rdparty\/zendframework\/zendsearch\/library\/ZendSearch\/Lucene\/LockManager.php#116","level":3,"time":"2015-02-17T14:15:02+00:00"} {"reqId":"a541445484b197cacbf97e1c1a8f3d5d","remoteAddr":"","app":"PHP","message":"Call to a member function createFile() on a non-object at \/var\/www\/html\/owncloud\/apps\/search_lucene\/3rdparty\/zendframework\/zendsearch\/library\/ZendSearch\/Lucene\/LockManager.php#118","level":3,"time":"2015-02-17T14:15:02+00:00"}

On investigation, the objects urn:oid:344 and urn:oid:345 do not exist in our Swift file system.

The relevant section of oc_appconfig shows

search_lucene enabled no search_lucene installed_version 0.6.0 search_lucene ocsid 168709 search_lucene types filesystem

On the upgraded server it too seems to be trying to access non-existent OIDs. Lucene search is turned on in the other server as shown here in the oc_appconfig data from that server.

search_lucene enabled yes search_lucene installed_version 0.6.0 search_lucene ocsid 168709 search_lucene types filesystem

razyr avatar Feb 17 '15 14:02 razyr

@butonic please have a look - THX

@razyr most probably an issue with search lucene - let's see

DeepDiver1975 avatar Feb 17 '15 14:02 DeepDiver1975

should be reopened in the search_lucene repo

DeepDiver1975 avatar Aug 21 '15 09:08 DeepDiver1975