sqlite error
Expected behaviour
No sqlite error :)
Actual behaviour
Sqlite error occurs during syncing, which results in many PROPFIND commands sending to server (for each subdirectory). Sqlite db file has 0B.
Using "reset" button doesn't help - sqlite db file was deleted but sync-client behave like above and sqllite db file still has 0B.
Stopping sync-client and manual deleting sqlite db file back everything to normal.
Steps to reproduce
- Run syncing
- Wait
Server configuration
Operating system: Rhel 6.4
Web server: Apache 2.2.15
Database: mysql
PHP version: 5.3.3
ownCloud version: 5.0.7 (stable)
Storage backend: GFS2
Client configuration
Client version: 1.3
Operating system: Fedora 17
OS language: Polish
Installation path of client: Standard
Logs
Please use Gist (https://gist.github.com/) or a similar code paster for longer logs.
- Output of
owncloud --logwindoworowncloud --logfile log.txt
06-28 15:19:37:306 void Mirall::CSyncThread::startSync() Sync finished
06-28 15:19:37:488 csync_statedb_query: sqlite_step error: disk I/O error - on query: CREATE TABLE IF NOT EXISTS metadata(phash INTEGER(8),pathlen INTEGER,path VARCHAR(4096),inode
INTEGER,uid INTEGER,gid INTEGER,mode INTEGER,modtime INTEGER(8),type INTEGER,md5 VARCHAR(32),PRIMARY KEY(phash));
06-28 15:19:37:827 csync_statedb_query: sqlite_step error: database disk image is malformed - on query: CREATE TABLE IF NOT EXISTS version(major INTEGER(8),minor INTEGER(8),patch I
NTEGER(8),custom VARCHAR(256));
06-28 15:19:37:827 _merge_and_write_statedb: Unable to write statedb:
06-28 15:19:37:827 csync_commit: Merge and Write database failed!
06-28 15:19:37:831 csync_commit: Journal: /home/jacek/Muzyka/.csync_journal.db
06-28 15:19:37:831 _csync_statedb_check: sqlite version mismatch
06-28 15:19:37:910 csync_statedb_load: statedb doesn't exist
Ok, Everything was fine until next restart :(
Sqlite version is 3.7.11.
I got this error in log:
06-28 15:48:45:379 csync_statedb_query: sqlite_step error: database disk image is malformed - on query: SELECT md5 FROM metadata WHERE phash='-1590195463067021415'
06-28 15:48:45:379 csync_ftw: Uniq ID from Database: hey - cudownie.mp3 -> <NULL>
06-28 15:48:45:379 csync_walker: file: /home/jacek/Muzyka/hey - cudownie.mp3
06-28 15:48:45:379 _csync_detect_update: ==> file: hey - cudownie.mp3 - hash 16856548610642530201, mtime: 1372163551
06-28 15:48:45:379 _csync_detect_update: Database entry found, compare: 1372163551 <-> 1372163551, md5: (null) <-> 51cd48ee4eeb1
06-28 15:48:45:379 _csync_detect_update: file: hey - cudownie.mp3, instruction: INSTRUCTION_EVAL <<=
06-28 15:48:45:379 csync_statedb_query: sqlite_step error: database disk image is malformed - on query: SELECT md5 FROM metadata WHERE phash='1944164534839112641'
06-28 15:48:45:379 csync_ftw: Uniq ID from Database: hey - o drugim policzku.mp3 -> <NULL>
06-28 15:48:45:379 csync_walker: file: /home/jacek/Muzyka/hey - o drugim policzku.mp3
06-28 15:48:45:379 _csync_detect_update: ==> file: hey - o drugim policzku.mp3 - hash 1944164534839112641, mtime: 1358539536
06-28 15:48:45:379 csync_statedb_query: sqlite_step error: file is encrypted or is not a database - on query: SELECT * FROM metadata WHERE phash='1944164534839112641'
06-28 15:48:45:379 csync_statedb_query: sqlite_step error: file is encrypted or is not a database - on query: SELECT * FROM metadata WHERE inode='940755'
06-28 15:48:45:379 _csync_detect_update: file: hey - o drugim policzku.mp3, instruction: INSTRUCTION_NEW <<=
06-28 15:48:45:379 csync_statedb_query: sqlite_step error: file is encrypted or is not a database - on query: SELECT md5 FROM metadata WHERE phash='-7243969167491741880'
06-28 15:48:45:379 csync_ftw: Uniq ID from Database: hey - empty page.mp3 -> <NULL>
and on the end
06-28 15:48:46:914 csync_statedb_get_below_path: SQL: SELECT phash, path, inode, uid, gid, mode, modtime, type, md5 FROM metadata WHERE path LIKE('Myslovitz/%')
06-28 15:48:46:914 csync_statedb_query: sqlite_step error: file is encrypted or is not a database - on query: SELECT phash, path, inode, uid, gid, mode, modtime, type, md5 FROM met
adata WHERE path LIKE('Myslovitz/%')
06-28 15:48:46:914 csync_dbtree_opendir: Query result list is NULL!
06-28 15:48:46:914 csync_ftw: opendir failed for ownclouds://host.coml/remote.php/webdav/muzyka/Myslovitz - (errno 2)
06-28 15:48:46:914 oc_module: closedir method called 0x7f1a8c167460!
06-28 15:48:46:914 #### ERROR during csync_update : "CSync nie mógł odnaleźć określonego pliku."
06-28 15:48:46:924 csync_commit: Journal: /home/jacek/Muzyka/.csync_journal.db
06-28 15:48:46:926 _csync_statedb_check: Integrity check failed!
06-28 15:48:47:019 csync_statedb_load: statedb doesn't exist
06-28 15:48:47:019 CSync run took 1641 Milliseconds
06-28 15:48:47:019 -> CSync Finished slot with error true
06-28 15:48:47:019 ** error Strings: ("CSync nie mógł odnaleźć określonego pliku.")
06-28 15:48:47:019 * owncloud csync thread finished with error
06-28 15:48:47:019 Starting Event logging again in 2000 milliseconds
06-28 15:48:47:019 OO folder slotSyncFinished: result: 5
client version 1.4 will contain a more robust database write routine, could you either retest with a nightly build or the beta version which we will release later this week? Thanks.
Closing, this should be fixed now.