Home > database >  Jenkins Slave JNLP4 Connection Issue
Jenkins Slave JNLP4 Connection Issue

Time:11-27

I am having an issue with a Jenkins slave not being able to connect with the master when a specific job ends. All other jobs are completed without any issues.

Basically, the job runs on the slave without any issues and gives out the expected result but, fails when it is time to hand over the job to the Jenkins master.

Both Master and Slave are windows server VMs.

I saw multiple questions about this issue in multiple forums and Jenkins support but none of the suggested solutions is able to solve my issue.

The error message is:

Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection to hostname/IP:16076
        at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1797)
        at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356)
        at hudson.remoting.Channel.call(Channel.java:1001)
        at hudson.FilePath.act(FilePath.java:1166)
        at hudson.FilePath.act(FilePath.java:1155)
        at hudson.FilePath.copyTo(FilePath.java:2493)
        at hudson.FilePath.copyTo(FilePath.java:2448)
        at hudson.plugins.logparser.LogParserStatusComputer.computeStatusMatches(LogParserStatusComputer.java:88)
        at hudson.plugins.logparser.LogParserStatusComputer.access$000(LogParserStatusComputer.java:22)
        at hudson.plugins.logparser.LogParserStatusComputer$1.call(LogParserStatusComputer.java:54)
        at hudson.plugins.logparser.LogParserStatusComputer$1.call(LogParserStatusComputer.java:47)
        at hudson.remoting.UserRequest.perform(UserRequest.java:211)
        at hudson.remoting.UserRequest.perform(UserRequest.java:54)
        at hudson.remoting.Request$2.run(Request.java:376)
        at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:122)
Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from hostname/IP:50925
        at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1797)
        at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:356)
        at hudson.remoting.Channel.call(Channel.java:1001)
        at hudson.plugins.logparser.LogParserStatusComputer.computeStatusMatches(LogParserStatusComputer.java:47)
        at hudson.plugins.logparser.LogParserStatusComputer.<init>(LogParserStatusComputer.java:36)
        at hudson.plugins.logparser.LogParserParser.parseLogBody(LogParserParser.java:355)
        at hudson.plugins.logparser.LogParserParser.parseLog(LogParserParser.java:165)
        at hudson.plugins.logparser.LogParserPublisher.perform(LogParserPublisher.java:119)
        at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
        at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:78)
        at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
        at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:806)
        at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:755)
        at hudson.model.Build$BuildExecution.post2(Build.java:178)
        at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:699)
        at hudson.model.Run.execute(Run.java:1913)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
        at hudson.model.ResourceController.execute(ResourceController.java:99)
        at hudson.model.Executor.run(Executor.java:431)
java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 3
e:\jenkbuilds\(. )\builds/[0-9] (/.*)?
   ^
    at java.util.regex.Pattern.error(Unknown Source)
    at java.util.regex.Pattern.escape(Unknown Source)
    at java.util.regex.Pattern.atom(Unknown Source)
    at java.util.regex.Pattern.sequence(Unknown Source)
    at java.util.regex.Pattern.expr(Unknown Source)
    at java.util.regex.Pattern.compile(Unknown Source)
    at java.util.regex.Pattern.<init>(Unknown Source)
    at java.util.regex.Pattern.compile(Unknown Source)
    at jenkins.security.s2m.RunningBuildFilePathFilter.op(RunningBuildFilePathFilter.java:91)
    at jenkins.ReflectiveFilePathFilter.read(ReflectiveFilePathFilter.java:21)
    at jenkins.FilePathFilterAggregator.read(FilePathFilterAggregator.java:75)
    at jenkins.SoloFilePathFilter.read(SoloFilePathFilter.java:66)
    at hudson.FilePath.reading(FilePath.java:3497)
    at hudson.FilePath.access$300(FilePath.java:213)
    at hudson.FilePath$CopyTo.invoke(FilePath.java:2507)
    at hudson.FilePath$CopyTo.invoke(FilePath.java:2499)
    at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3338)
    at hudson.remoting.UserRequest.perform(UserRequest.java:211)
    at hudson.remoting.UserRequest.perform(UserRequest.java:54)
    at hudson.remoting.Request$2.run(Request.java:376)
    at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:78)
    at org.jenkinsci.remoting.CallableDecorator.call(CallableDecorator.java:18)
    at hudson.remoting.CallableDecoratorList.lambda$applyDecorator$0(CallableDecoratorList.java:19)
    at jenkins.util.ContextResettingExecutorService$2.call(ContextResettingExecutorService.java:46)
    at jenkins.security.ImpersonatingExecutorService$2.call(ImpersonatingExecutorService.java:80)
    at java.util.concurrent.FutureTask.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Build step 'Console output (build log) parsing' marked build as failure
Archiving artifacts
Recording test results
Finished: FAILURE```

Please let me know if you would like to have more information.

Any help will be greatly appriciated.

CodePudding user response:

Illegal/unsupported escape sequence near index 3 e:\jenkbuilds\(. )\builds/[0-9] (/.*)?
Build step 'Console output (build log) parsing' marked build as failure
Archiving artifacts

It would seem it's interpreting your path regex as an escape character "\j*". Wherever that regex is, try double slash, "e:\\jenbuilds", or try chage to unix style "/".

It's either the ArchiveArtifacts step or right before that. Show your config steps?

CodePudding user response:

I managed to resolve the issue using @Ian W comment. When diving into the 'Log Parser' plugin's settings, I found that my last update to Jenkins plugins reset its settings.

I wasn't aware that there is a modified rule in Jenkins for this plugin.

To be more specific:

To find the list of rules: Manage Jenkins - > Configure System -> Multi-job Retry Rule -> Log Parser Rules

To update the job: Job -> Configure -> Post-Build Actions -> Use Project Rule -> paste rule

I hope this will turn to be useful for someone as this was quite of a challenge to find and fix.

  • Related