Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Upgrade Stash 2.6.4 to 3.1.3

Jonathan Chapman July 21, 2014

On an Ubuntu server 14.04 I've upgraded my Stash to 3.1.3. I've update the MySql to the latest 5.6.19. And as far I can tell the permissions are all correct. If I look the file mentioned below in the log actually exists even though the error is saying that it couldn't write it. I'm still getting the following error:

2014-07-21 15:57:31,220 INFO [localhost-startStop-1] c.a.s.i.server.BuildInfoLogger Starting Stash 3.1.3 (faa46f8 built on Wed Jul 09 01:29:27 EDT 2014)

2014-07-21 15:57:31,224 INFO [localhost-startStop-1] c.a.s.i.server.BuildInfoLogger JVM: Oracle Corporation OpenJDK 64-Bit Server VM 1.7.0_55-b14

2014-07-21 15:57:32,414 INFO [localhost-startStop-1] c.a.s.internal.home.HomeLockAcquirer Successfully acquired lock on home directory /home/apex/stash-home for 2182@git

2014-07-21 15:57:44,620 INFO [localhost-startStop-1] c.a.s.internal.home.HomeLockAcquirer Releasing lock on /home/apex/stash-home

2014-07-21 15:57:44,623 INFO [localhost-startStop-1] c.a.s.i.server.BuildInfoLogger Stash 3.1.3 has shut down

2014-07-21 15:57:44,628 ERROR [localhost-startStop-1] o.s.web.context.ContextLoader Context initialization failed

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hookService': Invocation of init method failed; nested exception is java.io.IOException: Hook support scripts could not be written to /home/apex/stash-home/bin/git-hooks

at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:136) ~[spring-beans-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:760) ~[spring-context-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:482) ~[spring-context-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:403) ~[spring-web-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306) ~[spring-web-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106) [spring-web-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at java.util.concurrent.FutureTask.run(FutureTask.java:262) [na:1.7.0_55]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_55]

at java.lang.Thread.run(Thread.java:744) [na:1.7.0_55]

... 16 frames trimmed

Caused by: java.io.IOException: Hook support scripts could not be written to /home/apex/stash-home/bin/git-hooks

at com.atlassian.stash.internal.hook.DefaultHookService.installHookScripts(DefaultHookService.java:175) ~[stash-service-impl-3.1.3.jar:na]

at com.atlassian.stash.internal.hook.DefaultHookService.startup(DefaultHookService.java:119) ~[stash-service-impl-3.1.3.jar:na]

... 9 common frames omitted

Caused by: java.io.IOException: /home/apex/stash-home/bin/git-hooks/hook-callback.pl could not be set executable.

at com.atlassian.stash.internal.hook.DefaultHookService.installHookScript(DefaultHookService.java:145) ~[stash-service-impl-3.1.3.jar:na]

at com.atlassian.stash.internal.hook.DefaultHookService.installHookScripts(DefaultHookService.java:172) ~[stash-service-impl-3.1.3.jar:na]

... 10 common frames omitted

2014-07-21 15:57:44,633 ERROR [localhost-startStop-1] c.a.j.s.w.c.JohnsonContextLoaderListener The Spring WebApplicationContext could not be started

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hookService': Invocation of init method failed; nested exception is java.io.IOException: Hook support scripts could not be written to /home/apex/stash-home/bin/git-hooks

at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:136) ~[spring-beans-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:760) ~[spring-context-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:482) ~[spring-context-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:403) ~[spring-web-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306) ~[spring-web-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106) [spring-web-4.0.5.RELEASE.jar:4.0.5.RELEASE]

at java.util.concurrent.FutureTask.run(FutureTask.java:262) [na:1.7.0_55]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_55]

at java.lang.Thread.run(Thread.java:744) [na:1.7.0_55]

... 16 frames trimmed

Caused by: java.io.IOException: Hook support scripts could not be written to /home/apex/stash-home/bin/git-hooks

at com.atlassian.stash.internal.hook.DefaultHookService.installHookScripts(DefaultHookService.java:175) ~[stash-service-impl-3.1.3.jar:na]

at com.atlassian.stash.internal.hook.DefaultHookService.startup(DefaultHookService.java:119) ~[stash-service-impl-3.1.3.jar:na]

... 9 common frames omitted

Caused by: java.io.IOException: /home/apex/stash-home/bin/git-hooks/hook-callback.pl could not be set executable.

at com.atlassian.stash.internal.hook.DefaultHookService.installHookScript(DefaultHookService.java:145) ~[stash-service-impl-3.1.3.jar:na]

