|
||
Kentico allows you to modify the size of files in Media libraries that you want to stage. You can set the size in order to avoid too large files from being synchronized. You may also want to modify the values in order to stage files larger than the values set by default.
1. On both the target and source server, open the web.config file located in the root of the website.
2. Modify the value of the maxRequestLength property. The value is in kilobytes.
...
<system.web> ...
<httpRuntime maxRequestLength="2097151" ... />
... </system.web>
... |
3. Add the following code into the system.webServer part of the web.config file. The value of maxAllowedContentLength is in bytes.
Note that there are two system.webServer parts in the web.config file by default. The first one is related to WebDav configuration. Enter the code into the second part.
...
<system.webServer> ...
<security> <requestFiltering> <requestLimits maxAllowedContentLength="2147483648" /> </requestFiltering> </security>
... </system.webServer>
... |
By default, IIS limits this value to 30000000 bytes (28.6 megabytes). Synchronizing files larger than the set value results in an HTTP status 404: Not Found error.
4. Save the web.config file.
To limit the maximum size of a file staged from the media library:
1. On the source server, open the web.config file located in the root of the website.
2. Add the following key into the file. The value is entered in kilobytes.
Note that files above the limit aren't synchronized and the tasks including the files leave the task list. The system transfers database definitions of the files only. You can find a record of the file not being synchronized in the Event log.
<add key="CMSMediaFileMaxStagingSize" value="102400" /> |
3. Save the web.config file.