Friday, February 13, 2015

SDL Tridion: Which folders do we need to ensure to exclude from anti-virus scanning to publish items successfully?

 Many times, I have come across publishing issues due to one of the error messages below:

ERROR HTTPSTransportConnector - Unable to execute HTTP POST
java.io.FileNotFoundException: D:\Tridion\bin\transactions\tcm_0-4074583-66560.Content.zip (The system cannot find the file specified)
    at java.io.FileInputStream.open(Native Method) ~[na:1.6.0_22]
    at java.io.FileInputStream.<init>(Unknown Source) ~[na:1.6.0_22]
    at org.apache.http.entity.mime.content.FileBody.writeTo(FileBody.java:100) ~[httpmime.jar:4.1.2]
    at org.apache.http.entity.mime.HttpMultipart.doWriteTo(HttpMultipart.java:206)

(...)

or

java.io.IOException: The process cannot access the file because another process has locked a portion of the file
    at java.io.FileInputStream.readBytes(Native Method)
    at java.io.FileInputStream.read(Unknown Source)
    at com.tridion.util.FileUtils.readFile(FileUtils.java:370)
    at com.tridion.util.FileUtils.readFile(FileUtils.java:352)
    at com.tridion.util.FileUtils.readFile(FileUtils.java:339)
   at Codemesh.JuggerNET.NTypeValue.Throw(Int64 inst)


These messages can happen when having an active anti-virus that is randomly locking and/or removing files that the Publisher/Transport and Deployer need to process packages. To avoid seeing similar error messages, ensure to exclude the folders mentioned below:
  • On the Content Manager servers exclude:
    • the root storage folder for the Publisher (by default, C:\temp) defined under Tridion Content Manager Snap-in > Publisher Settings;
    • the temporary path location (by default, C:\Windows\TEMP) defined under Tridion Content Manager Snap-in > General Settings;
    • the tridion_home location;
  • On the Content Deployer servers exclude: 
    • the incoming folder location defined on your cd_deployer_conf.xml;
    • the temporary location that the deployer uses to unzip packages, by default , the locate defined in the java.ip.tmpDir variable (c:\windows\temp or c:\temp or c:\Users\<username>\AppData\Local\Temp\1);
    • the TempFileSystemTransactionLocation set in each cd_storage_conf.xml - if multiple deployers are running on the same server;
    • the tridion_home location; 
Note: For security reasons, if your company cannot exclude c:\windows\temp and c:\temp from scanning, you can choose for the following approach:
  • For the Content Manager server in the :
    • Tridion Content Manager Snap-in > Publisher Settings - change the root storage folder to a separate location from the default C:\temp;
    • Tridion Content Manager Snap-in > General Settings - change the temporary path location to a separate location from the default C:\Windows\TEMP; 
  • For the Content Deployer server, you can specify  a different temporary location where the deployer will unzip the packages, by adding the element TempFileSystemTransactionLocation, for example:
<Storages TempFileSystemTransactionLocation="c:\tridion\deployer">

No comments: