I installed Jenkins 2.19.3 on my Rhel 8 server and I able to see the jenkins GUI successfully. The problem is the Plugins aren't installed. I referred some forum and edit the jenkins file which is located in init.d folder.
JAVA_CMD="$JENKINS_JAVA_CMD $JENKINS_JAVA_OPTIONS -DJENKINS_HOME=$JENKINS_HOME -jar $JENKINS_WAR"
to
JAVA_CMD="$JENKINS_JAVA_CMD -Dhudson.model.DownloadService.noSignatureCheck=true $JENKINS_JAVA_OPTIONS -DJENKINS_HOME=$JENKINS_HOME -jar $JENKINS_WAR"
After this change, the installation getting started but again the plugins are failed to install.
can someone please help me to resolve this.
Related
I am trying to deploy a Katalon Testcase to Jenkins but some errors appear, such as:
is not recognized as an internal or external command
Exit 9009
Jenkin using old update jenkin.war
You should Update file at : https://jenkins.io/doc/book/installing/#installing-docker
WAR file
The Web application ARchive (WAR) file version of Jenkins can be installed on any operating system or platform that supports Java.
To download and run the WAR file version of Jenkins:
Download the latest stable Jenkins WAR file to an appropriate directory on your machine.
Open up a terminal/command prompt window to the download directory.
Run the command java -jar jenkins.war.
Browse to http://localhost:8080 and wait until the Unlock Jenkins page appears.
Continue on with the Post-installation setup wizard below.
Solve it well
I have installed jdk 8 and set path in system variable.
I am getting below error and might be because of that not getting user password to login to local host.
my error are below:
Error injecting constructor, java.lang.NoClassDefFoundError: hudson/tools/JDK
Installer$FileSystem
at hudson.os.windows.ManagedWindowsServiceLauncher$DescriptorImpl.<init>(Manag
edWindowsServiceLauncher.java:540)
and
Error injecting constructor, java.lang.NoClassDefFoundError: hudson/tools/JDK
Installer$FileSystem
at hudson.plugins.sshslaves.SSHLauncher$DescriptorImpl.<init>(SSHLauncher.java
:1550)
please help to resolve.
To run the Jenkins WAR from the commandline you would execute
java -jar jenkins.war
This will cause the war file to explode itself to a war directory and as Jenkins includes a JETTY web server it will "self host" at localhost:8080. It will take a couple of minutes to do this. Jenkins will present the new instance wizard screens for you to go through which will install recommended plugins to get going.
Initially you won't have to log into Jenkins as "Anyone can do anything".
The next steps should be:
If you are running on windows, navigate to Manage Jenkins > Install as Windows Service and specify a Jenkins Home directory (Suggest E:\Jenkins or on a secondary partition or C:\Jenkins). The user doing this will need to be an administrator on the machine for this to work.
Install plugins at Manage Jenkins > Manage Plugins
Set up Security at Manage Jenkins > Configure Security
I upgraded Jenkins to 2.32.3 version (in place upgrade) after taking necessary backups (THIN) or $JENKINS_HOME and Jenkins is now UP and running.
Under Manage Jenkins > Manage Plugins, I see the following RED error:
Manage Jenkins
Correct
There are dependency errors loading some plugins:
Environment Injector Plugin v2.1.3
envinject-api v1.2 is missing. To fix, install v1.2 or later.
While trying to install Environment Inject Plugin 2.1.3, the logs (during download/install) shows the same error:
Installing Plugins/Upgrades
Preparation
Checking update center connectivity
Success
Environment Injector Plugin
Failure -
java.io.IOException: Failed to dynamically deploy this plugin
at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1895)
at hudson.model.UpdateCenter$DownloadJob.run(UpdateCenter.java:1652)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at hudson.remoting.AtmostOneThreadExecutor$Worker.run(AtmostOneThreadExecutor.java:110)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.IOException: Failed to install envinject plugin
at hudson.PluginManager.dynamicLoad(PluginManager.java:873)
at hudson.PluginManager.dynamicLoad(PluginManager.java:813)
at hudson.model.UpdateCenter$InstallationJob._run(UpdateCenter.java:1891)
... 5 more
Caused by: java.io.IOException: Environment Injector Plugin v2.1.3 failed to load.
- envinject-api v1.2 is missing. To fix, install v1.2 or later.
at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:621)
at hudson.PluginManager.dynamicLoad(PluginManager.java:863)
... 7 more
Where can I get this envinject-api 1.2 plugin? Should I go grab the Github project (clone it) and build the Maven project and put the hpi file under $JENKINS_HOME/plugins folder?
Under Available plugins tab, I don't see an option to select a given version (only 2.1.3 is available). I don't see envinject-api 1.2 plugin listed there either that I can select. My understanding it, selecting Environment Inject 2.1.3 should auto grab all of its dependent plugins for free per it's MANIFEST file.
$ cat $JENKINS_HOME/plugins/envinject/META-INF/MANIFEST.MF
Manifest-Version: 1.0
Archiver-Version: Plexus Archiver
Created-By: Apache Maven
Built-By: nenashev
Build-Jdk: 1.8.0_121
Extension-Name: envinject
Specification-Title: The Jenkins Plugins Parent POM Project
Implementation-Title: envinject
Implementation-Version: 2.1.3
Plugin-Class: org.jenkinsci.plugins.envinject.EnvInjectPlugin
Group-Id: org.jenkins-ci.plugins
Short-Name: envinject
Long-Name: Environment Injector Plugin
Url: https://wiki.jenkins-ci.org/display/JENKINS/EnvInject+Plugin
Compatible-Since-Version: 2.0
Plugin-Version: 2.1.3
Hudson-Version: 1.625.3
Jenkins-Version: 1.625.3
Plugin-Dependencies: envinject-api:1.2,ivy:1.21;resolution:=optional,m
atrix-project:1.7,script-security:1.22
Plugin-Developers: Gregory Boissinot:gbois:gregory.boissinot#gmail.com
,Oleg Nenashev:oleg_nenashev:o.v.nenashev#gmail.com,Manuel Recena:rec
ena:recena#gmail.com
For some reason Jenkins plugins (didn't download the dependent plugins per the Manifest file).
As envinject-api plugin was not listed in the AVAILABLE plugin tab (under Manage Jenkins > Manage Plugins section), I had to manually download the .hpi / .jpi file directly from the following download plugins URL and then I placed the file in $JENKINS_HOME/plugins folder.
https://updates.jenkins-ci.org/download/plugins/
wget https://updates.jenkins-ci.org/download/plugins/envinject-api/1.2/envinject-api.hpi
Restarted Jenkins sudo service jenkins restart (or any other way you have setup) and this issue went away from both Jenkins GUI and from tail -f /var/log/jenkins/jenkins.log
PS: Don't just randomly select a latest version of any plugin or it's dependent plugin. It may not work and break more other plugins as it depends upon your current Jenkins version.
Found this link for Juseppe, not sure how relevant is this but seems interesting: https://github.com/yandex-qatools/juseppe
I followed the SonarQube Jenkins integration tutorial from SonarQube official website. I am getting an error after building my project.
[RetailerWebsite_releaseTestCodeDx] $ "C:\Program Files (x86)\Jenkins2\tools\hudson.plugins.sonar.SonarRunnerInstallation\My_scanner\bin\sonar-scanner.bat" "SonarQube Scanner" -e -Dsonar.host.url=http://10.252.80.55:9000 -Dsonar.projectName=RetailerWebsite -Dsonar.projectVersion=1.0 -Dsonar.projectKey=Retailer-Website -Dsonar.sources=. -Dsonar.projectBaseDir=D:\Builds\RetailerWebsite_releaseTestCodeDx
\Jenkins2\tools\hudson.plugins.sonar.SonarRunnerInstallation\My_scanner\bin\..\jre was unexpected at this time.
ERROR: SonarQube scanner exited with non-zero code: 255
Project Configuration
Global Configuration
It appears you are victim of this Jenkins bug: when using a JRE installed at a path that includes parentheses, Jenkins (on Windows) tries to execute an invalid command.
Workaround: install the JDK elsewhere, and use that one in your Job configuration (or Jenkins itself).
When I try to build JHipster on a windows Jenkins instance, I get the following error
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal com.github.trecloux:yeoman-maven-plugin:0.4:build (run-frontend-build) on project jhipster: Error during : cmd /c bower --version
I tried running Pprod clean package from the commandline and it works fine.
Any thoughts / Help appreciated.
That's because Jenkins's node environment is not complete, make sure bower is in its path. Bower should be installed using npm install -g bower
Please refer to our documentation about Jenkins setup: http://jhipster.github.io/setting-up-ci/
Thanks to Gaƫl Marziou, I zeroed in on the problem to access issues for the Jenkins user. I was able to solve it using the NodeJS plugin.