Clearing Temporary Files to Resolve Disk Space Issues on Application Server

Disclaimer: The information provided in this article is for general informational purposes only. The author and the publisher do not guarantee the accuracy, completeness, or reliability of the information. The techniques and suggestions mentioned may cause harm if not implemented correctly. The author and the publisher are not liable for any damages resulting from the use or misuse of the information. Use your own judgment and exercise caution when applying the suggestions in this article. Always consult official documentation and experts, and test changes in a controlled environment before applying them to production systems. By using this information, you agree to hold the author and the publisher harmless from any liability or claim.

 

Applies To:

  1. Environments running web-based enterprise applications
  2. Application servers generating temporary files in a specific folder (e.g., orchid_tmp)
  3. Systems where login to the administrator console fails due to insufficient disk space
  4. Users of performance testing and load generation platforms installed on Windows servers.

 

Issue:

An application server ran out of disk space, resulting in the inability to sign in to the administrator interface. The issue was caused by the accumulation of temporary files in a directory used by the application to store runtime data.

This impacted normal operation of the application, including administrative access and functionality.

 

Cause:

The root cause was the continuous growth of temporary files in a specific folder (e.g., orchid_tmp). These files were not being automatically cleaned up, eventually consuming all available disk space.

As a result:

  1. The application could not operate normally
  2. Access to the admin console was blocked
  3. System performance degraded due to low disk space

 

Steps:

  1. Identify Disk Usage
    • Log in to the server via RDP or a remote management tool.
    • Use disk management utilities (e.g., TreeSize, WinDirStat, or built-in tools) to identify large folders consuming space.
  2. Locate Temporary Folder
    • Navigate to the application's temp directory. For example:
      • C:\Program Files (x86)\...\orchid_tmp
  3. Clean Up Temporary Files
    • Safely delete files from the temp folder except for critical files like:
      • web.config
      • Any folders named bin or essential configuration files
    • Deleting only unnecessary runtime-generated files will avoid service disruption.
  4. Schedule Automatic Cleanup
    • Create a script (e.g., PowerShell or batch) to clear the contents of the temp folder on a daily basis.
    • Example PowerShell snippet:
      • Get-ChildItem "C:\Path\to\orchid_tmp" -Recurse |
      • Where-Object { $_.Name -notin @('web.config', 'bin') } |
      • Remove-Item -Force -Recurse
    • Schedule the script using Task Scheduler to run once per day (e.g., during off-peak hours).
  5. Validate and Monitor
    • Confirm that disk space is freed.
    • Verify that the application and admin console are accessible again.
    • Monitor disk usage regularly to prevent recurrence.

 

Additional Info:

  1. The orchid_tmp folder (or its equivalent in other applications) is often used to store temporary cache and runtime data.
  2. Deleting critical configuration files such as web.config or application binaries may break the application. Always verify what is being removed.
  3. Regular maintenance tasks like scheduled cleanup scripts are essential for system health.
  4. System alerts for low disk space thresholds can help identify issues before they become critical.

 

We hope this article provided you with the assistance you needed. If you would like to find out more regarding the Services and Support Offerings we provide, please reach out to our Sales Team.

Have more questions? Submit a request

0 Comments

Article is closed for comments.