got internal server error while trying to clone project from gerrit slave after upgraded from version 2.10 to 2.11

277 views
Skip to first unread message

Makson Lee

unread,
Apr 20, 2015, 3:20:46 AM4/20/15
to repo-d...@googlegroups.com
upgraded from version 2.10 to 2.11, and then got the internal server error while trying to clone project from gerrit slave, but no problem from gerrit master, here is the error log,

[2015-04-19 17:25:57,415] ERROR com.google.gerrit.sshd.BaseCommand : Internal server error (user xxx account 1000004) during git-upload-pack '/test8/a'
com.google.common.util.concurrent.UncheckedExecutionException: java.lang.NullPointerException
        at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2203)
        at com.google.common.cache.LocalCache.get(LocalCache.java:3937)
        at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:3941)
        at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:4824)
        at com.google.gerrit.server.git.SearchingChangeCacheImpl.get(SearchingChangeCacheImpl.java:73)
        at com.google.gerrit.server.git.VisibleRefFilter.visibleChanges(VisibleRefFilter.java:180)
        at com.google.gerrit.server.git.VisibleRefFilter.filter(VisibleRefFilter.java:91)
        at com.google.gerrit.server.git.VisibleRefFilter.filter(VisibleRefFilter.java:169)
        at com.google.gerrit.server.git.VisibleRefFilter.getAdvertisedRefs(VisibleRefFilter.java:158)
        at org.eclipse.jgit.transport.AbstractAdvertiseRefsHook.advertiseRefs(AbstractAdvertiseRefsHook.java:62)
        at org.eclipse.jgit.transport.UploadPack.sendAdvertisedRefs(UploadPack.java:783)
        at org.eclipse.jgit.transport.UploadPack.service(UploadPack.java:662)
        at org.eclipse.jgit.transport.UploadPack.upload(UploadPack.java:628)
        at com.google.gerrit.sshd.commands.Upload.runImpl(Upload.java:80)
        at com.google.gerrit.sshd.AbstractGitCommand.service(AbstractGitCommand.java:101)
        at com.google.gerrit.sshd.AbstractGitCommand.access$000(AbstractGitCommand.java:32)
        at com.google.gerrit.sshd.AbstractGitCommand$1.run(AbstractGitCommand.java:70)
        at com.google.gerrit.sshd.BaseCommand$TaskThunk.run(BaseCommand.java:445)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
        at java.util.concurrent.FutureTask.run(FutureTask.java:262)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
        at com.google.gerrit.server.git.WorkQueue$Task.run(WorkQueue.java:379)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:745)

Makson Lee

unread,
Apr 20, 2015, 4:43:34 AM4/20/15
to repo-d...@googlegroups.com
with the same gerrit salve, if i change slave setting in gerrit.conf from true to false and then restart it, the project can be cloned without any problems, so it means that the error would only happen when gerrit is running in slave mode.

Makson Lee

unread,
Apr 20, 2015, 11:47:13 PM4/20/15
to repo-d...@googlegroups.com
did i miss some configuration?

Sven Selberg

unread,
Apr 21, 2015, 8:49:23 AM4/21/15
to repo-d...@googlegroups.com
A shot in the dark.
Could it be that you need to nuke the file caches at: /var/cache/git/ ?

/Sven

Den tisdag 21 april 2015 kl. 05:47:13 UTC+2 skrev Makson Lee:
did i miss some configuration?

Makson Lee

unread,
Apr 21, 2015, 10:51:06 AM4/21/15
to repo-d...@googlegroups.com
No luck, removed caches in /var/cache/git and re-synced, still can't clone project from slave.

And just FYI, i also tried to upgrade from version 2.10 to 2.10.3.1, everything is fine.

Hugo Arès

unread,
Apr 21, 2015, 1:20:38 PM4/21/15
to repo-d...@googlegroups.com
I was able to reproduce the issue, it's looks like a regression in 2.11.

The slave is trying to use the secondary index to find out which refs/changes should be advertized. The NullPointerException is happening  because the secondary index is not enabled on slaves. I am not sure yet what is the proper way to fix this.

Marco Miller

unread,
Apr 21, 2015, 3:19:43 PM4/21/15
to repo-d...@googlegroups.com
Just submitted this new issue to make this bug even more visible:
https://code.google.com/p/gerrit/issues/detail?id=3323
/Marco

