Repository Mirror Plugin for Bitbucket Server - process timed out Edited

Hi,

I want to use Repository Mirror Plugin for Bitbucket Server to mirror repository from our internal bitkucket server to remote bitbucket.org repo. Plugin is installed, enabled and configured (I've tried with https, git and ssh - in all cases the error log was the same). Our internal bitbucket (v4.12.1, git version 1.9.1) server is behind reverse proxy (apache), configuration is done according to documentation (https://confluence.atlassian.com/kb/integrating-apache-http-server-reverse-proxy-with-bitbucket-server-753894395.html), there's communication to WAN through squid proxy (we've got apriopriate configuration at bikbucket side, also git itself is configured to use our squid proxy for WAN communication).

The problem is to mirror repository with "Repository Mirror Plugin for Bitbucket Server", here's bitbucket log:

 ERROR [threadpool:thread-4] username @1I15U79x605x938201x0 1bo9kzh client_ip_address, reverse_proxy_ip_address "PUT /rest/api/latest/projects/~username/repos/test-repo-mirroring/settings/hooks/com.englishtown.stash-hook-mirror:mirror-repository-hook/settings HTTP/1.1" c.e.b.hook.MirrorRepositoryHook Failed to mirror repository test-repo-mirroring after 5 attempts.
com.atlassian.bitbucket.ServerException: An error occurred while executing an external process: process timed out
        at com.atlassian.bitbucket.scm.git.command.GitCommandExitHandler.evaluateThrowable(GitCommandExitHandler.java:113) ~[na:na]
        at com.atlassian.bitbucket.scm.git.command.GitCommandExitHandler.onError(GitCommandExitHandler.java:201) ~[na:na]
        at com.atlassian.bitbucket.scm.DefaultCommandExitHandler.onExit(DefaultCommandExitHandler.java:31) ~[bitbucket-spi-4.12.1.jar:na]
        at com.englishtown.bitbucket.hook.PasswordHandler.onExit(PasswordHandler.java:46) ~[na:na]
        at com.atlassian.bitbucket.scm.BaseCommand.callExitHandler(BaseCommand.java:146) ~[bitbucket-spi-4.12.1.jar:na]
        at com.atlassian.bitbucket.scm.BaseCommand$CommandFuture.internalGet(BaseCommand.java:280) ~[bitbucket-spi-4.12.1.jar:na]
        at com.atlassian.bitbucket.scm.BaseCommand$CommandFuture.get(BaseCommand.java:244) ~[bitbucket-spi-4.12.1.jar:na]
        at com.atlassian.bitbucket.scm.BaseCommand.call(BaseCommand.java:83) ~[bitbucket-spi-4.12.1.jar:na]
        at com.englishtown.bitbucket.hook.MirrorRepositoryHook$1.run(MirrorRepositoryHook.java:142) ~[na:na]
        at com.atlassian.stash.internal.concurrent.StateTransferringExecutor$StateTransferringRunnable.run(StateTransferringExecutor.java:70) [bitbucket-platform-4.12.1.jar:na]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_111]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_111]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_111]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [na:1.8.0_111]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_111]
        at java.lang.Thread.run(Thread.java:745) [na:1.8.0_111]
        ... 1 frame trimmed
Caused by: com.atlassian.utils.process.ProcessTimeoutException: process timed out
        at com.atlassian.utils.process.ExternalProcessImpl.wrapUpProcess(ExternalProcessImpl.java:679) ~[atlassian-processutils-1.7.8.jar:na]
        at com.atlassian.utils.process.ExternalProcessImpl.finish(ExternalProcessImpl.java:161) ~[atlassian-processutils-1.7.8.jar:na]
        at com.atlassian.bitbucket.scm.BaseCommand$CommandFuture.get(BaseCommand.java:242) ~[bitbucket-spi-4.12.1.jar:na]
        ... 10 common frames omitted

I've done troubleshooting according to vendor suggestions (https://github.com/ef-labs/stash-hook-mirror/wiki)

git push --prune https://username:password@bitbucket.org/username/stash-hook-mirror.git +refs/heads/*:refs/heads/* +refs/tags/*:refs/tags/*

and it works.

When bitbucket is trying mirror to remote repo there are no connections to our proxy server, it suggests that problems are within our internal bitbucket server.

Can you please suggest what can cause this situation? How can we debug it more detailed way?

Any suggestion very appreciated.

0 answers

Suggest an answer

Log in or Sign up to answer
Community showcase
Published yesterday in Statuspage

194 years of downtime: looking back on incident data from 2018

Statuspage customers logged more than 194 years of collective incidents in 2018. That’s a whopping 87% increase from the  104 years logged in 2017 , and we aren’t even through December yet....

44 views 1 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you