Skip to content

Numeric value out of range: 167 Out of range value for column 'fileid'  #2775

Description

@eshagh

Steps to reproduce

  1. upload file

Expected behaviour

file should be saved

Actual behaviour

Error noting file cannot be saved. Issue is filecache has the maximum number of entries for the INT value in fileid column. Is it possible to change fileid from INT to BIGINT? My initial attempt failed.

Server configuration

Operating system: FreeBSD

Web server: Apache24

Database: MariaDB 10

PHP version: 5.6

Nextcloud version: 11

Updated from an older Nextcloud/ownCloud or fresh install: updated (error manifested as soon as fileid maxed out INT value)

Where did you install Nextcloud from: manual

Signing status:

Signing status
Login as admin user into your Nextcloud and access 
http://example.com/index.php/settings/integrity/failed 
paste the results here.

List of activated apps:

App list
If you have access to your command line run e.g.:
sudo -u www-data php occ app:list
from within your Nextcloud installation folder

The content of config/config.php:

Config report
If you have access to your command line run e.g.:
sudo -u www-data php occ config:list system
from within your Nextcloud installation folder

or 

Insert your config.php content here
(Without the database password, passwordsalt and secret)

Are you using external storage, if yes which one: yes, local (reason for so many file entries)

Are you using encryption: no

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

LDAP configuration (delete this part if not used)

LDAP config
With access to your command line run e.g.:
sudo -u www-data php occ ldap:show-config
from within your Nextcloud installation folder

Without access to your command line download the data/owncloud.db to your local
computer or access your SQL server remotely and run the select query:
SELECT * FROM `oc_appconfig` WHERE `appid` = 'user_ldap';


Eventually replace sensitive data as the name/IP-address of your LDAP server or groups.

Client configuration

Browser:

Operating system:

Logs

Web server error log

Web server error log ``` Insert your webserver log here ```

Nextcloud log (data/nextcloud.log)

Nextcloud log ``` Insert your Nextcloud log here ```

Browser log

Browser log ``` Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log
c) ...

</details>

Activity

  1. MorrisJobke commented on Dec 20, 2016

    @MorrisJobke
    Member

    @karlitschek possible change of the filecache table 🙈

  2. MorrisJobke commented on Dec 20, 2016

    @MorrisJobke
    Member

    @karlitschek possible change of the filecache table 🙈

    Max value is 2.147 billion roughly

  3. karlitschek commented on Dec 20, 2016

    @karlitschek
    Member

    uff. let's be careful here because of the well known migration issues. 👎 for now.

  4. eshagh commented on Dec 20, 2016

    @eshagh
    Author

    It appears that even attempting to remove large swaths of data from the system does not alleviate the problem. I speculate that since there is an entry right at:

    MariaDB [owncloud]> select MAX(fileid) from oc_filecache;
    +-------------+
    | MAX(fileid) |
    +-------------+
    | 2147477186 |
    +-------------+
    1 row in set (0.26 sec)

    That even if previous entries are removed, no new entries may be made since the maximum value has already been reached.

    When I manually convered fileid to BIGINT, the index appeared to restart at 0 and any new data was attempting to overwrite the fileid entry at 0.

    Any suggestions for how to navigate out of this situation, even if that breaks my upgrade path, short of start over?

  5. LukasReschke commented on Jan 6, 2017

    @LukasReschke
    Member

    @karlitschek @MorrisJobke SWITCH seems to face the same problem soon over at owncloud/core#26901 – so this requires some action.

  6. karlitschek commented on Jan 6, 2017

    @karlitschek
    Member

    Hmm. O.K. Then let's merge it. 👍 Any ideas how the smoothen the problem that an alter table on a full file cache table takes forever is welcome.

  7. tessus commented on Sep 14, 2017

    @tessus

    @karlitschek

    Any ideas how the smoothen the problem that an alter table on a full file cache table takes forever is welcome.

    Depending on the database engine, an export and import/load could be faster. One would have to run a few benchmarks though.

  8. MorrisJobke commented on Sep 29, 2017

    @MorrisJobke
    Member

    Fixed with #6563

  9. added this to the Nextcloud 13 milestone on Sep 29, 2017
  10. Claonilton commented on Jun 9, 2019

    @Claonilton

    image

    update oc_filecache set mtime='1538395718' where fileid = 581607;

    mtime -> 1538395718 is one mtime valid
    fileid is the id with problem

  11. kesselb commented on Jun 9, 2019

    @kesselb
    Contributor

    image

    update oc_filecache set mtime='1538395718' where fileid = 581607;

    mtime -> 1538395718 is one mtime valid
    fileid is the id with problem

    @Claonilton Mind to open a new issue? https://docs.nextcloud.com/server/16/admin_manual/configuration_database/bigint_identifiers.html

  12. Claonilton commented on Jun 9, 2019

    @Claonilton

    image
    update oc_filecache set mtime='1538395718' where fileid = 581607;
    mtime -> 1538395718 is one mtime valid
    fileid is the id with problem

    @Claonilton Mind to open a new issue? https://docs.nextcloud.com/server/16/admin_manual/configuration_database/bigint_identifiers.html

    Hi... In my case, is a migration / upgrade of owncloud to nextcloud.

    In doc, the compatible version is nextcloud 12.0 but this command is availabilite in version 13.
    But,... Solved, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions