Centralized file storage for a load-balanced Telligent website

To set up a centralized file location for a Telligent Community website solution a new configuration file needs to be created. The file needs to be named communityserver_override.config and placed in the root of the website.

In order to override the location for the paths to the shared folder to be used for file storage this new configuration file would need to contain something similar to the following XML:

<?xml version="1.0" encoding="utf-8" ?>
<Overrides>
 <!-- Filestorage -->
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.PostAttachments']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" downloadValidatorType="CommunityServer.Components.PostAttachmentFileAccessValidator, CommunityServer.Components" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.PostAttachments.Temporary']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.SiteFiles']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Blogs.Components.WeblogFiles']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.ImageFileViewer']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.MultipleUploadFileManager']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.UserFiles']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.Ranks']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.Roles']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.Avatars']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.GroupAvatars']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.SelectableAvatars']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Components.GroupSelectableAvatars']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Wikis.Components.Files']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.MailGateway.MailRoom.ForumsHandler']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
 <Override xpath="/CommunityServer/CentralizedFileStorage/fileStore[@name='CommunityServer.Discussions.Components.Files']" mode="change" name="basePath" value="\\{SERVER_NAME}\{FILE_STORAGE_SHARED_FOLDER}" />
</Overrides>

If this file is copied to all the sites that constitute the web farm for this load-balanced Telligent Community website then they will all share the same file storage location for uploads, attachments, avatar images and the like.

It is also a good idea to ensure that there are no folders named filestorage in the root of any of the load-balanced sites and that there contents are all moved to the shared location.

This solution has been tested in Telligent Community 5 and 5.5.

@MobeenAnwar

Author: Mobeen Anwar

Share This Post On

Submit a Comment

Your email address will not be published. Required fields are marked *