安裝與組態 > 安裝 ThingWorx > 安裝附錄 > 安裝疑難排解
安裝疑難排解
問題
可能的解決方案
如何在 ThingWorx 中啟用跨原始來源資源共用 (CORS)?
啟用 CORS 可讓您從網域/網站向在不同伺服器上部署之 ThingWorx 的實例發出請求。您可透過更新 Apache Tomcat web.xml 檔案來完成此操作。您可在 https://www.ptc.com/en/support/article?n=CS229450 中找到詳細的流程步驟。
安裝 Tomcat 與部署 Thingworx.war 檔案之後,Composer 不會透過 404 error Application not found 載入
核對在存取 Composer 時使用的埠是否為 Tomcat 上的相應埠
檢查 Proxy 伺服器/重新導向
請核對 <Tomcat directory>/webapps 中的 Thingworx.war 檔案與對應的資料夾是否擁有正確的大小寫 (應為 Thingworx,而非 thingworxThingWorx)
* 
如果資料夾或 WAR 檔案以錯誤的大小寫形式部署,請關閉 Tomcat 伺服器,從 webapp 移除 "thingworx" 資料夾,將 thingworx.war 檔案重新命名為正確的大小寫,然後重新啟動 Tomcat。
核對存取的 URL 是否正確 http://<伺服器>:<埠>/Thingworx (非 http://<伺服器>:<埠>/ThingWorx)
如果在 ThingWorx 安裝之後,在 RHEL 環境中遇到找不到 404 頁這一錯誤,還要核對下列步驟:
核對 JDK 是否存在於 /usr/lib/jvm/ 資料夾中。如果不存在 JDK,則遵循 安裝 Oracle Java 與 Apache Tomcat (RHEL) 中的步驟來安裝 Java
核對 JAVA_HOME 環境變數是否具有 JDK 路徑。例如,
JAVA_HOME = /usr/lib/jvm/jdk1.8.144
部署 thingworx.war 時出現問題。
核對 ThingworxStorage/extensions/web-inf 資料夾是否包含授權物件庫 (DLL 檔案)。
部署 ThingWorx 時收到下列錯誤:

org.apache.catalina.core.ApplicationContext.log HTMLManager:
FAIL - Deploy Upload Failed, Exception:
org.apache.tomcat.util.http.fileupload.FileUploadBase$SizeLimitExceededException:
the request was rejected because its size (90883556)
exceeds the configured maximum (52437800)
java.lang.IllegalStateException:
org.apache.tomcat.util.http.fileupload.FileUploadBase$SizeLimitExceededException:
the request was rejected because its size (90883556)
exceeds the configured maximum (52437800)
at org.apache.catalina.connector.Request.parseParts(Request.java:2871
必須增加 Tomcat web.xml 檔案中的最大檔案大小 (預設值為 50MB)。此檔案位於:
<path to Tomcat>\Apache Software Foundation\Tomcat
8.5\webapps\manager\WEB-INF
1. 開啟 web.xml
2. 將最大檔案大小與最大請求大小變更為 104857600。
3. 儲存並關閉檔案。
4. 重新啟動 Tomcat。
匯入 PTC 授權延伸功能時,會收到下列錯誤訊息:
is licensed but cannot find feature in license.bin file
請造訪 PTC 支援網站上的「管理授權」部份,以確認符合您權益的正確授權檔案。如果您的授權需要進一步協助,請聯絡「授權管理」小組。
嘗試解除部署 ThingWorx 時會收到下列錯誤訊息:
FAIL - Unable to delete [<path to Tomcat>\webapps\Thingworx].
The continued presence of this file may cause problems.
Due to FlxCore64.dll
(<path to Tomcat>\webapps\Thingworx\WEB-INF\extensions\FlxCore64.dll)
在解除部署之前,從 Tomcat 的 Java 組態移除 -Djava.library.path
ConfigurationLog.log 中顯示類似下列的錯誤訊息:
2017-03-10 05:56:07.097-0500 [L: ERROR] [O: ] [I: ] [U: SuperUser] [S: ]
[T: localhost-startStop-1]
**********LICENSING ERROR ANALYSIS
2017-03-10 05:56:07.097-0500 [L: ERROR] [O: ] [I: ] [U: SuperUser] [S: ]
[T: localhost-startStop-1]
/Library/flexs is listed as a java.library.path but it does not exist.
/Library/blah is listed as a java.library.path but it does not exist.
/Library/zzz is listed as a java.library.path but it does not exist.
No flx dll files found.
Is the java.library.path set?
2017-03-10 05:56:07.097-0500 [L: ERROR] [O: ] [I: ] [U: SuperUser] [S: ]
[T: localhost-startStop-1]
**********END LICENSING ERROR ANALYIS
記錄檔訊息會核對授權檔案是否存在問題。
平台啟動時,會擲回類似下列的錯誤訊息:

2017-06-12 11:33:59.204+0530 [L: ERROR] [O: c.t.s.s.l.LicensingSubsystem]
[I: ] [U: SuperUser]
[S: ] [T: localhost-startStop-1] [message: The size of provided data is incorrect.]
2017-06-12 11:33:59.205+0530 [L: ERROR] [O: c.t.s.s.l.LicensingSubsystem] [I: ]
[U: SuperUser] [S: ] [T: localhost-startStop-1] ======================================
2017-06-12 11:33:59.205+0530 [L: ERROR] [O: c.t.s.s.l.LicensingSubsystem] [I: ]
[U: SuperUser] [S: ] [T: localhost-startStop-1]
Invalid License file: /ThingworxPlatform\license.bin
2017-06-12 11:33:59.205+0530 [L: ERROR] [O: c.t.s.s.l.LicensingSubsystem] [I: ]
[U: SuperUser] [S: ] [T: localhost-startStop-1] ======================================
2017-06-12 11:33:59.205+0530 [L: WARN] [O: c.t.s.ThingWorxServer] [I: ]
[U: SuperUser] [S: ] [T: localhost-startStop-1] Shutting down the Platform.
授權檔案可能已在瀏覽器中開啟/編輯/儲存。再次下載授權檔案,將其重新命名為 license_capability_response.bin,並置於 ThingworxPlatform 資料夾中,而不進行編輯或儲存。