Marco Miller

unread,
Apr 23, 2015, 2:47:13 PM4/23/15
to repo-d...@googlegroups.com
Fyi, a change meant as a fix for this issue has been pushed for review earlier today:
/Marco

Marco Miller

unread,
Apr 23, 2015, 3:08:12 PM4/23/15
to repo-d...@googlegroups.com

Matias Burni

unread,
Jun 3, 2015, 6:28:31 AM6/3/15
to repo-d...@googlegroups.com

Hi Marco, is there a target to make official the 2.11.1 release?

Marco Miller

unread,
Jun 3, 2015, 8:52:21 AM6/3/15
to repo-d...@googlegroups.com, david.pu...@sonymobile.com
Hi Martin,

David in cc is the release maintainer for 2.11, so you'd need his input on this one.
I understand that JGit has to be stabilized first -prior to releasing 2.10.5 hence 2.11.

You can still use the latest from the stable-2.11 branch, if you're in a hurry to get this fix.
Or you can cherry-pick it straight or so.
/Marco

Marco Miller

unread,
Jun 3, 2015, 8:53:14 AM6/3/15
to repo-d...@googlegroups.com, david.pu...@sonymobile.com
Said Martin, meant Matias -sorry!

Matias Burni

unread,
Jun 3, 2015, 8:58:08 AM6/3/15
to Marco Miller, repo-d...@googlegroups.com, david.pu...@sonymobile.com
Ok, thanks Marco.
We're going to take the stable-2.11, recompile it and test it.

Thanks.




Matias.

--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to a topic in the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/repo-discuss/3KBuykQWa1Q/unsubscribe.
To unsubscribe from this group and all its topics, send an email to repo-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Matias Burni

unread,
Jun 4, 2015, 5:30:06 AM6/4/15
to repo-d...@googlegroups.com, david.pu...@sonymobile.com, miller...@me.com
Hi, is there a stable-2.11 build and containg the https://gerrit-review.googlesource.com/#/c/67405/ ??? (nightly/latest/etc)
To avoid compiling by our own the src.

thanks.


Matias.

--
--
To unsubscribe, email repo-discuss+unsubscribe@googlegroups.com

More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to a topic in the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/repo-discuss/3KBuykQWa1Q/unsubscribe.
To unsubscribe from this group and all its topics, send an email to repo-discuss+unsubscribe@googlegroups.com.

Marco Miller

unread,
Jun 4, 2015, 9:20:22 AM6/4/15
to repo-d...@googlegroups.com, david.pu...@sonymobile.com, miller...@me.com
This would be the place as far as I know, but its latest is before this fix was introduced:
http://gerrit-releases.storage.googleapis.com/index.html

So you'd need to build it yourself; fyi in case you'd need these instructions:
https://gerrit-review.googlesource.com/Documentation/dev-buck.html

/Marco


Matias.

--
--
To unsubscribe, email repo-discuss...@googlegroups.com

More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to a topic in the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/repo-discuss/3KBuykQWa1Q/unsubscribe.
To unsubscribe from this group and all its topics, send an email to repo-discuss...@googlegroups.com.

Christian Aistleitner

unread,
Jun 4, 2015, 5:11:42 PM6/4/15
to Matias Burni, repo-d...@googlegroups.com, david.pu...@sonymobile.com, miller...@me.com
Hi Matias,

On Thu, Jun 04, 2015 at 02:30:06AM -0700, Matias Burni wrote:
> Hi, is there a stable-2.11 build and containg the
> https://gerrit-review.googlesource.com/#/c/67405/ ??? (nightly/latest/etc)
> To avoid compiling by our own the src.

<shamelessPlug>
You can grab a prebuilt war of your liking from

http://builds.quelltextlich.at/gerrit/nightly/stable-2.11/2015-06-04/index.html

</shamelessPlug>


Have fun,
Christian



--
---- quelltextlich e.U. ---- \\ ---- Christian Aistleitner ----
Companies' registry: 360296y in Linz
Christian Aistleitner
Kefermarkterstrasze 6a/3 Email: chri...@quelltextlich.at
4293 Gutau, Austria Phone: +43 7946 / 20 5 81
Fax: +43 7946 / 20 5 81
Homepage: http://quelltextlich.at/
---------------------------------------------------------------
signature.asc
Reply all
Reply to author
Forward
0 new messages