nested exception is java.io.IOException: The temporary upload location

Once a request post interfaces Times
Org.springframework.web.multipart.MultipartException: Could not the parse multipart the servlet Request; nested Exception IS java.io.IOException:
at The the Upload the Temporary LOCATION [/tmp/tomcat.2785206180241401379.8032/work/Tomcat/localhost/ ROOT] is not valid
check the file directory, the file does not, check the code, also found no problems. Really do not know why, only to restart the server, the problem no longer occurs. The reason is later found centos system will clean up the / tmp folder, the solution
1. Set centos do not clean up your folders
increase -Djava.io.tmpdir = / opt when 2.jar package start / projecttmp locate the temporary directory to another path.


Guess you like

Origin www.cnblogs.com/zhuyeshen/p/12197100.html