at com.atlassian.stash.internal.hook.DefaultHookService.installHookScripts(DefaultHookService.java:172) ~[stash-service-impl-3.1.3.jar:na]

... 10 common frames omitted

2014-07-21 15:57:44,699 ERROR [localhost-startStop-1] c.a.j.s.w.c.s.JohnsonHttpRequestHandlerServlet Bypassing HttpRequestHandlerServlet [fileServerServlet] initialisation; Spring initialisation failed: The Spring WebApplicationContext could not be started

2014-07-21 15:57:44,699 ERROR [localhost-startStop-1] c.a.j.s.w.c.s.JohnsonHttpRequestHandlerServlet Bypassing HttpRequestHandlerServlet [scmServlet] initialisation; Spring initialisation failed: The Spring WebApplicationContext could not be started

2014-07-21 15:57:44,699 ERROR [localhost-startStop-1] c.a.j.s.w.c.s.JohnsonHttpRequestHandlerServlet Bypassing HttpRequestHandlerServlet [streamsEmptyActivityServlet] initialisation; Spring initialisation failed: The Spring WebApplicationContext could not be started

2014-07-21 15:57:44,701 ERROR [localhost-startStop-1] c.a.j.s.w.s.JohnsonDispatcherServlet Bypassing SpringMVC dispatcher [spring-mvc] initialisation; Spring initialisation failed: The Spring WebApplicationContext could not be started

2 answers

1 vote
Jonathan Chapman July 21, 2014

Now I get the following about missing directory in some file and can't figure out why.

2014-07-21 16:39:45,036 WARN [ThreadPoolAsyncTaskExecutor::Thread 14] o.s.beans.TypeConverterDelegate PropertyEditor [com.sun.beans.editors.EnumEditor] found through deprecated global PropertyEditorManager fallback - consider using a more isolated form of registration, e.g. on the BeanWrapper/BeanFactory!

2014-07-21 16:39:46,767 WARN [ThreadPoolAsyncTaskExecutor::Thread 15] n.s.e.config.CacheConfiguration Cache 'com.atlassian.applinks.core.DefaultReadOnlyApplicationLinkService.links' is set to eternal but also has TTI/TTL set. To avoid this warning, clean up the config removing conflicting values of eternal, TTI and TTL. Effective configuration for Cache 'com.atlassian.applinks.core.DefaultReadOnlyApplicationLinkService.links' will be eternal='true', timeToIdleSeconds='0', timeToLiveSeconds='0'.

2014-07-21 16:39:46,930 WARN [ThreadPoolAsyncTaskExecutor::Thread 14] n.s.e.config.CacheConfiguration Cache 'HostLicenseCache' is set to eternal but also has TTI/TTL set. To avoid this warning, clean up the config removing conflicting values of eternal, TTI and TTL. Effective configuration for Cache 'HostLicenseCache' will be eternal='true', timeToIdleSeconds='0', timeToLiveSeconds='0'.

2014-07-21 16:39:46,968 WARN [ThreadPoolAsyncTaskExecutor::Thread 14] n.s.e.config.CacheConfiguration Cache 'UpmRoleBasedMetadataCache' is set to eternal but also has TTI/TTL set. To avoid this warning, clean up the config removing conflicting values of eternal, TTI and TTL. Effective configuration for Cache 'UpmRoleBasedMetadataCache' will be eternal='true', timeToIdleSeconds='0', timeToLiveSeconds='0'.

2014-07-21 16:39:47,208 WARN [ThreadPoolAsyncTaskExecutor::Thread 14] n.s.e.config.CacheConfiguration Cache 'UpmPluginLicenseCache' is set to eternal but also has TTI/TTL set. To avoid this warning, clean up the config removing conflicting values of eternal, TTI and TTL. Effective configuration for Cache 'UpmPluginLicenseCache' will be eternal='true', timeToIdleSeconds='0', timeToLiveSeconds='0'.

2014-07-21 16:39:48,953 WARN [localhost-startStop-1] c.a.s.i.p.OsgiBundledPathScanner Cannot scan directory /com/atlassian/oauth/shared/servlet/ in bundle com.atlassian.oauth.atlassian-oauth-service-provider-plugin as it does not exist

Jonathan Chapman July 21, 2014

The only place I can find reference to com.atlassian.oauth.atlassian-oauth-service-provider-plugin is in the licenses folder.

0 votes
Jonathan Chapman July 21, 2014

Looks like the issue was that the new stash user was not the owner of the git-hooks directory even though it had write/execute permission on this fodler and file based on the group. Once I made him the owner I got farther but now have a "JiraIndexUpgradeTask Error indexing repository" error on all my repositories.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events