You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

Before you Begin

By default Enterprise Tester stores attachments in the file system from V4.3 and above. Note that the original installation must be V4.3 (released September 2012) and above. In this case, you do not need to make any additional configurations to your system unless you would like to change the default file storage location or the maximum file size. See the Additional Configurations section below.

Where the original installation of ET was a version earlier than 4.3 then the default attachment storage is in the database and you will need to migrate the attachments from the database in addition to making the changes to the web.config file described below. Failure to migrate your attachments from the database after changing the attachment storage method will make those attachments in the database unavailable to users and will leave your system with attachments in both the database and the file system. The migration process described below will not migrate attachments from the database if new attachments are already being stored in the file system. In this case, please contact Catch Support for assistance.

Changing Attachment Storage from Database to File System (Existing installation of ET) only applies to V4.2 and earlier original installations

Enterprise Tester provides a mechanism to migrate between storing attachments in the file system or database for an existing instance of Enterprise. Before commencing, the Enterprise Tester website should be taken offline. The easiest way to do this is to stop IIS or stop the application pool Enterprise Tester belongs to.

Migrating from In-database to the file system

To store attachments in a location other than /Data/Attachments, you will need to add the "attachment.storage.path" setting to the web.config file (ensure the attachment storage method remains the same). Next, start a command prompt, and change the Enterprise Tester bin folder:

cd c:\Program Files\Catch Limited\Enterprise Tester\Web\bin\

Now run the following executable:

AttachmentMigrator.exe

A message similar to the following should appear:

Enterprise Tester Attachment Migration Tool Version 1.0.0.0
 
Current Attachment Storage Configuration: InDatabase
 
This tool will migrate attachments to the new storage location: FileSystemCas
 
WARNING! This operation cannot be reversed, and if it fails, will leave your database in a inconsistent state. Please ensure you have backed up the database before proceeding.
 
To proceed type "yes" and press enter

As the message suggests, you should always backup both your database and web.config file prior to using this tool - as if it fails halfway through, it will leave your Enterprise Tester database in an inconsistent state.

When you are ready type "yes" and press enter.

You will then see progress displayed on screen, and eventually the migration will complete.

Initializing...
 
Initialization Complete.
 
Plugins Folder: c:\Program Files (x86)\Catch Limited\Enterprise Tester\Web\bin
Attachments Folder: c:\Program Files (x86)\Catch Limited\Enterprise Tester\Data\Attachments\
Database Type: SqlServer
 
.......................................  Processed 40/265 (15%)
........................................  Processed 80/265 (30%)
........................................  Processed 120/265 (45%)
........................................  Processed 160/265 (60%)
........................................  Processed 200/265 (75%)
........................................  Processed 240/265 (91%)
.........................
 
Migration completed and web.config file updated, total time: 4.5294003s

Now restart IIS or the application pool, and your attachments will now be stored in the new location.

If you are migrating from file system to in-database storage, you will need to manually delete/archive the attachment files after the migration.

Additional Configurations

Changing the Attachment Storage Location

By default, attachments are stored in the folder ../Data/Attachments/ (so normally c:\Program Files(x86)\Catch Limited\Enterprise Tester\Data\Attachments)

If however you wish store attachments in another location (i.e. if you have a lot of attachments and wish to store them on a NAS disk) you can set the path by adding another entry with the key "attachment.storage.path".

<appSettings>
   <add key="migration.providerName" value="Migrator.Providers.SqlServer.SqlServer2005Dialect" />   
   <add key="attachment.storage.method" value="FileSystemCas" />
   <add key="attachment.storage.path" value="f:\et-attachments\" />
</appSettings>

For more information of appSettings, see the help topic appSettings.

Setting Maximum File Sizes

To support the attachment of very large files change to the configuration of the application are also required. By default Enterprise Tester sets a limit of 64mb for requests. To support attaching larger files you will need to change this value.

In the web.config file, locate this section:

<system.web>
    <httpRuntime executionTimeout="18000" maxRequestLength="65535" />

The value "maxRequestLength" controls the maximum size of requests in kilobytes, changing this to value such as 1024000, will allow you to upload files up to 1gigabyte in size.

  • No labels