More in this section
Forums / General Discussions / SF_CHUNKS table size

SF_CHUNKS table size

The forums are in read-only mode. In case that you want to directly contact the Progress Sitefinity team use the support center. In our Google Plus group you can find more than one thousand Sitefinity developers discussing different topics. For the Stack Overflow threads don’t forget to use the “Sitefinity” tag.
5 posts, 0 answered
  1. Jared
    Jared avatar
    122 posts
    04 Apr 2013
    14 Oct 2013
    Link to this post
    Is there a recommended way to minimize the size of the sf_chunks table?  It is currently around 2 GB, which is half the size of our entire DB.  Any thoughts or suggestions would be appreciated!
  2. Craig
    Craig avatar
    82 posts
    07 Apr 2009
    14 Oct 2013 in reply to Jared
    Link to this post
    I am 99% sure this is where were all BLOBs (Binary Large Objects) are stored in Sitefinity.  Anything you store under Images, Video, or Documents will be stored in the database by default.

    One way of reducing the size of this file could be to store these files on the file system.  Any top level library will allow you to change the storage location by going to Actions > Move to another storage.  Select File System and the files will be moved from inside the database to you file system under /App_Data/Storage/FileSystem.  This is the default location but this can be changed.

    Hope this helps.

  3. Stanislav Velikov
    Stanislav Velikov avatar
    1113 posts
    18 Sep 2017
    16 Oct 2013
    Link to this post

    The table sf_chunks contains the binary data for the uploaded documents on the site, each document,  binary data is split into chunks with a certain size stored in this table, the table gets updated when a document is deleted so I suppose the media contents on the site is matching the size of the table and check if this is true execute the query below to check the sizes of all uploaded media content (the size is in bytes).
    LibrariesManager manager = LibrariesManager.GetManager();
           var docs = manager.GetDocuments();
           long allDocumentsSize = 1L;
           foreach (var item in docs)
               //the size is in bytes
               allDocumentsSize += item.TotalSize;

    As Craig mentions the default location for storing binary data is database and can be changed to file system or external storage provider like dropbox (sample provider for dropbox is available in sitefinity SDK, DropboxLibraries provider), azure storage provider or amazon S3 storage.

    Stanislav Velikov
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  4. jason
    jason avatar
    3 posts
    04 May 2009
    08 Oct 2014 in reply to Stanislav Velikov
    Link to this post

    External Storage option does not work properly. Choosing Azure Storage if you put images in a root level library, and then put images in a sub-library with the same names, Sitefinity puts them both in a folder with the name of the root level library. So you cannot have images with the same name in sublibraries.


    Local file system is not an option for a clustered environment. 

    Database storage is expensive, and I'm experiencing large load on queries to sf_chunks table. Some responses are taking up to 30 seconds. Sure would be nice to use Azure Storage and CDN instead.


  5. Stefani Tacheva
    Stefani Tacheva avatar
    718 posts
    31 May 2017
    09 Oct 2014
    Link to this post

    I have marked this bug as important for clients and I hope that we will be able to address it soon:

    You could follow the item in order to receive notifications when the status of the items is changed.

    Excuse us for the inconvenience.

    Stefani Tacheva
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
5 posts, 0 answered