Managing File Types and Sizes in SharePoint 2010

Good SharePoint governance policies will frequently containing operational directives regarding both the type and size of files that can be stored on SharePoint 2010.
Being able to control the types of files is essential to any organization to ensure that only the correct type of content is stored within the platform. Many organizations encourage their users to move content to SharePoint, however they do not want users moving their entire ITunes library or video collection to the platform.
Another issue is of maximum file size. The ability to control the maximum size of file that can be uploaded to SharePoint is a must for many organizations. In MOSS 2007 database administrators were frequently hesitant to store large files within SharePoint simply due to the fact that databases are not optimized for the storage of large BLOB files. Although Remote Blob Storage provides a great deal of flexibility where BLOB files can now be stored we still want a mechanism to control the maximum size of files.
So our problem statement is “Can we control both the type and size of content that gets stored within SharePoint 2010?”

The Solution – Blocked File Types and Maximum File Size

SharePoint 2010 comes with some out of the box tools to help us solve the issue that we have.

Configuring Block File Types

Ton configure the types of file that we would like to block navigate the Central Administration->Security->Define Block File Types


From here we can choose to define the various types of files that we will not allow user to upload. Just enter in one per line. For this example I am going to add zip files so users will not be able to upload zip files.

You don’t need to put the dot in front of the extension and also these settings apply to the entire Web Application. Keep in mind that SharePoint 2010 also blocks about a 100 file types by default as well.



 Now if a user tries to upload a file that is blocked they will receive nice informative error message:
















Configuring Maximum File Sizes

Configuring maximum file sizes is just as easy but done in a slightly different location within Central Administration. Navigate to Central Administration->Manage Web Applications->Select your Web Application->General Settings



 At the bottom of the page is your Maximum Upload Size. Set it to whatever value you like and press OK. The default value for a Web Application is 50MB in case you were wondering:




 Now if a user uploads a file size greater than the allowable maximum they will receive an error:





Other thoughts

As you can see it’s quite easy to configure these setting from an Administrator perspective and it will help you govern your environment. However a few important things to note:
  • The maximum file size is subject across all files, you cannot configure individual file types to different sizes.
  • Frequently a Digital Asset Management system will exist in its own Site Collection because it will need to have a higher maximum upload file size than other content within a SharePoint installation
  • Since these settings are at the Web Application level all Site Collections will be subject to the file type and size restriction
  • RBS has a hard limit of 2GB. Regardless of whether you are using RBS or a SQL database you will only be able to retrieve a 2GB file.