Problema para Deploy

121 views
Skip to first unread message

Mateus Lima Fonseca

unread,
Feb 8, 2017, 10:27:02 PM2/8/17
to Livro "Devops na Prática"
Olá Danilo,

Estou como o erro ao subir aplicação no servidor WEB. Realizei o aumento de memoria para a maquina web, no arquivo Vagrantfile e aumentei também no comando export MAVEN_OPTS="-Xmx2048m" para o Maven (mvn install).

Ocorre o erro abaixo:

vagrant@web:~/lojinha/loja-virtual-devops$ tail -f /var/lib/tomcat7/logs/catalina.out
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:958)
at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1599)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
... 1 more
Exception in thread "http-bio-8080-Acceptor-0" java.lang.OutOfMemoryError: PermGen space

Mateus Lima Fonseca

unread,
Feb 10, 2017, 1:24:17 PM2/10/17
to Livro "Devops na Prática"

Tentei outra vez e deu este erro:

Feb 10, 2017 2:09:09 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8443"]
Feb 10, 2017 2:09:09 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 93558 ms
Feb 10, 2017 2:16:30 AM org.apache.catalina.startup.HostConfig checkResources
INFO: Undeploying context [/devopsnapratica]
Feb 10, 2017 2:16:37 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/devopsnapratica] appears to have started a thread named [Abandoned connection cleanup thread] but has failed to stop it. This is very likely to create a memory leak.
Feb 10, 2017 2:16:37 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive /var/lib/tomcat7/webapps/devopsnapratica.war
[ WARN] 02:16:56 RuntimeEnvironmentPropertiesConfigurer - Unable to determine runtime environment, using default environment 'development'
[ERROR] 02:17:02 Ejb3Configuration - Container is providing a null PersistenceUnitRootUrl: discovery impossible
[ WARN] 02:17:05 Ejb3Configuration - hibernate.connection.autocommit = false break the EJB3 specification
[ WARN] 02:17:06 AbstractEhcacheRegionFactory - Couldn't find a specific ehcache configuration for cache named [blSandBoxElements]; using defaults.
[ WARN] 02:17:24 AbstractEhcacheRegionFactory - Couldn't find a specific ehcache configuration for cache named [org.hibernate.cache.UpdateTimestampsCache]; using defaults.
[ERROR] 02:17:26 Ejb3Configuration - Container is providing a null PersistenceUnitRootUrl: discovery impossible
[ WARN] 02:17:26 Ejb3Configuration - hibernate.connection.autocommit = false break the EJB3 specification
[ERROR] 02:17:27 Ejb3Configuration - Container is providing a null PersistenceUnitRootUrl: discovery impossible
[ WARN] 02:17:27 Ejb3Configuration - hibernate.connection.autocommit = false break the EJB3 specification
Exception in thread "ContainerBackgroundProcessor[StandardEngine[Catalina]]" java.lang.OutOfMemoryError: PermGen space
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:252)
at java.util.concurrent.FutureTask.get(FutureTask.java:111)
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:751)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:471)
at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1453)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:295)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1379)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1537)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1547)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1526)
at java.lang.Thread.run(Thread.java:701)
 

Mateus Lima Fonseca

unread,
Feb 10, 2017, 7:15:50 PM2/10/17
to Livro "Devops na Prática"

Maeda Alessandro

unread,
Mar 15, 2017, 9:12:38 PM3/15/17
to Livro "Devops na Prática"
Estou com o mesmo problema. Alguem conseguiu resolver?

Daniel Souza

unread,
May 12, 2017, 5:26:58 PM5/12/17
to Livro "Devops na Prática"
Em quinta-feira, 9 de fevereiro de 2017 00:27:02 UTC-3, Mateus Lima Fonseca escreveu:
Seguindo os passos do livro e fazendo uma modificação no Vagranfile: 1024mb de memória.

E após o do vagrant@web$ sudo nano /var/lib/tomcat7/conf/context.xml

e

vagrant@web$ cd ~/loja-virtual-devops
vagrant@web$ sudo cp combined/target/devopsnapratica.war /var/lib/tomcat7/webapps

Na minha primeira tentativa após esses passos, ao entrar no endereço estava dando erro.

O que fiz?? Restartei o Tomcat:
vagrant@web:~/loja-virtual-devops$ sudo /etc/init.d/tomcat7 restart
* Stopping Tomcat servlet engine tomcat7 [ OK ]
* Starting Tomcat servlet engine tomcat7 [ OK ]

E pegaaaa, funfou.
Reply all
Reply to author
Forward
0 new messages