Jenkins does not start on ARM+OpenJDK+JamVM

Bug #827463 reported by James Page
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
jenkins (Ubuntu)
Fix Released
Medium
James Page
jenkins-xstream (Ubuntu)
Fix Released
Medium
James Page
openjdk-6 (Ubuntu)
Fix Released
Medium
Xerxes Rånby

Bug Description

Jenkins currently won't start on ARM architecture with the following issues:

1) jenkins-xstream does not recognise JamVM as a virtual machine implementation that supports the required native VM features - Jenkins checks this as it has similar requirements and displays an error message on startup to this effect.

2) Using a patched version of jenkins-xstream (JamVM + OpenJDK should support the require native language features) Jenkins fails during extension point location through Sezpoz - see attached log output.

It works OK with the zero VM but as you would expect performance is not great.

Tags: patch jamvm

Related branches

Revision history for this message
James Page (james-page) wrote :
James Page (james-page)
tags: added: jamvm
Changed in jenkins (Ubuntu):
status: New → Confirmed
Changed in jenkins-xstream (Ubuntu):
status: New → Confirmed
Revision history for this message
Kohsuke Kawaguchi (kk-kohsuke) wrote :

The error message indicates that JamVM doesn't properly implement java.lang.Class.getEnclosingClass(). This method is returning null when it shouldn't --- as such I consider it a bug in JamVM.

Revision history for this message
Xerxes Rånby (xranby) wrote :

I have forwarded this bug to the JamVM mailinglist:

It looks like JamVM source for the gnuclasspath bindings have support for getEnclosingClass, I will look into getting the JamVM+OpenJDK combination to implement the same bindings.

