<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Jenkins Archives - Rhein-Ruhr-Informatik</title>
	<atom:link href="https://rhein-ruhr-informatik.de/en/category/articles/jenkins/feed/" rel="self" type="application/rss+xml" />
	<link>https://rhein-ruhr-informatik.de/en/category/articles/jenkins/</link>
	<description></description>
	<lastbuilddate>Tue, 11 Mar 2025 08:44:41 +0000</lastbuilddate>
	<language>en-US</language>
	<sy:updateperiod>
	hourly	</sy:updateperiod>
	<sy:updatefrequency>
	1	</sy:updatefrequency>
	

<image>
	<url>https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/cropped-favicon-32x32.png</url>
	<title>Jenkins Archives - Rhein-Ruhr-Informatik</title>
	<link>https://rhein-ruhr-informatik.de/en/category/articles/jenkins/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Jenkins auf Ubuntu 22.04 LTS installieren und einige Administrationsaufgaben</title>
		<link>https://rhein-ruhr-informatik.de/en/2025/03/01/jenkins-auf-ubuntu-22-04-lts-installieren-und-einige-administrationsaufgaben/</link>
		
		<dc:creator><![CDATA[Rhein-Ruhr-Informatik]]></dc:creator>
		<pubdate>Sat, 01 Mar 2025 16:51:43 +0000</pubdate>
				<category><![CDATA[Artikel]]></category>
		<category><![CDATA[Jenkins]]></category>
		<category><![CDATA[Linux]]></category>
		<guid ispermalink="false">https://rhein-ruhr-informatik.de/?p=454</guid>

					<description><![CDATA[<p>Übersicht Jenkins ist eine äußerst beliebte Open-Source-Webanwendung, die entwickelt wurde, um den Softwareentwicklungsprozess zu rationalisieren und zu automatisieren. Es ist ein Eckpfeiler für Continuous Integration (CI) und Continuous Delivery (CD)-Pipelines und ermöglicht es Entwicklern und DevOps-Teams, Anwendungen effizient zu erstellen, zu testen und bereitzustellen. Jenkins installieren&#160;&#160;&#160;&#160;&#160; Es gibt viele Methoden,<a class="moretag" href="https://rhein-ruhr-informatik.de/en/2025/03/01/jenkins-auf-ubuntu-22-04-lts-installieren-und-einige-administrationsaufgaben/"> Read more&#8230;</a></p>
<p>The post <a href="https://rhein-ruhr-informatik.de/en/2025/03/01/jenkins-auf-ubuntu-22-04-lts-installieren-und-einige-administrationsaufgaben/">Jenkins auf Ubuntu 22.04 LTS installieren und einige Administrationsaufgaben</a> appeared first on <a href="https://rhein-ruhr-informatik.de/en">Rhein-Ruhr-Informatik</a>.</p>
]]></description>
										<content:encoded><![CDATA[<div class="wp-block-image">
<figure class="aligncenter size-full is-resized"><img fetchpriority="high" decoding="async" width="408" height="389" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-17.png" alt="" class="wp-image-455" style="width:306px;height:auto" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-17.png 408w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-17-300x286.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-17-13x12.png 13w" sizes="(max-width: 408px) 100vw, 408px" /></figure></div>


<p><strong>Overview</strong></p>



<p>Jenkins is a highly popular open-source web application designed to streamline and automate the software development process. It's a cornerstone tool for Continuous Integration (CI) and Continuous Delivery (CD) pipelines, allowing developers and DevOps teams to build, test, and deploy applications efficiently.<strong>.</strong></p>



<p><strong>Installing Jenkins&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</strong></p>



<p>There are many methods to install Jenkins in Ubuntu. Before we go to install Jenkins, we need to have already installed Java JRE (Java Runtime Environment). OpenJDK is an open-source implementation of the Java Platform It provides the core components necessary for running Java applications.</p>



<p>We will work on Ubuntu-22.04 version:</p>



<figure class="wp-block-image size-full"><img decoding="async" width="1019" height="322" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-8.png" alt="" class="wp-image-774" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-8.png 1019w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-8-300x95.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-8-768x243.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-8-18x6.png 18w" sizes="(max-width: 1019px) 100vw, 1019px" /></figure>



<p>Let’s install OpenJDK-11 release. The steps to install this distribution in our system via putty interface. 
We going to download the file OpenJDK-11 as archived file from the official website [<a href="https://jdk.java.net/archive/" target="_blank" rel="noreferrer noopener">https://jdk.java.net/archive/</a>] locally,</p>


<div class="wp-block-image">
<figure class="aligncenter size-full is-resized"><img decoding="async" width="992" height="558" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-18.png" alt="" class="wp-image-456" style="width:742px;height:auto" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-18.png 992w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-18-300x169.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-18-768x432.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-18-18x10.png 18w" sizes="(max-width: 992px) 100vw, 992px" /><figcaption class="wp-element-caption"><em>OpenJDK download</em></figcaption></figure></div>


<p>Then via WinSCP app we can access our Linux (Ubuntu) environment to transfer it as Binary file.</p>


<div class="wp-block-image">
<figure class="aligncenter size-large is-resized"><img loading="lazy" decoding="async" width="1024" height="522" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-19-1024x522.png" alt="" class="wp-image-457" style="width:792px;height:auto" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-19-1024x522.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-19-300x153.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-19-768x392.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-19-18x9.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-19.png 1086w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption class="wp-element-caption"><em>OpenJDK file transfer</em></figcaption></figure></div>


<p>After we have the archive file in our environment, we need first to extract it via cli.</p>



<p><strong>tar -xvzf openjdk-17.0.1_linux-x64_bin.tar.gz</strong></p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="62" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-9-1024x62.png" alt="" class="wp-image-776" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-9-1024x62.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-9-300x18.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-9-768x47.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-9-18x1.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-9.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>As we have the file in just read and write permission, we are going to give it the execute permission like:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="54" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-10-1024x54.png" alt="" class="wp-image-777" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-10-1024x54.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-10-300x16.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-10-768x41.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-10-18x1.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-10.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>Then when we list, it gives:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="66" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-11-1024x66.png" alt="" class="wp-image-778" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-11-1024x66.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-11-300x19.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-11-768x49.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-11-18x1.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-11.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>Jetzt können wir OpenJDK-17 mit dem folgenden Befehl installieren:</p>



<p><strong>sudo apt install openjdk-17-jdk -y</strong></p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="167" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-12-1024x167.png" alt="" class="wp-image-780" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-12-1024x167.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-12-300x49.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-12-768x125.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-12-18x3.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-12.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>Da jedoch OpenJDK-17 bereits in meiner Umgebung installiert ist, wird die neueste Version angezeigt.</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="85" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-13-1024x85.png" alt="" class="wp-image-781" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-13-1024x85.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-13-300x25.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-13-768x64.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-13-18x2.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-13.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<pre class="wp-block-code"><code></code></pre>



<p>After Installation we check if the Jenkins service is active.</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="220" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-14-1024x220.png" alt="" class="wp-image-782" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-14-1024x220.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-14-300x64.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-14-768x165.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-14-18x4.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2025/03/image-14.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<pre class="wp-block-code"><code>  
  root@master:/home/bekber1# systemctl
  status jenkins
  ● jenkins.service
  - Jenkins Continuous Integration Server
  &nbsp;&nbsp;&nbsp;&nbsp;
  Loaded: loaded (/lib/systemd/system/jenkins.service; enabled; vendor
  preset: enabled)
  &nbsp;&nbsp;&nbsp;&nbsp;
  Active: active (running) since Tue 2024-09-03 06:34:13 UTC; 2h 58min
  ago
  &nbsp;&nbsp;
  Main PID: 18413 (java)
  &nbsp;&nbsp;&nbsp;&nbsp;
  &nbsp;Tasks: 63 (limit: 2178)
  &nbsp;&nbsp;&nbsp;&nbsp;
  Memory: 791.1M
  &nbsp;&nbsp;&nbsp;&nbsp;
  CGroup: /system.slice/jenkins.service
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; └─18413 /usr/bin/java
  -Djava.awt.headless=true -jar /usr/share/java/jenkins.war
  --webroot=/var/cache/jenkins/war --httpPort=xxx
  
</code></pre>



<p>So, we can see that Jenkins service is Active.
Now to be able to access the Jenkins from the web browser we need to setting up the default UFW firewall.</p>



<p>Open port 8080 by running the following commands:</p>



<pre class="wp-block-code"><code> 
  root@master:/home/bekber1#
  ufw allow 8080
  Rule
  added
  Rule
  added (v6)
  &nbsp;
  root@master:/home/bekber1#
  ufw status
  Status:
  active<span style="color:red;mso-ansi-language:EN-US"></span>
 </code></pre>


<div class="wp-block-image">
<figure class="aligncenter size-full is-resized"><img loading="lazy" decoding="async" width="846" height="642" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-24.png" alt="" class="wp-image-462" style="width:660px;height:auto" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-24.png 846w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-24-300x228.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-24-768x583.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-24-16x12.png 16w" sizes="auto, (max-width: 846px) 100vw, 846px" /></figure></div>


<p>In the putty cli we use the command to get the admin password:</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="28" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-25-1024x28.png" alt="" class="wp-image-463" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-25-1024x28.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-25-300x8.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-25-768x21.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-25-18x1.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-25.png 1089w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p>We copy the password provided by default and paste it in the filed shown in the picture above and then click Continue button. After this we getting started:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="702" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-26.png" alt="" class="wp-image-464" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-26.png 940w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-26-300x224.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-26-768x574.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-26-16x12.png 16w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p>After the installation and configuration, we must create our first Admin user as show in the picture below:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="896" height="639" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-27.png" alt="" class="wp-image-465" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-27.png 896w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-27-300x214.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-27-768x548.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-27-18x12.png 18w" sizes="auto, (max-width: 896px) 100vw, 896px" /></figure>



<p>Now we can click Save and Continue and then getting the Jenkins URL as shown below:</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="881" height="611" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-28.png" alt="" class="wp-image-466" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-28.png 881w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-28-300x208.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-28-768x533.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-28-18x12.png 18w" sizes="auto, (max-width: 881px) 100vw, 881px" /></figure>



<p>Now Jenkins is ready, and we can start and using it.</p>


<div class="wp-block-image">
<figure class="aligncenter size-large"><img loading="lazy" decoding="async" width="1024" height="331" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-30-1024x331.png" alt="" class="wp-image-468" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-30-1024x331.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-30-300x97.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-30-768x248.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-30-18x6.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-30.png 1089w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption class="wp-element-caption"><em>start with Jenkins</em></figcaption></figure></div>

<div class="wp-block-image">
<figure class="aligncenter size-large"><img loading="lazy" decoding="async" width="1024" height="297" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-31-1024x297.png" alt="" class="wp-image-469" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-31-1024x297.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-31-300x87.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-31-768x223.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-31-18x5.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-31.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption class="wp-element-caption"><em>Login</em></figcaption></figure></div>

<div class="wp-block-image">
<figure class="aligncenter size-large"><img loading="lazy" decoding="async" width="1024" height="279" src="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-32-1024x279.png" alt="" class="wp-image-470" srcset="https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-32-1024x279.png 1024w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-32-300x82.png 300w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-32-768x209.png 768w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-32-18x5.png 18w, https://rhein-ruhr-informatik.de/wp-content/uploads/2024/10/image-32.png 1090w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption class="wp-element-caption"><em>Jenkins-Dashboard</em></figcaption></figure></div>


<p>How to change Jenkins Administrator password if we lost it:</p>



<p>If we forget the Jenkins Admin password for web browser, to reset it we should follow the steps as below:</p>



<p>First, we need to find where is the config.xml file is located in:</p>



<pre class="wp-block-code"><code>root@master:/home/bekber1# cd /var/lib/jenkins/ </code></pre>



<p>First, we need to find where is the config.xml file is located in:</p>



<pre class="wp-block-code"><code>root@master:/var/lib/jenkins# vim config.xml</code></pre>



<p>So, concatonating this file in cli you can see inside the line named: <code>"&lt;useSecurity&gt;true&lt;/useSecurity&gt;"</code> We change it from<strong>true</strong>to<strong>false</strong>and we restart the Jenkins service afterwards like:</p>



<p><code>systemctl restart jenkins&nbsp;</code></p>



<p>After these steps we refresh the web browser page and we will get inside the Jenkins page to make the changes because it is unsecured.</p>



<p>First step is to choose the<strong>Manage Jenkins</strong>and after we click on<strong>Security Realm</strong>&#8220; &#8222;<strong>Jenkins&#8216; own user database</strong>. We save it and close.</p>



<p>After this we can go to the under<strong>Manage Jenkins</strong>&#8220; -&gt; &#8222;<strong>Security</strong>&#8220; -&gt; &#8222;<strong>Users</strong>we click on<strong>Settings</strong>click and under<strong>Password</strong>we change the password.</p>



<p><strong>How-create-agent-for-built-in-node</strong></p>



<p>In Jenkins, agents are essential for executing build jobs. Steps that we should follow are:</p>



<p>We have to configuring .ssh inside the /var/lib/jenkins/.ssh/known_host</p>



<p>- we create the folder named .ssh</p>



<pre class="wp-block-code"><code>root@master:/var/lib/jenkins#mkdir -p /var/lib/jenkins/.ssh
root@master:/var/lib/jenkins# chown -R jenkins:jenkins .ssh
root@master:/var/lib/jenkins#ssh-keyscan -H agent1 &gt;&gt; /var/lib/jenkins/.ssh/known_host

</code></pre>



<p>If doesn't work as e.g.</p>



<pre class="wp-block-code"><code>root@master:/etc/ssh# ssh-keyscan -H agent1 &gt;&gt; /var/lib/jenkins/.ssh/known_hosts
getaddrinfo agent1: Temporary failure in name resolution
getaddrinfo agent1: Temporary failure in name resolution
getaddrinfo agent1: Temporary failure in name resolution
getaddrinfo agent1: Temporary failure in name resolution
getaddrinfo agent1: Temporary failure in name resolution

</code></pre>



<p>we need to add agent1 server ip in the <code>/etc/hosts</code>-Datei hinzufügen.&nbsp;</p>



<p>To find the agent1 ip address, we use the command:</p>



<pre class="wp-block-code"><code>root@master:/etc/ssh# dig agent1
 
; &lt;&lt;&gt;&gt; DiG 9.16.48-Ubuntu &lt;&lt;&gt;&gt; agent1
;; global options: +cmd
;; Got answer:
;; -&gt;&gt;HEADER&lt;&lt;- opcode: QUERY, status: SERVFAIL, id: 15329
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 1
 
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 65494
;; QUESTION SECTION:
;agent1.                                IN      A
 ;; Query time: 0 msec
;; SERVER: &lt;MyIpAddress&gt;#53(&lt;MyIpAddress&gt;)
;; WHEN: Sun Mar 10 10:33:06 UTC 2024
;; MSG SIZE  rcvd: 35

</code></pre>



<p>and edit the /etc/hosts with the nano editor like:</p>



<pre class="wp-block-code"><code>root@master:/etc# cat hosts
&lt;MyIpAddress&gt;localhost
&lt;MyIpAddress&gt;linux-0
&lt;MyIpAddress&gt;master
&lt;MyIpAddress&gt;node1
&lt;MyIpAddress&gt;node2
&lt;MyIpAddress&gt; agent1    ----------&gt; mit dem Nano- oder Vim-Editor müssen wir die IP-Adresse von agent1 hinzufügen.
/etc/hosts
# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
</code></pre>



<p>Nach Ausführung des Befehls ssh-keyscan -H agent1 &gt;&gt; /var/lib/jenkins/.ssh/known_hosts erhalten wir die Auflösung:</p>



<pre class="wp-block-code"><code>root@master:/etc# ssh-keyscan -H agent1 &gt;&gt; /var/lib/jenkins/.ssh/known_hosts
# agent1:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.11
# agent1:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.11
# agent1:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.11
# agent1:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.11
# agent1:22 SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.11
</code></pre>



<p>Jenkins agent1 in port 22 is resolved:</p>



<pre class="wp-block-code"><code>root@master:/etc# cd /var/lib/jenkins/.ssh/
root@master:/var/lib/jenkins/.ssh# ll
total 12
drwxr-xr-x  2 jenkins jenkins 4096 Mar 10 10:11 ./
drwxr-xr-x 15 jenkins jenkins 4096 Mar 10 10:05 ../
-rw-r--r--  1 jenkins jenkins  978 Mar 10 10:36 known_hosts

root@master:/var/lib/jenkins/.ssh# cat known_hosts
|1|UMnpRmZeDMTxf8bAmPYanyzeE54=|C7tpVgwzVbu7FDJG4fUiDVN3L4I= ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBAunO9x3A5IInM2Qqqf4wwWBEokfH8pRiMVcrjNTNn7hCZrgi75hbRbV+dG8hy2xhUtDlywP0k0S/+qpSwoVd7E=
|1|nPGx2tNNjsRAU6ZYf7UqlI1iGcM=|TqWQT18KAS56FgREOVEfVUvvILQ= ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDTy0gPfw8tQ7T2VkFlp82regznVnrZx7tlsgLqlOWVqzhCPrA4/V0DlOsHRjDKUFNnrH+LgOSSAmZwqRrHYyy6Oe+BkmXU4v5a8oZPA1xYRSL/Q1YDYhiMeySilDDzUQwy6HqcmlpPHdPFsl/S/vQIoCAlP5PbS9/GYXILJJj2bxVjqq/nWeC3QywDsoch02XxPpQORk3qFPKDAbc8AWn26v/zHXFgjEig0vW+el1gjkKe8scNTvjVhRot31gD3SdM39SpEspD+Unkw0EhI60hnQeZjiunRUM9/Za2sw3cFGOCXOySDPrkZ2mm10geTZVDF4JTm+pdsv8cmLOUSooRWg+t8R6MK7ZDmeW1aRScpy5R8je0fuGU7XX/P+RNs27TFJQevE0EwWcTYMtBMQunuuqGFBVUBIOMZzwKeipojx9mGXhDp+TiHsQRXq/9nIOdiDfrub658RUJBgZsaX7fAsnnMMbjf0qBSXdikNoQHm+SrvxI4I7L7XawidSqWkU=
|1|1JIhNCOumg+yjaTgMMYtcGAkC6o=|B/ZgF81ZU+t+8AbByBU3hwp68X0= ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFLr95lmAUl1k0+zxfhzG4B9fvrvPtddpxOCII+abRfO

root@master:/var/lib/jenkins/.ssh#
</code></pre>



<p>Jenkins-Logs:</p>



<pre class="wp-block-code"><code>Warning: no key algorithms provided; JENKINS-42959 disabled
SSHLauncher{host='agent1', port=22, credentialsId='linux-0', jvmOptions='', javaPath='', prefixStartSlaveCmd='', suffixStartSlaveCmd='', launchTimeoutSeconds=60, maxNumRetries=10, retryWaitTime=15, sshHostKeyVerificationStrategy=hudson.plugins.sshslaves.verifiers.KnownHostsFileKeyVerificationStrategy, tcpNoDelay=true, trackCredentials=true}
&#91;03/10/24 10:43:30] &#91;SSH] Opening SSH connection to agent1:22.
Searching for agent1 in /var/lib/jenkins/.ssh/known_hosts
Searching for agent1:22 in /var/lib/jenkins/.ssh/known_hosts
&#91;03/10/24 10:43:30] &#91;SSH] SSH host key matches key in Known Hosts file. Connection will be allowed.
&#91;03/10/24 10:43:31] &#91;SSH] Authentication successful.
&#91;03/10/24 10:43:32] &#91;SSH] The remote user's environment is:
BASH=/usr/bin/bash
.
.
.
&lt;===&#91;JENKINS REMOTING CAPACITY]===&gt;channel started
Remoting version: 3206.vb_15dcf73f6a_9
Launcher: SSHLauncher
Communication Protocol: Standard in/out
This is a Unix agent
Agent successfully connected and online
</code></pre>



<p><strong>Conclusion</strong></p>



<p>Jenkins is a valuable tool for automating software development processes. By understanding its core features, installation, configuration, security, and agent management, you can effectively leverage Jenkins to improve your CI/CD pipelines and deliver high-quality software.</p>



<p><strong>Referenz:</strong></p>



<p><a href="https://community.jenkins.io/t/can-i-create-agent-for-built-in-node/1183">https://community.jenkins.io/t/can-i-create-agent-for-built-in-node/1183</a></p>



<p><a href="https://jdk.java.net/archive">https://jdk.java.net/archive</a></p>



<p></p><p>The post <a href="https://rhein-ruhr-informatik.de/en/2025/03/01/jenkins-auf-ubuntu-22-04-lts-installieren-und-einige-administrationsaufgaben/">Jenkins auf Ubuntu 22.04 LTS installieren und einige Administrationsaufgaben</a> appeared first on <a href="https://rhein-ruhr-informatik.de/en">Rhein-Ruhr-Informatik</a>.</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>