개발/JAVA

java | org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException

AM0530 2021. 2. 22. 11:22

1. 오류코드 : 

 org.apache.catalina.core.StandardWrapperValve invoke
심각: 경로 []의 컨텍스트 내의 서블릿 [Spring MVC Dispatcher Servlet]을(를) 위한 Servlet.service() 호출이, 근본 원인(root cause)과 함께, 예외 [Request processing failed; nested exception is org.springframework.web.multipart.MaxUploadSizeExceededException: Maximum upload size of 10000000 bytes exceeded; nested exception is org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException: the request was rejected because its size (18745968) exceeds the configured maximum (10000000)]을(를) 발생시켰습니다.
org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException: the request was rejected because its size (18745968) exceeds the configured maximum (10000000)

 

2. 오류원인 : 

지정된 첨부파일 업로드 제한 용량보다, 용량이 더 큰 파일을 첨부함 

 

3. 해결방법 : 

 common-servlet.xml에서 maxUploadSize 조정 

	<bean id="m" class="org.springframework.*********">
		<property name="maxSize">
			<value>20000000</value>
		</property>
	</bean>

<value> </value> 안의 값을 조정하면 된다.