Hudson

Comparison:

Problems

sun.io.MalformedInputException in maven-resources-plugin

Stacktrace

Few posts (1, 2, 3, MNG-2187) gave a hint that this is IBM JDK 1.5 specific issue.

Make sure that you do not enable filtering for binary resources:

pom.xml

<build>
    <resources>
        <resource>
            <!-- Enable filtering for text resources: -->
            <directory>src/main/resources</directory>
            <filtering>true</filtering>
            <includes>
                <include>**/*.properties</include>
            </includes>
        </resource>
        <resource>
            <!-- Disable for other resources: -->
            <directory>src/main/resources</directory>
            <filtering>false</filtering>
            <excludes>
                <exclude>**/*.properties</exclude>
            </excludes>
        </resource>
    </resources>
</build>

java.io.FileNotFoundException: /boot.log (Permission denied) for maven-checkstyle-plugin

Stacktrace

This issue is addressed in HUDSON-2048.

It looks like the chain that comes in JBoss's bin/run.jar:/log4j.properties which states:

This is happening because Hudson launches Maven in forked JVM so that JBoss configured log4j service (from server0/conf/jboss-log4j.xml) is not visible. But log4j classes are available via JVM boot classpath (lib/log4j-boot.jar) so Checkstyle → Digester → commons-logging → log4j tries to initialize again from log4j.properties in bootstrap bin/run.jar:

...
log4j.appender.FILE.File=${jboss.server.log.dir}/boot.log
...

Unfortunately Hudson/Maven also filtered out all system variables so ${jboss.server.log.dir} is empty…

Create the file /whatever/log4j.properties to override log4j configuration:
log4j.rootLogger=INFO, C

log4j.appender.C=org.apache.log4j.ConsoleAppender
log4j.appender.C.layout=org.apache.log4j.PatternLayout
log4j.appender.C.layout.ConversionPattern=%d{dd.MM HH:mm:ss} %-5p [%c] %m%n

and pass it as Build → Goals and options: -Dlog4j.configuration=/whatever/log4j.properties

Hudson boost the logfile with java.lang.IllegalArgumentException: The instance name component of a fully qualified service cannot be empty entries

Log entry

Hudson (v1.398) intensively logs the above messages to logfile, which by the end of the day is 100MB. The issue is addressed in HUDSON-8647 and JENKINS-8647.

Disable DNS multicast: -Dhudson.DNSMultiCast.disabled=true (perhaps upgrading to latest Hudson 2.1.2 is better idea).

How to change the date/tome format from 12H to 24H format?

In your browser settings change the preferred locale from English (en) to English Britain (en-GB).

How to run Jenkins under Timcat on Debian?

  • Disable Jenkins standalone:
    chkconfig jenkins off
    and in /etc/default/jenkins:
    RUN_STANDALONE=true
  • Force Tomcat to use UTF-8 for URL encoding in /etc/tomcat8/server.xml:
    <Connector port="8080" URIEncoding="UTF8" ... >
  • Pass Jenkins home to Tomcat in /etc/default/tomcat8:
    JAVA_OPTS="${JAVA_OPTS} -DJENKINS_HOME=/var/lib/jenkins"
  • Create Maven symlink:
    ln -s /var/lib/jenkins/.m2 /var/lib/tomcat8
  • Create Git symlink:
    ln -s /var/lib/jenkins/.gitconfig /var/lib/tomcat8
  • Create Jenkins app symlink:
    ln -s /usr/share/jenkins/jenkins.war /var/lib/tomcat8/webapps
  • Add “tomcat8” user to “jenkins” group:
    usermod -a -G jenkins tomcat8
  • Fix permissions:
    chmod g+w -R /var/lib/jenkins
  • Restart Tomcat (/etc/init.d/tomcat restart) and monitor log /var/log/tomcat8/catalina.out

software/hudson.txt · Last modified: 2018/06/12 17:44 by dmitry
 
 
Recent changes RSS feed Driven by DokuWiki