-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong folder size in webview / truncate oc_filecache corrupts share structure in db #10036
Comments
don't truncate that table! Truncating the file cache was a workaround back in the days of OC4! |
Ok, if it's not allowed to truncate this table, how is it possible to force a rebuild of its content? I could delete and recreate the files and then I'm shure the database would be "repaired". |
using files:scan is the way to go - please note that in some cases this is not possible - e.g. some mounted filesystems or in case encryption is enabled. but even without files:scan the filesizes will populate themselves - espacially in your case with that many files it can take some time because the file sizes have to be propagated to the file root |
The rescanning works - it crawles through the whole filesystem. And to be clear: There is no problem with the FILE size - here everything is fine! Is it possible to delete only the cached size of the folders in db and force a recalculation this way? Edit:I had a look in database and found this: And here it comes: Would it be save or possible to delete the whole column "unencrypted_size" if encryption is disabled? |
Ok, the values in "unencrypted_size" have been the clue. Although I have solved my problem now, there has to be a bug in activating and deactivating the encryption app. Or the safest way: One last thing: |
CC @schiesbn |
Size propagation has issues on OC 7.0.4 with shared folders: #14596 @deMattin the encryption app normally calculates unencrypted_size during the initial encryption of every user. If you set it back to 0 it will only recompute it the next time the file is accessed/modified. To recover from this particular situation, one idea is to reset the migration flag in the database for all users: The next time a user will login, the unencrypted_size should be recomputed. Closing as duplicate of #14596 (the size propagation ticket) |
First, sorry for my english ... ;)
The main problem is, that the folder size isn't calculated correct in OC 7 in webview.
And I need some help to repair this.
The try to repair this caused another problem that I only could "repair" with a restoring of my database backup.
Steps to reproduce
I did the following steps:
Filesize itself is always shown correct!
Some of my files are shown as shared by others, my shares link to other files that shouldn't have been shared, ...
The whole sharing structure is linked wrong in database with no chance to repair it in the webview.
There was NO dataloss (>10GB of Data)!
Expected behaviour
Foldersize will show the sum of all files in the folder
AND
truncate filecache shouldn't corrupt shareing structure in database
Actual behaviour
foldersize is shown wrong
"truncate oc_filecache;" corrupts database
Server configuration
Operating system:
'............', 'passwordsalt' => '.........', 'trusted_domains' => array ( 0 => '192.168.192.210', 1 => 'domain.tld', ), 'datadirectory' => '/media/sf_Owncloud-Data', 'dbtype' => 'mysql', 'version' => '7.0.0.8', 'dbname' => 'ocdb', 'dbhost' => 'localhost', 'dbtableprefix' => 'oc_', 'dbuser' => '......', 'dbpassword' => '..................', 'installed' => true, 'forcessl' => true, "overwritehost" => "domain.tld", "overwriteprotocol" => "https", "overwritewebroot" => "owncloud", 'trashbin_retention_obligation' => 180, 'trashbin_auto_expire' => true, 'loglevel' => '2', "remember_login_cookie_lifetime" => 60_60_24_30, 'enable_previews' => true, 'theme' => '', 'maintenance' => false, ); *_Are you using external storage, if yes which one:*\* local/smb/sftp/... no **Are you using encryption:** yes/no no (but had activated it before) ### Client configuration **Browser:** Google Chrome **Operating system:** Windows 7 ### Logs #### Web server error log nothing special #### ownCloud log (data/owncloud.log) some errors like: Error PHP Undefined offset: 2 at /var/www/owncloud/lib/private/share/share.php#1339 2014-07-29T20:48:18+00:00 Error PHP Undefined offset: 1 at /var/www/owncloud/lib/private/share/share.php#1339 2014-07-29T20:42:42+00:00 ... #### Browser log nothing specialDebian 7
Web server:
Apache 2
Database:
MySQL 5.0
PHP version:
5.4.4
ownCloud version: (see ownCloud admin page)
7.0.0.8
Updated from an older ownCloud or fresh install:
updated from well working 6.0.4
List of activated apps:
default
+videoviewer
The content of config/config.php:
The text was updated successfully, but these errors were encountered: