SRM:import-properties 工作有下列錯誤:com.mysql.jdbc.exceptions.jdbc4.CommunicationsException:通訊連結故障

요약: 如果導入通道任務由於 apg 資料庫負載過重而在套接字超時時持續失敗,則可以增加 socketTimeout。

이 문서는 다음에 적용됩니다. 이 문서는 다음에 적용되지 않습니다. 이 문서는 특정 제품과 관련이 없습니다. 모든 제품 버전이 이 문서에 나와 있는 것은 아닙니다.

증상

匯入屬性工作在與 apg 資料庫的連線時出現以下錯誤:
160627 07:07:57 : com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
160627 07:07:57 :
160627 07:07:57 : The last packet successfully received from the server was 180,025 milliseconds ago. The last packet sent successfully to the server was 180,025 milliseconds ago.

異常的原因是:
aused by: java.net.SocketTimeoutException:讀取逾時

在此特定情況下,APG/Web-Servers/Tomcat/Default/conf/server.xml 中為每個資料庫設定的 socketTimeout 設定為 180000 毫秒。

원인

socketTimeout 將用於導入屬性任務中,以等待從data_property表中提取數據。如果由於當時資料庫負載過重而超過此時間,則任務將失敗。

해결

我們可以將 APG/Web-Servers/Tomcat/Default/conf/server.xml 檔案中的 socketTimeout 設定增加為例如 5 分鐘 (300000 毫秒),如下所示:
<!-- Defines the connection to the APG timeseries database for MySQL. -->
	<Resource name="jdbc/APG-DB" auth="Container" type="javax.sql.DataSource" maxActive="20" maxIdle="20" validationQuery="SELECT 1" testOnBorrow="false" testWhileIdle="true" validationQueryTimeout="5" timeBetweenEvictionRunsMillis="10000" minEvictableIdleTimeMillis="60000" maxWait="30000" username="apg" password="watch4net" driverClassName="com.mysql.jdbc.Driver" removeAbandoned="true" removeAbandonedTimeout="60" logAbandoned="true" url="jdbc:mysql://<db hostname>:53306/apg?autoReconnect=true&socketTimeout=300000"/>
 

해당 제품

SRM
문서 속성
문서 번호: 000059197
문서 유형: Solution
마지막 수정 시간: 29 7월 2025
버전:  4
다른 Dell 사용자에게 질문에 대한 답변 찾기
지원 서비스
디바이스에 지원 서비스가 적용되는지 확인하십시오.