2
respostas

Aplicação não abre.

Estou com problemas para subir a aplicação da loja. Já rodei o comando:

sudo mysql -u root -e "ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY''; FLUSH PRIVILEGES;"

Mas retornou o seguinte:

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

Quando tento abrir a Url/loja na porta 8080, só me retorna erro 404.

Seguem os logs do mysql:

ubuntu@ip-172-31-86-197:/var/log/mysql$ cat error.log
2019-02-06T16:45:09.616862Z 12 [Note] Unknown database 'projeto_jpa'
2019-02-06T16:45:10.505547Z 13 [Note] Unknown database 'projeto_jpa'
2019-02-06T16:45:10.778425Z 14 [Note] Unknown database 'projeto_jpa'
2019-02-06T16:45:10.797139Z 15 [Note] Unknown database 'projeto_jpa'
2019-02-06T16:47:27.277860Z 16 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2019-02-06T16:47:52.085161Z 17 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2019-02-06T16:48:11.459601Z 18 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2019-02-06T16:48:34.079842Z 19 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2019-02-06T16:49:25.507800Z 20 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2019-02-06T16:49:58.070963Z 21 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2019-02-06T16:58:19.437890Z 22 [Note] Access denied for user 'root'@'localhost' (using password: NO)

E os logs do tomcat:

06-Feb-2019 16:45:03.361 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [/var/lib/tomcat8/webapps/loja.war]
06-Feb-2019 16:45:06.895 INFO [localhost-startStop-1] org.apache.jasper.servlet.TldScanner.scanJars At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader).
log4j:WARN Please initialize the log4j system properly.
Wed Feb 06 16:45:09 UTC 2019 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
Wed Feb 06 16:45:10 UTC 2019 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
Wed Feb 06 16:45:10 UTC 2019 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
Wed Feb 06 16:45:10 UTC 2019 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
06-Feb-2019 16:45:10.807 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal One or more listeners failed to start. Full details will be found in the appropriate container log file
06-Feb-2019 16:45:10.818 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal Context [/loja] startup failed due to previous errors
2 respostas

Oi Luciano tudo certo ?

Você consegue logar apenas com sudo mysql ?

Oi Felipe. Tudo certo! Não consigo:

ubuntu@ip-172-31-86-197:/var/log/tomcat8$ sudo mysql
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

Quer mergulhar em tecnologia e aprendizagem?

Receba a newsletter que o nosso CEO escreve pessoalmente, com insights do mercado de trabalho, ciência e desenvolvimento de software