Skip to main content
1-Visitor
November 20, 2019
Solved

logging no longer works after tomcat upgrade

  • November 20, 2019
  • 1 reply
  • 8702 views

Hi, we do have a yet another delightful problem with ThingWorx. We have updated Tomcat from 8.0 to 8.5. 

We have changed server config file as instructed and java properties in tomcat config utilities. 

We deployed ThingWorx into the new Tomcat (coppied war file, autodeploy true by default) 

Everything works fine except for the fact that platform is no longer logging anything into the log files. 

No script log, no application log no nothing. 

 

Anyone any help. 

I am very exhausted to debug such a software.... 

Best answer by tcoufal

Hi there,

sorry for delayed answer. It was very hectic at the end of the year. 

So..

After some back and forth it turned out that it was indeed a permission issue after all. 

For some reason Tomcat 8 install it self as (rather "under account of") local system, but 8.5 as local service. Difference is that local service has R/W permissions (that is why Import/Export in/from ThingworxStorage/repository worked, as well validation.properties file has been created after startup), but local system has full access permissions. I dont why that is necessary, but it is. 

We changed under which account Tomcat has to run and now everything works. 

It was not obvious because there were no errors in tomcat log files.

 

1 reply

22-Sapphire I
November 21, 2019

Any errors listed in the catalina.log (my guess is that application log is blank)

You've probably already check the permissions on the ThingworxStorage folder and its subfolders?

tcoufal1-VisitorAuthor
1-Visitor
November 21, 2019

Catalina log (not complete):

20-Nov-2019 22:05:36.532 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"]
20-Nov-2019 22:05:36.563 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["https-jsse-nio-443"]
20-Nov-2019 22:05:36.563 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"]
20-Nov-2019 22:05:36.563 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in 110408 ms
20-Nov-2019 22:07:03.115 INFO [https-jsse-nio-443-exec-102] org.apache.tomcat.util.http.parser.Cookie.logInvalidHeader A cookie header was received [255,255; color_1=192,192,192; color_2=128,128,128; color_3=0,0,0; color_4=191,48,48; color_5=249,239,107; color_6=102,204,51; color_7=51,153,255; color_8=27,60,132; color_9=153,102,153; JSESSIONID=EF920AD216E3C090BFD3A07235AF7A9F; PD-HOST=portal.skoda-auto.com; PD-NET=internet] that contained an invalid cookie. That cookie will be ignored.
Note: further occurrences of this error will be logged at DEBUG level.
log4j:WARN No appenders could be found for logger (org.apache.http.client.protocol.RequestAddCookies).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.

 

 

Tomcat runs under the same user as previous version of tomcat so I guess that permission is not an issue. 

Plus - Export, IMport, Repository all works, if permission would be the issue none of that would work as well right? Repository is also under ThingworxStorage. ESAPI file was also created after Tomcat started.  

Community Manager
November 21, 2019

Hi @tcoufal.

 

Which version of ThingWorx are you running and which exact version of Tomcat did you upgrade to?  What platform are you running on?  In Composer, do you see logs under Monitoring?

 

I am happy to open a case on your behalf in order to work with a Support engineer on a solution.

 

Regards.

 

--Sharon