(oneiric)xranby@ac100:~/icedtea6-jamvm/jamvm/jamvm/src/classlib$ grep getEnclosing -r *
gnuclasspath/reflect.c:Class *getEnclosingClass(Class *class) {
gnuclasspath/reflect.c:MethodBlock *getEnclosingMethod(Class *class) {
gnuclasspath/reflect.c: Class *enclosing_class = getEnclosingClass(class);
gnuclasspath/reflect.c:Object *getEnclosingMethodObject(Class *class) {
gnuclasspath/reflect.c: MethodBlock *mb = getEnclosingMethod(class);
gnuclasspath/reflect.c:Object *getEnclosingConstructorObject(Class *class) {
gnuclasspath/reflect.c: MethodBlock *mb = getEnclosingMethod(class);
gnuclasspath/natives.c:uintptr_t *getEnclosingClass0(Class *class, MethodBlock *mb,
gnuclasspath/natives.c: *ostack++ = (uintptr_t) getEnclosingClass(clazz);
gnuclasspath/natives.c:uintptr_t *getEnclosingMethod0(Class *class, MethodBlock *mb,
gnuclasspath/natives.c: *ostack++ = (uintptr_t) getEnclosingMethodObject(clazz);
gnuclasspath/natives.c:uintptr_t *getEnclosingConstructor(Class *class, MethodBlock *mb,
gnuclasspath/natives.c: *ostack++ = (uintptr_t) getEnclosingConstructorObject(clazz);
gnuclasspath/natives.c: {"getEnclosingClass", NULL, getEnclosingClass0},
gnuclasspath/natives.c: {"getEnclosingMethod", NULL, getEnclosingMethod0},
gnuclasspath/natives.c: {"getEnclosingConstructor", NULL, getEnclosingConstructor},
gnuclasspath/lib/java/lang/VMClass.java: Class enclosingClass = getEnclosingClass(klass);
gnuclasspath/lib/java/lang/VMClass.java: static native Class getEnclosingClass(Class klass);
gnuclasspath/lib/java/lang/VMClass.java: static native Constructor getEnclosingConstructor(Class klass);
gnuclasspath/lib/java/lang/VMClass.java: static native Method getEnclosingMethod(Class klass);

Revision history for this message
Xerxes Rånby (xranby) wrote :

Robert Lougher have posted a fix for this issue on the JamVM mailinglist:
http://sourceforge.net/mailarchive/message.php?msg_id=27957556

Revision history for this message
Xerxes Rånby (xranby) wrote :

Patch for task 1) to make JamVM pass the xstream runtime check.
The patch makes xstream accept all JVM that run on top of OpenJDK or IcedTea builds to be ok to use.

James Page (james-page)
Changed in jenkins-xstream (Ubuntu):
importance: Undecided → Medium
Changed in jenkins (Ubuntu):
importance: Undecided → Medium
Changed in jenkins-xstream (Ubuntu):
assignee: nobody → James Page (james-page)
status: Confirmed → In Progress
Revision history for this message
James Page (james-page) wrote :

Thanks for the patch Xerxes - I took the liberty of reporting this upstream and submitting the patch to Jenkins as well:

https://issues.jenkins-ci.org/browse/JENKINS-10752

Changed in openjdk-6 (Ubuntu):
status: New → Confirmed
importance: Undecided → Medium
tags: added: patch
Revision history for this message
Xerxes Rånby (xranby) wrote :

The fix for task 2) have been pushed upstream to JamVM and IcedTea6:
http://git.berlios.de/cgi-bin/cgit.cgi/jamvm/commit/?id=15f0fcf749071c7fa1bf0431e044e55143e94844
http://icedtea.classpath.org/hg/icedtea6/rev/759b17771e6a498046d728fa7443b3f32f067698

It will get pulled in in the next openjdk-6 update in Oneiric.

Revision history for this message
Xerxes Rånby (xranby) wrote :

New problem
task 3) the /usr/share/jenkins/jankins.war from the jenkins package contains its own copy of xstream-debian.jar in WEB-INF/lib/xstream-debian.jar that needs to get updated for xstream to pass the runtime check.
It would be good if Jenkins could use the system installed /usr/share/java/jenkins-xstream-1.3.1-hudson-8.jar .
Right now Jenkins are only using its own local xstream copy that only gets updated at buildtime of the jenkins package.

Revision history for this message
Xerxes Rånby (xranby) wrote :

The OpenJDK 6 6b23~pre8-1ubuntu1 package contains the fix for task 2)

Changed in openjdk-6 (Ubuntu):
status: Confirmed → Fix Released
assignee: nobody → Xerxes Rånby (xranby)
Revision history for this message
James Page (james-page) wrote : Re: [Bug 827463] Re: Jenkins does not start on ARM+OpenJDK+JamVM

> New problem
> task 3) the /usr/share/jenkins/jankins.war from the jenkins package contains its own copy of xstream-debian.jar in WEB-INF/lib/xstream-debian.jar that needs to get updated for xstream to pass the runtime check.
> It would be good if Jenkins could use the system installed /usr/share/java/jenkins-xstream-1.3.1-hudson-8.jar .
> Right now Jenkins are only using its own local xstream copy that only gets updated at build time

Hi Xerces

Aware of this issue but no good way to work around the fact that java web applications bundle all dependencies at the moment - effectively static linking

I need to resolve a minor issue with the upstart script which will require a rebuild - but need xstream winstone and jcaptcha proposed branches to land first.

I'll push an updated version to an arm enabled ppa in the next few hours.

Revision history for this message
James Page (james-page) wrote :

Xerces

I've uploaded a new version of jenkins + all updated dependencies to:

  ppa:hudson-ubuntu/testing

This PPA is ARM enabled so should be good for testing; trying it ATM but my pandaboard just became unresponsive and I'm not local to it....

Revision history for this message
Xerxes Rånby (xranby) wrote :

The new version of jenkins + all updated dependencies in the PPA:
  ppa:hudson-ubuntu/testing
makes Jenkins on ARM+OpenJDK+JamVM work!

I am looking forward to see these fixes merged into the Oneiric archive.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package jenkins-xstream - 1.3.1-hudson-8-0ubuntu2

---------------
jenkins-xstream (1.3.1-hudson-8-0ubuntu2) oneiric; urgency=low

  [ Xerces Ranby ]
  * debian/patches/openjdk-icedtea-support.patch: Add support for OpenJDK
    or IcedTea based JVM's to enable use on ARM based architectures
    (LP: #827463).
 -- James Page <email address hidden> Thu, 18 Aug 2011 09:14:29 +0100

Changed in jenkins-xstream (Ubuntu):
status: In Progress → Fix Released
James Page (james-page)
Changed in jenkins (Ubuntu):
assignee: nobody → James Page (james-page)
status: Confirmed → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package jenkins - 1.409.1-0ubuntu2

---------------
jenkins (1.409.1-0ubuntu2) oneiric; urgency=low

  * Resolved issue with specific group being set in upstart
    configuration (LP: #820938).
  * Rebuild to pickup new versions of jenkins-xstream to enable ARM
    compatibility (LP: #827463).
  * Rebuild to pickup new versions of jcaptcha and jenkins-winstone to
    resolve compatibiltiy issues with libservlet2.5-java (LP: #827651).
  * Fix FTBFS due to missing fonts causing test failure in Jenkins core:
     - debian/control: added ttf-dejavu-core to Build-Depends-Indep.
  * Fix FTBFS due to change in location of jtidy maven artifact:
     - debian/maven.rules: switch jtidy -> net.sf.jtidy to pickup new
       location.
 -- James Page <email address hidden> Tue, 06 Sep 2011 16:53:57 +0100

Changed in jenkins (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.