i had deployed my project on Aws ec2 server according to this link: http://grails.asia/step-by-step-tutorial-on-how-to-host-your-grails-application
And its has been deployed successfully as my bootstrap has been executed and i
have given some println in it which are getting shown on tomcat's catalina.out.
and also the bootstraped data has been already inserted into mysql db. I
guess, it means that my application is running somewhere. But when i am trying
to hit the url according to above link its not getting dispalyed on browser.
I am hitting : https://35.154.163.145:8080/jobVacency/
where "35.154.163.145" is my aws IPv4 Public IP and
jobVacency is my project name.
Catalina.out:
Apr 14, 2017 8:19:19 AM org.apache.catalina.startup.TaglibUriRule body
INFO: TLD skipped. URI: http://www.springframework.org/tags/form is already defined
Apr 14, 2017 8:19:20 AM org.codehaus.groovy.runtime.m12n.MetaInfExtensionModule newModule
WARNING: Module [groovy-all] - Unable to load extension class [org.codehaus.groovy.runtime.NioGroovyMethods]
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Bootstrap started.
Bootstrap ended.
Apr 14, 2017 8:19:48 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /va`enter code here`r/lib/tomcat7/webapps/ROOT
Apr 14, 2017 8:19:50 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Apr 14, 2017 8:19:50`enter code here` AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 42043 ms
Related
Deployed a grails app successfully on openshift. As the log doesnt show any error. But the page I am getting is still 503.
Please help.
My Log is :
Apr 30, 2014 8:58:57 AM org.apache.catalina.startup.ClusterRuleSetFactory getClusterRuleSet
INFO: Unable to find a cluster rule set in the classpath. Will load the default rule set.
Apr 30, 2014 8:58:57 AM org.apache.catalina.startup.ClusterRuleSetFactory getClusterRuleSet
INFO: Unable to find a cluster rule set in the classpath. Will load the default rule set.
Apr 30, 2014 8:59:00 AM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /opt/rh/mysql55/root/usr/lib64:/usr/java/packages/lib/i386:/lib:/usr/lib
Apr 30, 2014 8:59:02 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-127.5.178.1-8080
Apr 30, 2014 8:59:02 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 5493 ms
Apr 30, 2014 8:59:02 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Apr 30, 2014 8:59:02 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.37
Apr 30, 2014 8:59:02 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT.war
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Configuring Spring Security UI ...
... finished configuring Spring Security UI
Apr 30, 2014 9:04:42 AM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-127.5.178.1-8080
Apr 30, 2014 9:04:43 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 340606 ms
Got It !!!
It was haproxy at the end. after a day of headscratching I got it when I sat with a cooler mind and thought through everything.
This is the link for dealing with 503 error.
https://www.openshift.com/blogs/how-to-host-your-java-ee-application-with-auto-scaling
I did not use rhc to connect to haproxy conf though. I used putty.
I'm following the guide on this page, and it gets the server up and running, but the webadmin doesn't work. And being a newbie to Neo4j, the webadmin is VERY useful to me. When trying to access the webadmin, I just get a 404 Not Found error. And it doesn't seem like the logs are telling me that anything is wrong.
May 14, 2013 11:41:33 AM org.neo4j.server.logging.Logger log
INFO: Setting startup timeout to: 120000ms based on -1
May 14, 2013 11:41:33 AM org.neo4j.server.logging.Logger log
INFO: Starting Neo Server on port [7474] with [40] threads available
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
INFO: Mounted discovery module at [/]
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
INFO: Loaded server plugin "CypherPlugin"
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
INFO: Mounted REST API at [/db/data]
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
INFO: Mounted management API at [/db/manage]
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
INFO: Mounted webadmin at [/webadmin]
11:41:34.598 [main] INFO org.mortbay.log - Logging to Logger[org.mortbay.log] via org.mortbay.log.Slf4jLog
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
INFO: Mounting static content at [/webadmin] from [webadmin-html]
May 14, 2013 11:41:34 AM org.neo4j.server.logging.Logger log
SEVERE: No static content available for Neo Server at port [7474], management console may not be available.
11:41:34.651 [main] INFO org.mortbay.log - jetty-6.1.25
May 14, 2013 11:41:34 AM com.sun.jersey.api.core.PackagesResourceConfig init
INFO: Scanning for root resource and provider classes in the packages:
org.neo4j.server.webadmin.rest
May 14, 2013 11:41:34 AM com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Root resource classes found:
class org.neo4j.server.webadmin.rest.console.ConsoleService
class org.neo4j.server.webadmin.rest.JmxService
class org.neo4j.server.webadmin.rest.RootService
class org.neo4j.server.webadmin.rest.MonitorService
May 14, 2013 11:41:34 AM com.sun.jersey.api.core.ScanningResourceConfig init
INFO: No provider classes found.
May 14, 2013 11:41:34 AM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
INFO: Initiating Jersey application, version 'Jersey: 1.9 09/02/2011 11:17 AM'
May 14, 2013 11:41:35 AM com.sun.jersey.api.core.PackagesResourceConfig init
INFO: Scanning for root resource and provider classes in the packages:
org.neo4j.server.rest.web
May 14, 2013 11:41:35 AM com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Root resource classes found:
class org.neo4j.server.rest.web.ExtensionService
class org.neo4j.server.rest.web.CypherService
class org.neo4j.server.rest.web.ResourcesService
class org.neo4j.server.rest.web.BatchOperationService
class org.neo4j.server.rest.web.RestfulGraphDatabase
class org.neo4j.server.rest.web.DatabaseMetadataService
May 14, 2013 11:41:35 AM com.sun.jersey.api.core.ScanningResourceConfig init
INFO: No provider classes found.
May 14, 2013 11:41:35 AM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
INFO: Initiating Jersey application, version 'Jersey: 1.9 09/02/2011 11:17 AM'
May 14, 2013 11:41:35 AM com.sun.jersey.api.core.PackagesResourceConfig init
INFO: Scanning for root resource and provider classes in the packages:
org.neo4j.server.rest.discovery
May 14, 2013 11:41:35 AM com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Root resource classes found:
class org.neo4j.server.rest.discovery.DiscoveryService
May 14, 2013 11:41:35 AM com.sun.jersey.api.core.ScanningResourceConfig init
INFO: No provider classes found.
May 14, 2013 11:41:35 AM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
INFO: Initiating Jersey application, version 'Jersey: 1.9 09/02/2011 11:17 AM'
May 14, 2013 11:41:35 AM org.neo4j.server.logging.Logger log
11:41:35.522 [main] INFO org.mortbay.log - Started SelectChannelConnector#localhost:7474
INFO: Server started on [http://localhost:7474/]
Is there something else I'm supposed to be configuring to get the webadmin working? Do I need to install the Windows service or something?
Grails 2.1.4
Tomcat 7.0.37
Java 1.7
Window 7
I created Sample Grails app in eclipse, i run with run-app. it is working fine and able to open in brower also.
But for same application, i build .war file with grails:maven-install. And i am trying to deploy, But i am getting below error:
Mar 26, 2013 11:56:26 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: Context [/HelloGrails-0.1] startup failed due to previous errors
Mar 26, 2013 11:56:26 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/HelloGrails-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.runtime.GroovyCategorySupport.MyThreadLocal] (value [org.codehaus.groovy.runtime.GroovyCategorySupport$MyThreadLocal#644aa32b]) and a value of type [java.lang.ref.SoftReference] (value [java.lang.ref.SoftReference#601e8f7d]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
Mar 26, 2013 11:56:26 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/HelloGrails-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.reflection.ClassInfo.ThreadLocalMapHandler] (value [org.codehaus.groovy.reflection.ClassInfo$ThreadLocalMapHandler#639ca35]) and a value of type [java.lang.ref.SoftReference] (value [java.lang.ref.SoftReference#3c0a60c4]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
Please help me..............
Thanks,
Ravi
create a file named logging.properties in WEB-INF/classes with following content:
org.apache.catalina.core.ContainerBase.[Catalina].level = INFO
org.apache.catalina.core.ContainerBase.[Catalina].handlers = java.util.logging.ConsoleHandler
Restart apache and look to the stacktrace
I'm using the cloud foundry plugin. I have set my credentials in Config.groovy.
Can you tell me more about the errors I get?
Application Deployed URL: 'sqr-gb-ks.cloudfoundry.com'
>
Would you like to create and bind a mysql service?[y,n] > Invalid input. Must be one of [y,n] y
Service 'mysql-8a02c10' provisioned.
>
Would you like to create and bind a postgresql service?[y,n] > Invalid input. Must be one of [y,n] y
Service 'postgresql-d6ab9c9' provisioned.
| Creating application sqr-gb-ks at sqr-gb-ks.cloudfoundry.com with 1024MB and services [mysql-8a02c10, postgresql-d6ab9c9]: OK
| Uploading Application:
| Checking for available resources: OK
| Processing resources: OK
| Packing application: OK
| Uploading (50K): OK
| Trying to start Application: 'sqr-gb-ks'.....
| Error ERROR - Application 'sqr-gb-ks' failed to start, logs information below.
==== logs/stderr.log ====
Oct 22, 2012 4:57:47 PM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-25918
Oct 22, 2012 4:57:47 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 403 ms
Oct 22, 2012 4:57:47 PM org.apache.catalina.realm.JAASRealm setContainer
INFO: Set JAAS app name Catalina
Oct 22, 2012 4:57:47 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Oct 22, 2012 4:57:47 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.35
Oct 22, 2012 4:57:47 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
Oct 22, 2012 4:58:10 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Oct 22, 2012 4:58:10 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [] startup failed due to previous errors
Oct 22, 2012 4:58:10 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [Timer-0] but has failed to stop it. This is very likely to create a memory leak.
Oct 22, 2012 4:58:10 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [net.sf.ehcache.CacheManager#403525a2] but has failed to stop it. This is very likely to create a memory leak.
==== logs/stdout.log ====
[ Envjs/1.6 (Rhino; U; Linux amd64 2.6.38-15-virtual; en-US; rv:1.7.0.rc2) Resig/20070309 PilotFish/1.2.13 ]
[ Envjs/1.6 (Rhino; U; Linux amd64 2.6.38-15-virtual; en-US; rv:1.7.0.rc2) Resig/20070309 PilotFish/1.2.13 ]
[ Envjs/1.6 (Rhino; U; Linux amd64 2.6.38-15-virtual; en-US; rv:1.7.0.rc2) Resig/20070309 PilotFish/1.2.13 ]
[ Envjs/1.6 (Rhino; U; Linux amd64 2.6.38-15-virtual; en-US; rv:1.7.0.rc2) Resig/20070309 PilotFish/1.2.13 ]
Stopping Tomcat because the context stopped.
If it's a Grails app you should use the http://grails.org/plugin/cloud-foundry plugin instead of STS since it has an awareness of the Spring beans for JDBC, MongoDB, Redis, etc. and will reconfigure them automatically for you on deployment. See the docs here: http://grails-plugins.github.com/grails-cloud-foundry/docs/manual/index.html
Also - do you really want both a MySQL and a PostgreSQL database? You should probably pick one :)
You can see the actual problem by looking at stacktrace.log and the "localhost" log in the tomcat/logs directory on the server - that's where the real stacktrace and error messages will be, not in the stdout that you see when deploying.
Thanks to my friend bertrand from odelia technologies, I succeeded in pushing my app to the cloud.I turned off one of the plugins I added and ran the command :
grails cf-bind-service mysql-f1..(I had not done it!)
Then I had to modify my DataSource.groovy;
production {
dataSource {
dialect= org.hibernate.dialect.MySQLInnoDBDialect
driverClassName = "com.mysql.jdbc.Driver"
dbCreate = "update"
username = "n/a"
password = "n/a"
url = "n/a"
}
}
I have installed cloud foundry plugin on my grails project and I have successfully pushed my project once onto the cloud but when I tried to update my app using,
grails prod cf-update
command. When I did this, I get the following error:
ERROR - Application 'scheduleNew' failed to start, logs information below.
==== logs/stderr.log ====
Jan 23, 2012 2:45:02 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8963
Jan 23, 2012 2:45:02 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 378 ms
Jan 23, 2012 2:45:02 AM org.apache.catalina.realm.JAASRealm setContainer
INFO: Set JAAS app name Catalina
Jan 23, 2012 2:45:02 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Jan 23, 2012 2:45:02 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.35
Jan 23, 2012 2:45:02 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
Jan 23, 2012 2:45:12 AM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Jan 23, 2012 2:45:12 AM org.apache.catalina.core.StandardContext start
SEVERE: Context [] startup failed due to previous errors
Jan 23, 2012 2:45:12 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [Timer-0] but has failed to stop it. This is very likely to create a memory leak.
Jan 23, 2012 2:45:12 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [net.sf.ehcache.CacheManager#7e628e42] but has failed to stop it. This is very likely to create a memory leak.
Jan 23, 2012 2:45:12 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [org.example.SecRole.data] but has failed to stop it. This is very likely to create a memory leak.
Jan 23, 2012 2:45:12 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [org.hibernate.cache.UpdateTimestampsCache.data] but has failed to stop it. This is very likely to create a memory leak.
Jan 23, 2012 2:45:12 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [org.hibernate.cache.StandardQueryCache.data] but has failed to stop it. This is very likely to create a memory leak.
==== logs/stdout.log ====
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Stopping Tomcat because the context stopped.
When I again run the same command (grails prod cf-update), the error message getting changed :
ERROR - Application 'scheduleNew' failed to start, logs information below.
==== logs/stderr.log ====
Jan 23, 2012 2:52:14 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-45003
Jan 23, 2012 2:52:14 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 379 ms
Jan 23, 2012 2:52:14 AM org.apache.catalina.realm.JAASRealm setContainer
INFO: Set JAAS app name Catalina
Jan 23, 2012 2:52:14 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Jan 23, 2012 2:52:14 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.35
Jan 23, 2012 2:52:14 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
I really don't understand whats going on here.
What these error messages say? Where I have went wrong?
There are other log files. If you use the http://grails-plugins.github.com/grails-cloud-foundry/docs/manual/ref/Scripts/cf-list-files.html command you can get a directory listing. Run grails cf-list-files / to get a listing of the top-level directory (it'll contain a logs and a tomcat directory). The logs directory will probably just have the stderr and stdout files that you're already seeing, but there's another logs directory under the tomcat directory: grails cf-list-files /tomcat/logs. This should have other more informative log files. Also check if there's a stacktrace.log in the tomcat directory.
Once you've found a file you want to look at, use the http://grails-plugins.github.com/grails-cloud-foundry/docs/manual/ref/Scripts/cf-get-file.html command to view them, e.g.
grails cf-get-file /tomcat/stacktrace.log
grails cf-get-file /tomcat/logs/catalina.2012-01-24.log