Can I change the upload temp directory on Windows?

200 views
Skip to first unread message

JP

unread,
Oct 12, 2015, 1:54:31 PM10/12/15
to Railo
I've got a Railo app that allows users to upload very large files. I just noticed that my system drive is full because Railo is using C:\railo\tomcat\temp to store temporary upload files. The files are named "temporary-stream-<number>" and there are a lot of them. There's also an empty file named safeToDelete.tmp, which I assume means that all the files are safe to delete.

Is there a way to change the location of this folder?

Andrew Dixon

unread,
Oct 12, 2015, 4:29:21 PM10/12/15
to ra...@googlegroups.com
Hi,

If you look in the catalina.bat file (in the [RAILO_BASE_DIR]/bin/) you will find a variable called CATALINA_TMPDIR and this is used to set this directory at startup, something like:

if not "%CATALINA_TMPDIR%" == "" goto gotTmpdir
set "CATALINA_TMPDIR=%CATALINA_BASE%\temp"

If you want to change it hard code a value for CATALINA_TMPDIR above this line, e.g.

CATALINA_TMPDIR="D:\my_new_temp_folder"

and that should fix it for you.

FYI, Railo is now basically a dead project, head on over to Lucee (http://lucee.org) for the latest updates, including some security patches.

Kind regards,

Andrew

On 12 October 2015 at 18:54, JP <jo...@redtopia.com> wrote:
I've got a Railo app that allows users to upload very large files. I just noticed that my system drive is full because Railo is using C:\railo\tomcat\temp to store temporary upload files. The files are named "temporary-stream-<number>" and there are a lot of them. There's also an empty file named safeToDelete.tmp, which I assume means that all the files are safe to delete.

Is there a way to change the location of this folder?

--
Did you find this reply useful? Help the Railo community and add it to the Railo Server wiki at https://github.com/getrailo/railo/wiki
---
You received this message because you are subscribed to the Google Groups "Railo" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/railo/8690149e-1bb6-47d7-b237-ae652e1b78e2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

JP

unread,
Oct 12, 2015, 10:39:14 PM10/12/15
to Railo
I found a better way to do it... open up the Railo-Tomcat Server Settings program, go to the Java tab, and change the temp directory.

Yes, I'm aware Railo is dead... Thanks!

-JP
Reply all
Reply to author
Forward
0 new messages