Agent's Temp Directory contains a large number of files and takes up a large amount of disk space



Environment Details

  • Java Application
  • Agent version below 4.1.0

Issue Tracking

  • VFUN-14876

Overview of the Issue

This issue occurs in the following circumstances:

  1. An organization installs the vFunction Agent with a version below 4.1.0 on a Java Application
  2. The organization puts the Application in Learning
  3. After a period of time, the organization notices that the disk space is being used at an unexpectedly high rate on the Application Server
  4. Unexpectedly, the ../opt/vfunction/agent/instances/default-java/temp directory contains a large number of snap*.tmp files that have not been removed

Steps to Resolve the Problem

Take the following steps to resolve this issue:

  1. SSH to the VM running the Application
  2. Remove the TMP files in the Agent’s TEMP directory
### Sudo
rm -f /opt/vfunction/agent/instances/default-java/temp/*.tmp

### Sudoless
rm -f vfunction/opt/vfunction/agent/instances/default-java/temp/*.tmp

  1. Upgrade the vFunction Agent to version 4.1.1658 or later
  1. Download the vFunction Controller TGZ
  2. Unpack the TGZ on the VM
### Sudo 
### Replace VERSION with the actual version
sudo tar -Pxvzf vfunction-controller-installation.vVERSION.tgz

### Sudoless 
### Unpack the TGZ in the BASE_DIR where the "vfunction" folder was created
### Replace VERSION with the actual version
tar -xvzf vfunction-controller-sudo-less-installation.vVERSION.tgz
  1. Run the vFunction Upgrade script
### Sudo
sudo bash /opt/vfunction/controller-installation/upgrade.sh -i default-java

### Sudoless
bash vfunction/opt/vfunction/controller-installation/upgrade.sh -i default-java
  1. Restart the Java Application so that the Application picks up the new vFunction Agent version