{"id":1741,"date":"2017-07-02T21:35:10","date_gmt":"2017-07-02T16:05:10","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=1741"},"modified":"2026-08-28T16:04:36","modified_gmt":"2026-08-28T10:34:36","slug":"install-jenkins-ubuntu-16","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/install-jenkins-ubuntu-16\/","title":{"rendered":"Install Jenkins on Ubuntu 16"},"content":{"rendered":"<h2>Introduction<\/h2>\n<p>Jenkins is one of the most popular open-source automation servers used for Continuous Integration (CI) and Continuous Deployment (CD). It helps development teams automate software building, testing, and deployment processes, improving productivity and reducing manual errors.<\/p>\n<p>With Jenkins, organizations can streamline their DevOps workflows by automatically triggering builds, running tests, and deploying applications whenever code changes are pushed to a repository.<\/p>\n<p>In this guide, we will walk through the complete process of installing Jenkins on an Ubuntu 16.04 server, configuring the required repository, starting the service, and completing the initial web-based setup.<\/p>\n<hr \/>\n<h2>Prerequisites<\/h2>\n<p>Before you begin, ensure you have the following:<\/p>\n<ul>\n<li>Ubuntu 16.04 server<\/li>\n<li>Root or sudo privileges<\/li>\n<li>Internet connectivity<\/li>\n<li>Port <strong>8080<\/strong> allowed through the firewall\/security group<\/li>\n<li>System packages updated to the latest version<\/li>\n<\/ul>\n<hr \/>\n<h2>Step 1: Update the Ubuntu Server<\/h2>\n<p>Start by upgrading all installed packages to ensure the system is up to date.<\/p>\n<pre><code class=\"language-bash\">sudo apt-get update\nsudo apt-get upgrade -y\n<\/code><\/pre>\n<p>It is recommended to reboot the server after the upgrade if kernel updates are installed.<\/p>\n<pre><code class=\"language-bash\">sudo reboot\n<\/code><\/pre>\n<hr \/>\n<h2>Step 2: Add the Jenkins Repository Key<\/h2>\n<p>Jenkins packages are distributed through the official Jenkins repository. Add the Jenkins repository signing key to your server.<\/p>\n<pre><code class=\"language-bash\">wget -q -O - https:\/\/pkg.jenkins.io\/debian\/jenkins-ci.org.key | sudo apt-key add -\n<\/code><\/pre>\n<p>You should see:<\/p>\n<pre><code class=\"language-text\">OK\n<\/code><\/pre>\n<hr \/>\n<h2>Step 3: Add the Jenkins Repository<\/h2>\n<p>Create a Jenkins repository source file and add the official stable repository.<\/p>\n<pre><code class=\"language-bash\">echo \"deb http:\/\/pkg.jenkins.io\/debian-stable binary\/\" | sudo tee \/etc\/apt\/sources.list.d\/jenkins.list\n<\/code><\/pre>\n<hr \/>\n<h2>Step 4: Refresh Package Information<\/h2>\n<p>Update the package cache so Ubuntu can retrieve packages from the newly added Jenkins repository.<\/p>\n<pre><code class=\"language-bash\">sudo apt-get update\n<\/code><\/pre>\n<hr \/>\n<h2>Step 5: Install Jenkins<\/h2>\n<p>Install Jenkins using the package manager.<\/p>\n<pre><code class=\"language-bash\">sudo apt-get install jenkins -y\n<\/code><\/pre>\n<p>The installation process will automatically create the Jenkins service and required directories.<\/p>\n<hr \/>\n<h2>Step 6: Start and Enable Jenkins Service<\/h2>\n<p>Start the Jenkins service.<\/p>\n<pre><code class=\"language-bash\">sudo systemctl start jenkins\n<\/code><\/pre>\n<p>Enable Jenkins to start automatically whenever the server reboots.<\/p>\n<pre><code class=\"language-bash\">sudo systemctl enable jenkins\n<\/code><\/pre>\n<p>Verify that Jenkins is running successfully.<\/p>\n<pre><code class=\"language-bash\">sudo systemctl status jenkins\n<\/code><\/pre>\n<p>Expected output:<\/p>\n<pre><code class=\"language-text\">Active: active (running)\n<\/code><\/pre>\n<hr \/>\n<h2>Step 7: Access Jenkins Web Interface<\/h2>\n<p>Open a web browser and navigate to:<\/p>\n<pre><code class=\"language-text\">http:\/\/SERVER_IP:8080\n<\/code><\/pre>\n<p>Replace <code>SERVER_IP<\/code> with your server&#8217;s public IP address or hostname.<\/p>\n<p>The Jenkins setup wizard will appear.<\/p>\n<hr \/>\n<h2>Step 8: Retrieve the Initial Administrator Password<\/h2>\n<p>Jenkins generates a temporary administrator password during installation.<\/p>\n<p>Retrieve it using:<\/p>\n<pre><code class=\"language-bash\">cat \/var\/lib\/jenkins\/secrets\/initialAdminPassword\n<\/code><\/pre>\n<p>Example output:<\/p>\n<pre><code class=\"language-text\">d5a2f8d9b4c7e1f3a6...\n<\/code><\/pre>\n<p>Copy the password and paste it into the Jenkins setup screen.<\/p>\n<p><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_installation-1.png\"><img fetchpriority=\"high\" decoding=\"async\" class=\"alignnone wp-image-11124 size-full\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_installation-1.png\" alt=\"\" width=\"1355\" height=\"614\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_installation-1.png 1355w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_installation-1-300x136.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_installation-1-1024x464.png 1024w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_installation-1-768x348.png 768w\" sizes=\"(max-width: 1355px) 100vw, 1355px\" \/><\/a><\/p>\n<p>Click <strong>Continue<\/strong>.<\/p>\n<hr \/>\n<h2>Step 9: Install Suggested Plugins<\/h2>\n<p>After unlocking Jenkins, you will be prompted to install plugins.<\/p>\n<p>Select:<\/p>\n<p><strong>Install Suggested Plugins<\/strong><\/p>\n<p><a href=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_suggested-1.png\"><img decoding=\"async\" class=\"alignnone wp-image-11126 size-full\" src=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_suggested-1.png\" alt=\"\" width=\"1303\" height=\"555\" srcset=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_suggested-1.png 1303w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_suggested-1-300x128.png 300w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_suggested-1-1024x436.png 1024w, https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2017\/07\/Jenkins_suggested-1-768x327.png 768w\" sizes=\"(max-width: 1303px) 100vw, 1303px\" \/><\/a><\/p>\n<p>Jenkins will automatically download and install the most commonly used plugins required for CI\/CD pipelines.<\/p>\n<p>This process may take several minutes depending on your internet connection.<\/p>\n<hr \/>\n<h2>Step 10: Create the First Administrator User<\/h2>\n<p>Once the plugins are installed:<\/p>\n<ol>\n<li>Enter a username.<\/li>\n<li>Set a strong password.<\/li>\n<li>Provide an email address.<\/li>\n<li>Click <strong>Save and Continue<\/strong>.<\/li>\n<\/ol>\n<p>You can now log in using the credentials you created.<\/p>\n<hr \/>\n<h2>Step 11: Verify Jenkins Installation<\/h2>\n<p>After logging in, the Jenkins dashboard should be displayed successfully.<\/p>\n<p>You can now:<\/p>\n<ul>\n<li>Create build jobs<\/li>\n<li>Configure CI\/CD pipelines<\/li>\n<li>Connect Git repositories<\/li>\n<li>Install additional plugins<\/li>\n<li>Integrate with Docker and Kubernetes<\/li>\n<li>Automate deployments<\/li>\n<\/ul>\n<hr \/>\n<h2>Useful Jenkins Commands<\/h2>\n<h3>Check Service Status<\/h3>\n<pre><code class=\"language-bash\">sudo systemctl status jenkins\n<\/code><\/pre>\n<h3>Restart Jenkins<\/h3>\n<pre><code class=\"language-bash\">sudo systemctl restart jenkins\n<\/code><\/pre>\n<h3>Stop Jenkins<\/h3>\n<pre><code class=\"language-bash\">sudo systemctl stop jenkins\n<\/code><\/pre>\n<h3>View Jenkins Logs<\/h3>\n<pre><code class=\"language-bash\">sudo journalctl -u jenkins -f\n<\/code><\/pre>\n<hr \/>\n<h2>Troubleshooting<\/h2>\n<h3>Jenkins Not Accessible on Port 8080<\/h3>\n<p>Verify Jenkins is running:<\/p>\n<pre><code class=\"language-bash\">sudo systemctl status jenkins\n<\/code><\/pre>\n<p>Check whether port 8080 is listening:<\/p>\n<pre><code class=\"language-bash\">sudo netstat -tulpn | grep 8080\n<\/code><\/pre>\n<p>If a firewall is enabled, allow port 8080:<\/p>\n<pre><code class=\"language-bash\">sudo ufw allow 8080\/tcp\n<\/code><\/pre>\n<h3>Unable to Retrieve Admin Password<\/h3>\n<p>Verify the Jenkins installation completed successfully:<\/p>\n<pre><code class=\"language-bash\">sudo ls -l \/var\/lib\/jenkins\/secrets\/\n<\/code><\/pre>\n<p>Then retry:<\/p>\n<pre><code class=\"language-bash\">sudo cat \/var\/lib\/jenkins\/secrets\/initialAdminPassword\n<\/code><\/pre>\n<hr \/>\n<h2>Conclusion<\/h2>\n<p>Installing Jenkins on Ubuntu 16.04 is a straightforward process that provides a powerful foundation for implementing Continuous Integration and Continuous Deployment practices. By following the steps outlined in this guide, you can quickly deploy Jenkins, secure the initial setup, and begin automating software delivery workflows.<\/p>\n<p>Once Jenkins is operational, you can further enhance your DevOps environment by integrating source control platforms such as GitHub and GitLab, container platforms like Docker, and orchestration solutions such as Kubernetes. These integrations enable faster releases, improved code quality, and a more reliable deployment pipeline for modern applications.<\/p>\n<hr \/>\n<h2>Frequently Asked Questions (FAQ)<\/h2>\n<h3>1. Why is Jenkins not accessible on port 8080?<\/h3>\n<p class=\"isSelectedEnd\">If Jenkins is not accessible from your browser, ensure that the Jenkins service is running and that port 8080 is allowed through your firewall or cloud security group. You can verify the service status using:<\/p>\n<pre dir=\"ltr\"><code dir=\"ltr\">sudo systemctl status jenkins<\/code><\/pre>\n<h3>2. How do I retrieve the Jenkins initial administrator password?<\/h3>\n<p class=\"isSelectedEnd\">After installation, Jenkins generates a temporary administrator password. You can retrieve it by running:<\/p>\n<pre dir=\"ltr\"><code dir=\"ltr\">cat \/var\/lib\/jenkins\/secrets\/initialAdminPassword<\/code><\/pre>\n<p class=\"isSelectedEnd\">Copy the password and use it to unlock the Jenkins setup wizard.<\/p>\n<h3>3. Can Jenkins be integrated with GitHub?<\/h3>\n<p>Yes. Jenkins can be integrated with GitHub to automatically trigger builds whenever code is pushed to a repository. This enables automated testing, building, and deployment as part of a CI\/CD pipeline.<\/p>\n<hr \/>\n<div class=\"item_measurer\" role=\"listitem\">\n<div class=\"\">\n<div id=\"post_rgqri8smhig59fmktnccpuuuqw\" class=\"a11y__section post other--root\" aria-label=\"At 12:30 PM Friday, August 21, kaviya wrote, Related Articles\n----------------\n\n1.  **How to Use a Sub Folder in Default Controller Route in CodeIgniter 3**  \n    [How to Use a Sub Folder in Default Controller Route in CodeIgniter 3](https:\/\/pheonixsolutions.com\/blog\/use-sub-folder-default-controller-route-codeigniter-3\/?utm_source=chatgpt.com)\n2.  **Send Email Using HTML Templates in CodeIgniter**  \n    [Send Email Using HTML Templates in CodeIgniter](https:\/\/pheonixsolutions.com\/blog\/send-email-using-html-templates-codeigniter\/?utm_source=chatgpt.com)\n3.  **Currency Conversion and Symbol Library in CodeIgniter**  \n    [Currency Conversion and Symbol Library in CodeIgniter](https:\/\/pheonixsolutions.com\/blog\/currency-conversion-and-symbol-library-in-codeigniter\/?utm_source=chatgpt.com)\" data-testid=\"postView\"><\/p>\n<div class=\"post__content\" data-testid=\"postContent\">\n<div id=\"rgqri8smhig59fmktnccpuuuqw_message\" class=\"post__body\">\n<div class=\"AutoHeight\">\n<div class=\"post-message post-message--collapsed\">\n<div class=\"post-message__text-container\">\n<div id=\"postMessageText_rgqri8smhig59fmktnccpuuuqw\" class=\"post-message__text\" dir=\"auto\">\n<h2 class=\"markdown__heading\">Related Articles<\/h2>\n<ol class=\"markdown__list\">\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/integration-of-sonarqube-in-jenkins\/\"><span data-sheets-root=\"1\">Integration of SonarQube in Jenkins<\/span><\/a><\/li>\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/schedule-job-in-jenkins\/\">Schedule Job in<\/a><a href=\"https:\/\/pheonixsolutions.com\/blog\/schedule-job-in-jenkins\/\"> J<\/a><a href=\"https:\/\/pheonixsolutions.com\/blog\/schedule-job-in-jenkins\/\">enkins<\/a><\/li>\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/how-to-upgrade-jenkins-to-2-414\/\">How to upgrade Jenkins to 2.414<\/a><\/li>\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/jenkins-user-creation-and-permission-management-guide\/\"><span data-sheets-root=\"1\">Jenkins User Creation and Permission Management Guide<\/span><\/a><\/li>\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/building-a-reusable-react-component-library-with-typescript\/\"><span data-sheets-root=\"1\">How to Configure the Bitbucket credentials in Jenkins<\/span><\/a><\/li>\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/how-to-update-node-server-credentials-in-jenkins\/\"><span data-sheets-root=\"1\">How to Update Node Server Credentials in Jenkins<\/span><\/a><\/li>\n<li><a href=\"https:\/\/pheonixsolutions.com\/blog\/connect-windows-agent-to-jenkins\/\">How to Connect a Windows Node (Agent) to Jenkins: A Complete Guide<\/a>\n<div class=\"entry-meta psol-meta-fixed\"><\/div>\n<\/li>\n<\/ol>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"post__body-reactions-acks\"><\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"item_measurer\" role=\"listitem\">\n<div class=\"post-row__padding bottom\">\n<div id=\"post_zmuzuy986tdfdczjjq4e8f94eh\" class=\"a11y__section post other--root post--hovered\" aria-label=\"At 9:07 PM Friday, August 21, kaviya wrote, please check this email bounce \" data-testid=\"postView\">\n<div class=\"post__content\" data-testid=\"postContent\">\n<div class=\"post__img\"><\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Introduction Jenkins is one of the most popular open-source automation servers used for Continuous Integration (CI) and Continuous Deployment (CD). [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1020],"tags":[354,274],"class_list":["post-1741","post","type-post","status-publish","format-standard","hentry","category-containers-kubernetes","tag-jenkins","tag-ubuntu","psol-cat-containers-kubernetes"],"jetpack_publicize_connections":[],"jetpack_shortlink":"https:\/\/wp.me\/phn2x7-s5","jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1741","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=1741"}],"version-history":[{"count":1,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1741\/revisions"}],"predecessor-version":[{"id":11132,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/1741\/revisions\/11132"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=1741"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=1741"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=1741"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}