KB Article #178093
Slow services start due to a known issue in Tomcat
Problem
In some cases (after applying Service Pack 7 for ST 5.2.1 or an upgrade to ST 5.3.3), the services take longer to start (around 3-5 minutes as opposed to 30 seconds to 1 minute before).
Resolution
The particular delay is caused by a known issue in Tomcat, which is often seen in version Apache Tomcat/7.0.68. The delayed start is resolved by following the below steps.
1. Take a backup of the file <FILEDRIVHOME>/bin/update_files.sh
2. Open it in a text editor
3. Find each line like the below one
CLASS="com.tumbleweed.st.server.util.commandline.CertificateFilesGenerationUtil"
4. Add the below line right beneath each occurrence of the above line:
JAVA_OPTS="-Djava.security.egd=file:/dev/./urandom $JAVA_OPTS"
Example of an edited update_files.sh file can be found attached to this article.
5. Restart ST
The update_files.sh script is used to fetch information from the database and create certain certificate files locally on the filesystem during the services initialization. The new line is used to change the SecureRandom (this class provides a cryptographically strong random number generator) to /dev/urandom. Without the line, Java would use /dev/random to seed its SecureRandom class, which can cause Java code to block unexpectedly, thus cause the delays.
IMPORTANT: Note that issue is environment specific and you need to update the 'update_files.sh' script only in case you observe the delay.