Category Archives: Jenkins 2.9

 

For course:

  1. This is for OPTs and the Indian colleges fresh graduates who came/passed out in 2019.

  2. who are self driven and try for jobs with the given skills learning without getting into somebody shoes, come and get trained.

  3. A new batch is planned in a cost effective way. Contact in the given FB links from the blog. Good luck in your job search and in IT profession.

Free-orientation-for Freshers-2019

Join in the below group to follow the above guidelines:

https://www.facebook.com/groups/817762795246646/

This group is meant only for freshers/OPTs coaching on the topics mentioned in the group Logo. You can forward to your circles who all came out from college for 2019. They need to provide evidences as they are from 2019 batch only. The FB ID need to have photo with profile details. With these specs only they are allowed in this group.

For course: This is for OPTs and the Indian college graduate who came/passed out in 2019. who are self driven and try for jobs with the given skills learning without getting into somebody shoes, come and get trained. A new batch is planned in a cost effective way. Contact in the given FB links from the blog. Good luck in your job search and in IT profession.

https://www.linkedin.com/jobs/aws-jobs/

1. AWS:How to create and activate a new account in AWS ?

AWS Account-creation scrn

How to create and activate a new account in AWS ?:

In this blog, you will see the required steps for creating and activating your new AWS account. Once have the activated account, you can start your other lab practices as I discuss in the class timely.

The following are the main 4 steps process we need to follow:

STEP1: Creating your account. It consists of 2 steps: a) Providing a valid e-mail address and choosing a password. b) Providing your contact information and setting your preferences.

STEP2: Add a payment method Please note; you need to have a valid CC to give its details. Amazon verifies its transaction also with a tiny charge and with a credit back. If by mistaken given wrong data please note; your account registration process will not be activated. You will be intimated by mail. This way Amazon is authenticating/authorizing us for AWS usage.

STEP3: Verify your phone number. You need to Provide a phone number where you can be reached in next few minutes, while creating your account.

STEP4: Choose the AWS Support plans. Time to time the AWS plans will be published. You need to choose the plan from the currently available plans for your needs. The relevant URL is given in the detailed steps section in this blog.

As a consolidated process, we can understand from the below flow chart. Which is from the collection of AWS process charts.

AWS Account-creation flowchart

Note:

I am not copying the screens due to privacy.

Detailed steps

STEP1: Detailed steps for Creating your account.

a). You need to go to Amazon Web Services home page URL: https://aws.amazon.com/

b). Now, Choose Sign Up. Click on Create an AWS account. You can see new page with Create an AWS account. You need to enter the required details. E-mail id, Pwd, AWS Account name [you can give any name for this]. And choose continue to go to next page. Please note; The above steps are valid for the new users of AWS. If you enter your email address entered incorrectly, you might not be able to access your account or change your password in the future. So you need to be careful on your data entry part. Let us assume; if you’ve signed in to AWS recently, it might say Sign In to the Console. So you need to login into your existing Account.

c). Now in the current page, choose Professional or personal. These two areas will give equal services. Depends on your need You can choose one of the options.

d). From the above options choosed, type the requested company or personal information entries. Note; At this point, You need to go through the AWS Customer Agreement to know their policies and procedures to follow while operating.

e). Finally, you choose Create Account and Continue options in the bottom.

f). Please note; at this point you will receive an e-mail to confirm that your account is created. Now, you can sign in to your new account using the valid email address and valid password you have supplied earlier.

Please note; we have done the Step1 only, the activation process is not yet completed to use the AWS services. Still we need to follow 3 more steps.

STEP2: Add a payment method- Detailed steps:

At this point; On the Payment Information page,

a) Choose the payment method as per the payment gateway standards which is displayed.

b) Type the requested information associated with your payment method. Please make sure the address for your payment method is the same as the address you provided for your account. Note; If your billing address is different; then choose Use a new address, type the billing address for your payment method.

c) Now, choose Secure Submit.

STEP3: Verify your phone number.

Please keep a valid and handy phone number at this point.

a) On this Phone Verification page, type a phone number where can use to accept incoming phone calls.

b) Enter the code displayed in the captcha. When you’re ready to receive a call, choose Call me now option.

c) In a few moments, an automated system will call you to your given phone number. Even it might have SMS feature also, if you are outside North America region.

d) Type the provided PIN on your phone’s keypad of the AWS screen. e) After the process is complete, choose Continue.

STEP4: Choose the AWS Support plans.

a) At this point please visit the below URL: https://aws.amazon.com/premiumsupport/features/

You can select the AWS support plans from the given list.

b) After your selection of a Support plan, a confirmation page denotes that your account is being activated.

c) Please note; Accounts are usually activated within a few minutes, but the process might take up to 24 hours. This process includes the validation of Bank/CC account given there.

d) Hence keep looking for a mail on this subject from Amazon to start your AWS services usage.

Assuming everything went well, and your AWS account is activated now.  Congratulations!

We can look into next lab with reference to the class session.

2. AWS: WordPress[WP] infrastructure creation using a free tier account

https://wordpress.com/post/vskumar.blog/2884

 

If you are interested to learn Virtualization with Vagrant visit:

1. Vagrant/Virtual Box:How to create Virtual Machine[VM] on Windows 10?:

 

Note:

If you are not a student of my class, and looking for it please contact me by mail with your LinkedIn identity. And send a connection request with a message on your need. You can use the below contacts. Please note; I teach globally.

 

Vcard-Shanthi Kumar V-v3

31. DevOps: Jenkins-How to use Backup/Restore using thinbackup plugin ?

\]jenkins

Through this video I have demonstrated the below steps using Jenkins and its thinkbackup plugin process/usage.

=== Steps used in video ====>

How to take jenkins backup ?
1. You need to configure the thinbackup plugin.
2. Search for that plugin in
Manage Jenkins option.
3. Click on Available tab. It shows the locally
available plugins.
4. Then goto filter and type the plugin name as
thinbackup.
5. Now let us check it. You can see the icon,
it is installed.
6. Once you have this, you can explore it.
7. Please note you also need to configure
Restore.
8. Now, let us configure the backup.
After that we can use backupnow option to
take a backup. It stores on the given path.
So, we should use settings.
9. Now, let us test one backup …
10. Let us check the backup file…
11. Observe the created jobs are there…
12. Now, let me run a build..
13.Created 8th Build.
14. Now let me take the new backup…
15. Now, let me use restore to restore
the past build.
16.See the current build history …
17. I am picking up the 1st it was
made in the beginning…
18. Now, let us verify the jenkins
system jobs/builds.
19. It is overwritten on the existing jobs..
20. Let us delete some jobs and restore
the 8thbuild backup.
21. Let me try to restore the latest backup
which has the 8thbuild …
22. Let us restart the server to use the
latest restore …. Let me pause you …
23. It is ready to login … let us test it..
24. Please Note;
When restored it unzipped and kept the files.
When we restarted the jenkins server
it pickedup those files only.
We can see the 8th build is there.
25. From this exercise and trouble shoot,
we can conclude:
i) We need to use thinbackup plugin to
setup backup/restore process.
ii. Initially we use backup plugin and
later we can setup restore setup after
configuring the backup options.

iii. And when we restore a particular build
we need to restart the jenkins server.
That is all for this exercise..

============================>

 

Advt-course3rd page

30. DevOps: Jenkins 2.9-How to remove and re-Install Jenkins 2.9 for Windows 10 with trial job test ?

jenkins

 

Through this video I have demonstrated the following steps:
1. Removing Jenkins from the Laptop/Desktop of Windows10 OS.
2. Installed it as fresh setup on the same machine of Windows10 OS.
3. Played around with 2 jobs creation through Build now.

Also visit:

https://vskumar.blog/2018/02/26/15-devops-how-to-setup-jenkins-2-9-on-ubuntu-16-04-with-jdk8/

https://vskumar.blog/2018/03/03/17-devops-working-with-git-on-ubuntu-16-04-vm/

 

 

29. DevOps: How to access internet through Vmware VM Bridge setup ?

 

Through this video I showed on “How to access internet through Virtual Machine of Vmware”. The required steps for setup is demonstrated along with the played options.

 

 

 

15. DevOps: How to setup jenkins 2.9 on Ubuntu-16.04 with jdk8 with a trouble shoot video guidance

jenkins

In continuation of blog related to Jenkins installation on Win10 url :https://vskumar.blog/2017/11/25/1-devops-jenkins2-9-installation-with-java-9-on-windows-10/

In this blog I would like to demonstrate on Jenkins 2.9 installation using Ubuntu 16.04 OS with JDK8. I used Ubuntu 16.04 VM.  You can use your standalone Ubuntu machine also.

At the end  a video link is given for this entire exercise…. with a job run…

[Note: If you are a student and in need of  Ubuntu 16.04 VM copy, I can share it. You need to send a request through linkedin with your identity please. At the bottom of this blog you can get my details.]

If you want to install Jenkins you need to have JDK in the Ubuntu machine.

You need to install JDK8 as 1st instance for Jenkins setup:

How to install JDK8?:

Step 1:-
Download JDK 8 tar.gz file from official website

Step 2:-
Extract contents using tar command

$tar -xzvf filename.tar.gz

Step 3 :-
Move Extracted file to /usr/local/java Directory
=====CLI Screen output ===>
vskumar@ubuntu:~$ pwd
/home/vskumar
vskumar@ubuntu:~$ cd /usr/local
vskumar@ubuntu:/usr/local$ ls
bin etc games include lib man sbin share src
vskumar@ubuntu:/usr/local$ mkdir java
mkdir: cannot create directory ‘java’: Permission denied
vskumar@ubuntu:/usr/local$ sudo mkdir java
[sudo] password for vskumar:
vskumar@ubuntu:/usr/local$ ls
bin etc games include java lib man sbin share src
vskumar@ubuntu:/usr/local$
vskumar@ubuntu:/usr/local$ cd java
vskumar@ubuntu:/usr/local/java$

vskumar@ubuntu:~$
vskumar@ubuntu:~$ ls
data-volume1 Downloads jdk-9.0.4_linux-x64_bin.tar.gz Public
Desktop examples.desktop Music Templates
Documents flask-test Pictures Videos
vskumar@ubuntu:~$ pwd
/home/vskumar
vskumar@ubuntu:~$

vskumar@ubuntu:~/Downloads$ ls
firefox-57.0.tar.bz2 jdk1.8.0_161 jdk-8u161-linux-x64.tar.gz

vskumar@ubuntu:~/Downloads$ sudo mv jdk1.8.0_161 /usr/local/java
[sudo] password for vskumar:
vskumar@ubuntu:~/Downloads$ ls
firefox-57.0.tar.bz2 jdk-8u161-linux-x64.tar.gz
vskumar@ubuntu:~/Downloads$
vskumar@ubuntu:/usr/local/java$ pwd
/usr/local/java
vskumar@ubuntu:/usr/local/java$ ls -l
total 4
drwxr-xr-x 8 vskumar vskumar 4096 Dec 19 16:24 jdk1.8.0_161
vskumar@ubuntu:/usr/local/java$

==jdk8 unzipped files are moved into /usr/local/java ===>

Step 4: – Now,
Update Alternatives

$sudo update-alternatives –install “/usr/bin/java” “java” “/usr/local/java/jdk1.8.0_161/bin/java” 1

$sudo update-alternatives –install “/usr/bin/javac” “javac” “/usr/local/java/jdk1.8.0_161/bin/javac” 1

$sudo update-alternatives –install “/usr/bin/javaws” “javaws” “/usr/local/java/jdk1.8.0_161/bin/javaws” 1

=== Output===>

vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$ pwd
/usr/local/java/jdk1.8.0_161
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$ sudo update-alternatives –install “/usr/bin/java” “java” “/usr/local/java/jdk1.8.0_161/bin/java” 1
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$ sudo update-alternatives –install “/usr/bin/javac” “javac” “/usr/local/java/jdk1.8.0_161/bin/javac” 1
update-alternatives: using /usr/local/java/jdk1.8.0_161/bin/javac to provide /usr/bin/javac (javac) in auto mode
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$ sudo update-alternatives –install “/usr/bin/javaws” “javaws” “/usr/local/java/jdk1.8.0_161/bin/javaws” 1
update-alternatives: using /usr/local/java/jdk1.8.0_161/bin/javaws to provide /usr/bin/javaws (javaws) in auto mode
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$
==============>

Step 5 :-
Check Java version
$ java -version

======>
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$ java -version
java version “1.8.0_161”
Java(TM) SE Runtime Environment (build 1.8.0_161-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.161-b12, mixed mode)
vskumar@ubuntu:/usr/local/java/jdk1.8.0_161$
====We have done JDKsetup ===>

Now, You can see “How to install Jenkins on Ubuntu 16.04?”:

For details Visit: https://wiki.jenkins.io/display/JENKINS/Installing+Jenkins+on+Ubuntu

Step1:
First, we need to add the jenkins repository key to the ubuntu system.

$ sudo wget -q -O – https://pkg.jenkins.io/debian/jenkins-ci.org.key | sudo apt-key add –

When the key is added, the system will return ‘OK’

Step2:
Now, we need to append the Debian package repository
address to the server’s sources.list:

$echo deb https://pkg.jenkins.io/debian-stable binary/ | sudo tee /etc/apt/sources.list

The screen ouput for the above steps:
=== Screen output of Step1 and Step2====>
vskumar@ubuntu:~$ sudo wget -q -O – https://pkg.jenkins.io/debian/jenkins-ci.org.key | sudo apt-key add –
OK
vskumar@ubuntu:~$ echo deb https://pkg.jenkins.io/debian-stable binary/ | sudo tee /etc/apt/sources.list
deb https://pkg.jenkins.io/debian-stable binary/
vskumar@ubuntu:~$ sudo apt-get update
===============>

When both of the above steps are executed, we’ll run update so that apt-get will use
the new repository:

Step3:
$sudo apt-get update

==== You will see the below screen output ===>
vskumar@ubuntu:~$ echo deb https://pkg.jenkins.io/debian-stable binary/ | sudo tee /etc/apt/sources.list
deb https://pkg.jenkins.io/debian-stable binary/
vskumar@ubuntu:~$ sudo apt-get update
Hit:1 https://download.docker.com/linux/ubuntu xenial InRelease
Ign:2 https://pkg.jenkins.io/debian-stable binary/ InRelease
Hit:3 https://pkg.jenkins.io/debian-stable binary/ Release
Reading package lists… Done
vskumar@ubuntu:~$
========================>

========>
vskumar@ubuntu:~$ sudo find . / jenkins | grep ‘jenkins’
find: ‘/run/user/1000/gvfs’: Permission denied
/var/lib/apt/lists/pkg.jenkins.io_debian-stable_binary_Packages
/var/lib/apt/lists/pkg.jenkins.io_debian-stable_binary_Release.gpg
/var/lib/apt/lists/pkg.jenkins.io_debian-stable_binary_Release
find: ‘jenkins’: No such file or directory
vskumar@ubuntu:~$
==============>

Step4:
Include JAVA_HOME = /usr/local/java/jdk1.8.0_161
in .shrc file.

Now, we will install Jenkins and its dependencies:

$sudo apt-get install jenkins
Whenyou run this command your might get the below error:
=== Dependecy issues ======>
vskumar@ubuntu:~$ sudo apt-get install jenkins
Reading package lists… Done
Building dependency tree
Reading state information… Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
jenkins : Depends: daemon but it is not installable
Depends: default-jre-headless (>= 2:1.8) or
java8-runtime-headless
E: Unable to correct problems, you have held broken packages.
vskumar@ubuntu:~$
======================>

To resolve this issued, Under Ubuntu Software tab, enable all the repositories.
The system updates all the packages/libs.

Visit for details:
https://askubuntu.com/questions/140246/how-do-i-resolve-unmet-dependencies-after-adding-a-ppa

After doing the repositories updates as mentioned above, I have re-executed the install command:

==== Screen Output of Jenkins installation ====
vskumar@ubuntu:~$ sudo apt-get install jenkins
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following additional packages will be installed:
ca-certificates-java daemon default-jre-headless java-common
openjdk-8-jre-headless
Suggested packages:
default-jre openjdk-8-jre-jamvm fonts-dejavu-extra fonts-ipafont-gothic
fonts-ipafont-mincho ttf-wqy-microhei | ttf-wqy-zenhei fonts-indic
The following NEW packages will be installed:
ca-certificates-java daemon default-jre-headless java-common jenkins
openjdk-8-jre-headless
0 upgraded, 6 newly installed, 0 to remove and 0 not upgraded.
Need to get 101 MB of archives.
After this operation, 174 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://archive.ubuntu.com/ubuntu xenial/main amd64 java-common all 0.56ubuntu2 [7,742 B]
Get:2 http://archive.ubuntu.com/ubuntu xenial/main amd64 default-jre-headless amd64 2:1.8-56ubuntu2 [4,380 B]
Get:3 http://archive.ubuntu.com/ubuntu xenial/main amd64 ca-certificates-java all 20160321 [12.9 kB]
Get:4 http://archive.ubuntu.com/ubuntu xenial/main amd64 openjdk-8-jre-headless amd64 8u77-b03-3ubuntu3 [26.9 MB]
Get:5 https://pkg.jenkins.io/debian-stable binary/ jenkins 2.89.4 [73.7 MB]
Get:6 http://archive.ubuntu.com/ubuntu xenial/universe amd64 daemon amd64 0.6.4-1 [98.2 kB]
Fetched 101 MB in 2min 9s (775 kB/s)
Selecting previously unselected package java-common.
(Reading database … 217445 files and directories currently installed.)
Preparing to unpack …/java-common_0.56ubuntu2_all.deb …
Unpacking java-common (0.56ubuntu2) …
Selecting previously unselected package default-jre-headless.
Preparing to unpack …/default-jre-headless_2%3a1.8-56ubuntu2_amd64.deb …
Unpacking default-jre-headless (2:1.8-56ubuntu2) …
Selecting previously unselected package ca-certificates-java.
Preparing to unpack …/ca-certificates-java_20160321_all.deb …
Unpacking ca-certificates-java (20160321) …
Selecting previously unselected package openjdk-8-jre-headless:amd64.
Preparing to unpack …/openjdk-8-jre-headless_8u77-b03-3ubuntu3_amd64.deb …
Unpacking openjdk-8-jre-headless:amd64 (8u77-b03-3ubuntu3) …
Selecting previously unselected package daemon.
Preparing to unpack …/daemon_0.6.4-1_amd64.deb …
Unpacking daemon (0.6.4-1) …
Selecting previously unselected package jenkins.
Preparing to unpack …/jenkins_2.89.4_all.deb …
Unpacking jenkins (2.89.4) …
Processing triggers for man-db (2.7.5-1) …
Processing triggers for ca-certificates (20170717~16.04.1) …
Updating certificates in /etc/ssl/certs…
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d…
done.
Processing triggers for systemd (229-4ubuntu21.1) …
Processing triggers for ureadahead (0.100.0-19) …
Setting up java-common (0.56ubuntu2) …
Setting up daemon (0.6.4-1) …
Setting up openjdk-8-jre-headless:amd64 (8u77-b03-3ubuntu3) …
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/rmid to provide /usr/bin/rmid (rmid) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java to provide /usr/bin/java (java) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/keytool to provide /usr/bin/keytool (keytool) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/jjs to provide /usr/bin/jjs (jjs) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/pack200 to provide /usr/bin/pack200 (pack200) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/rmiregistry to provide /usr/bin/rmiregistry (rmiregistry) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/unpack200 to provide /usr/bin/unpack200 (unpack200) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/orbd to provide /usr/bin/orbd (orbd) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/servertool to provide /usr/bin/servertool (servertool) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/tnameserv to provide /usr/bin/tnameserv (tnameserv) in auto mode
update-alternatives: using /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/jexec to provide /usr/bin/jexec (jexec) in auto mode
Setting up ca-certificates-java (20160321) …
Adding debian:Chambers_of_Commerce_Root_-_2008.pem
Adding debian:GeoTrust_Primary_Certification_Authority_-_G3.pem
Adding debian:OISTE_WISeKey_Global_Root_GA_CA.pem
Adding debian:Deutsche_Telekom_Root_CA_2.pem
Adding debian:Izenpe.com.pem
Adding debian:Microsec_e-Szigno_Root_CA_2009.pem
Adding debian:EC-ACC.pem
Adding debian:DigiCert_Global_Root_G2.pem
Adding debian:QuoVadis_Root_CA_3.pem
Adding debian:ePKI_Root_Certification_Authority.pem
Adding debian:GeoTrust_Primary_Certification_Authority_-_G2.pem
Adding debian:Autoridad_de_Certificacion_Firmaprofesional_CIF_A62634068.pem
Adding debian:ACCVRAIZ1.pem
Adding debian:Cybertrust_Global_Root.pem
Adding debian:COMODO_ECC_Certification_Authority.pem
Adding debian:GeoTrust_Universal_CA_2.pem
Adding debian:Entrust_Root_Certification_Authority_-_EC1.pem
Adding debian:Sonera_Class_2_Root_CA.pem
Adding debian:Comodo_AAA_Services_root.pem
Adding debian:Security_Communication_EV_RootCA1.pem
Adding debian:AddTrust_Low-Value_Services_Root.pem
Adding debian:Amazon_Root_CA_1.pem
Adding debian:DST_Root_CA_X3.pem
Adding debian:OpenTrust_Root_CA_G1.pem
Adding debian:T-TeleSec_GlobalRoot_Class_3.pem
Adding debian:Camerfirma_Chambers_of_Commerce_Root.pem
Adding debian:Atos_TrustedRoot_2011.pem
Adding debian:Starfield_Class_2_CA.pem
Adding debian:Certigna.pem
Adding debian:Buypass_Class_3_Root_CA.pem
Adding debian:COMODO_Certification_Authority.pem
Adding debian:thawte_Primary_Root_CA_-_G3.pem
Adding debian:Swisscom_Root_EV_CA_2.pem
Adding debian:Go_Daddy_Class_2_CA.pem
Adding debian:VeriSign_Universal_Root_Certification_Authority.pem
Adding debian:Global_Chambersign_Root_-_2008.pem
Adding debian:CNNIC_ROOT.pem
Adding debian:AddTrust_External_Root.pem
Adding debian:SwissSign_Gold_CA_-_G2.pem
Adding debian:QuoVadis_Root_CA_1_G3.pem
Adding debian:GeoTrust_Primary_Certification_Authority.pem
Adding debian:Hongkong_Post_Root_CA_1.pem
Adding debian:TWCA_Global_Root_CA.pem
Adding debian:ACEDICOM_Root.pem
Adding debian:Go_Daddy_Root_Certificate_Authority_-_G2.pem
Adding debian:Staat_der_Nederlanden_EV_Root_CA.pem
Adding debian:GlobalSign_ECC_Root_CA_-_R4.pem
Adding debian:Entrust_Root_Certification_Authority_-_G2.pem
Adding debian:Taiwan_GRCA.pem
Adding debian:Verisign_Class_3_Public_Primary_Certification_Authority_-_G3.pem
Adding debian:COMODO_RSA_Certification_Authority.pem
Adding debian:ssl-cert-snakeoil.pem
Adding debian:DigiCert_High_Assurance_EV_Root_CA.pem
Adding debian:GeoTrust_Global_CA.pem
Adding debian:Security_Communication_RootCA2.pem
Adding debian:QuoVadis_Root_CA.pem
Adding debian:D-TRUST_Root_Class_3_CA_2_2009.pem
Adding debian:D-TRUST_Root_Class_3_CA_2_EV_2009.pem
Adding debian:UTN_USERFirst_Hardware_Root_CA.pem
Adding debian:DST_ACES_CA_X6.pem
Adding debian:Visa_eCommerce_Root.pem
Adding debian:Certinomis_-_Autorité_Racine.pem
Adding debian:thawte_Primary_Root_CA_-_G2.pem
Adding debian:Staat_der_Nederlanden_Root_CA_-_G2.pem
Adding debian:E-Tugra_Certification_Authority.pem
Adding debian:QuoVadis_Root_CA_2_G3.pem
Adding debian:Entrust.net_Premium_2048_Secure_Server_CA.pem
Adding debian:TURKTRUST_Certificate_Services_Provider_Root_2007.pem
Adding debian:SwissSign_Silver_CA_-_G2.pem
Adding debian:TWCA_Root_Certification_Authority.pem
Adding debian:Certum_Trusted_Network_CA_2.pem
Adding debian:T-TeleSec_GlobalRoot_Class_2.pem
Adding debian:GlobalSign_Root_CA_-_R2.pem
Adding debian:LuxTrust_Global_Root_2.pem
Adding debian:AddTrust_Public_Services_Root.pem
Adding debian:Staat_der_Nederlanden_Root_CA_-_G3.pem
Adding debian:USERTrust_ECC_Certification_Authority.pem
Adding debian:AffirmTrust_Networking.pem
Adding debian:Amazon_Root_CA_4.pem
Adding debian:Starfield_Services_Root_Certificate_Authority_-_G2.pem
Adding debian:TÜRKTRUST_Elektronik_Sertifika_Hizmet_Saglayicisi_H5.pem
Adding debian:ISRG_Root_X1.pem
Adding debian:AC_RAIZ_FNMT-RCM.pem
Adding debian:Swisscom_Root_CA_2.pem
Adding debian:DigiCert_Trusted_Root_G4.pem
Adding debian:GlobalSign_Root_CA.pem
Adding debian:CA_Disig_Root_R2.pem
Adding debian:OISTE_WISeKey_Global_Root_GB_CA.pem
Adding debian:TeliaSonera_Root_CA_v1.pem
Adding debian:Comodo_Trusted_Services_root.pem
Adding debian:Certum_Trusted_Network_CA.pem
Adding debian:NetLock_Arany_=Class_Gold=_Fotanúsítvány.pem
Adding debian:AffirmTrust_Premium.pem
Adding debian:AffirmTrust_Premium_ECC.pem
Adding debian:VeriSign_Class_3_Public_Primary_Certification_Authority_-_G5.pem
Adding debian:Secure_Global_CA.pem
Adding debian:Certinomis_-_Root_CA.pem
Adding debian:AddTrust_Qualified_Certificates_Root.pem
Adding debian:Certplus_Root_CA_G2.pem
Adding debian:Amazon_Root_CA_2.pem
Adding debian:Security_Communication_Root_CA.pem
Adding debian:GeoTrust_Global_CA_2.pem
Adding debian:DigiCert_Global_Root_CA.pem
Adding debian:Starfield_Root_Certificate_Authority_-_G2.pem
Adding debian:IdenTrust_Public_Sector_Root_CA_1.pem
Adding debian:VeriSign_Class_3_Public_Primary_Certification_Authority_-_G4.pem
Adding debian:SZAFIR_ROOT_CA2.pem
Adding debian:PSCProcert.pem
Adding debian:AffirmTrust_Commercial.pem
Adding debian:certSIGN_ROOT_CA.pem
Adding debian:Swisscom_Root_CA_1.pem
Adding debian:Hellenic_Academic_and_Research_Institutions_ECC_RootCA_2015.pem
Adding debian:Certplus_Class_2_Primary_CA.pem
Adding debian:XRamp_Global_CA_Root.pem
Adding debian:GeoTrust_Universal_CA.pem
Adding debian:QuoVadis_Root_CA_3_G3.pem
Adding debian:QuoVadis_Root_CA_2.pem
Adding debian:China_Internet_Network_Information_Center_EV_Certificates_Root.pem
Adding debian:CFCA_EV_ROOT.pem
Adding debian:OpenTrust_Root_CA_G2.pem
Adding debian:Network_Solutions_Certificate_Authority.pem
Adding debian:Amazon_Root_CA_3.pem
Adding debian:Certum_Root_CA.pem
Adding debian:EE_Certification_Centre_Root_CA.pem
Adding debian:Actalis_Authentication_Root_CA.pem
Adding debian:Hellenic_Academic_and_Research_Institutions_RootCA_2015.pem
Adding debian:DigiCert_Assured_ID_Root_G3.pem
Adding debian:SecureTrust_CA.pem
Adding debian:Entrust_Root_Certification_Authority.pem
Adding debian:DigiCert_Assured_ID_Root_G2.pem
Adding debian:Certplus_Root_CA_G1.pem
Adding debian:TUBITAK_Kamu_SM_SSL_Kok_Sertifikasi_-_Surum_1.pem
Adding debian:TÜBITAK_UEKAE_Kök_Sertifika_Hizmet_Saglayicisi_-_Sürüm_3.pem
Adding debian:GlobalSign_Root_CA_-_R3.pem
Adding debian:IdenTrust_Commercial_Root_CA_1.pem
Adding debian:OpenTrust_Root_CA_G3.pem
Adding debian:thawte_Primary_Root_CA.pem
Adding debian:USERTrust_RSA_Certification_Authority.pem
Adding debian:DigiCert_Assured_ID_Root_CA.pem
Adding debian:Buypass_Class_2_Root_CA.pem
Adding debian:CA_Disig_Root_R1.pem
Adding debian:Trustis_FPS_Root_CA.pem
Adding debian:Baltimore_CyberTrust_Root.pem
Adding debian:GlobalSign_ECC_Root_CA_-_R5.pem
Adding debian:Comodo_Secure_Services_root.pem
Adding debian:DigiCert_Global_Root_G3.pem
Adding debian:Hellenic_Academic_and_Research_Institutions_RootCA_2011.pem
Adding debian:Camerfirma_Global_Chambersign_Root.pem
Adding debian:SecureSign_RootCA11.pem
done.
Setting up default-jre-headless (2:1.8-56ubuntu2) …
Setting up jenkins (2.89.4) …
Processing triggers for ca-certificates (20170717~16.04.1) …
Updating certificates in /etc/ssl/certs…
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d…

done.
done.
Processing triggers for systemd (229-4ubuntu21.1) …
Processing triggers for ureadahead (0.100.0-19) …
vskumar@ubuntu:~$
== End of Jenkins intallation ========>

==== Updates ====>

vskumar@ubuntu:~$
vskumar@ubuntu:~$ sudo apt-get update
Hit:1 http://ppa.launchpad.net/webupd8team/java/ubuntu xenial InRelease
Hit:2 http://archive.ubuntu.com/ubuntu xenial InRelease
Hit:3 https://download.docker.com/linux/ubuntu xenial InRelease
Ign:4 https://pkg.jenkins.io/debian-stable binary/ InRelease
Hit:5 https://pkg.jenkins.io/debian-stable binary/ Release
Reading package lists… Done
vskumar@ubuntu:~$
=============>

Step5:

How to install apache2?:
If we need to use jenkins apache2 is required.
Now let us install apache2

=== Output for apache installation ===>
vskumar@ubuntu:~$
vskumar@ubuntu:~$ sudo apt install apache2
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following additional packages will be installed:
apache2-bin apache2-data apache2-utils libapr1 libaprutil1
libaprutil1-dbd-sqlite3 libaprutil1-ldap liblua5.1-0
Suggested packages:
apache2-doc apache2-suexec-pristine | apache2-suexec-custom
The following NEW packages will be installed:
apache2 apache2-bin apache2-data apache2-utils libapr1 libaprutil1
libaprutil1-dbd-sqlite3 libaprutil1-ldap liblua5.1-0
0 upgraded, 9 newly installed, 0 to remove and 0 not upgraded.
Need to get 1,532 kB of archives.
After this operation, 6,350 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://archive.ubuntu.com/ubuntu xenial/main amd64 libapr1 amd64 1.5.2-3 [86.0 kB]
Get:2 http://archive.ubuntu.com/ubuntu xenial/main amd64 libaprutil1 amd64 1.5.4-1build1 [77.1 kB]
Get:3 http://archive.ubuntu.com/ubuntu xenial/main amd64 libaprutil1-dbd-sqlite3 amd64 1.5.4-1build1 [10.6 kB]
Get:4 http://archive.ubuntu.com/ubuntu xenial/main amd64 libaprutil1-ldap amd64 1.5.4-1build1 [8,720 B]
Get:5 http://archive.ubuntu.com/ubuntu xenial/main amd64 liblua5.1-0 amd64 5.1.5-8ubuntu1 [102 kB]
Get:6 http://archive.ubuntu.com/ubuntu xenial/main amd64 apache2-bin amd64 2.4.18-2ubuntu3 [918 kB]
Get:7 http://archive.ubuntu.com/ubuntu xenial/main amd64 apache2-utils amd64 2.4.18-2ubuntu3 [81.1 kB]
Get:8 http://archive.ubuntu.com/ubuntu xenial/main amd64 apache2-data all 2.4.18-2ubuntu3 [162 kB]
Get:9 http://archive.ubuntu.com/ubuntu xenial/main amd64 apache2 amd64 2.4.18-2ubuntu3 [86.6 kB]
Fetched 1,532 kB in 5s (270 kB/s)
Selecting previously unselected package libapr1:amd64.
(Reading database … 217703 files and directories currently installed.)
Preparing to unpack …/libapr1_1.5.2-3_amd64.deb …
Unpacking libapr1:amd64 (1.5.2-3) …
Selecting previously unselected package libaprutil1:amd64.
Preparing to unpack …/libaprutil1_1.5.4-1build1_amd64.deb …
Unpacking libaprutil1:amd64 (1.5.4-1build1) …
Selecting previously unselected package libaprutil1-dbd-sqlite3:amd64.
Preparing to unpack …/libaprutil1-dbd-sqlite3_1.5.4-1build1_amd64.deb …
Unpacking libaprutil1-dbd-sqlite3:amd64 (1.5.4-1build1) …
Selecting previously unselected package libaprutil1-ldap:amd64.
Preparing to unpack …/libaprutil1-ldap_1.5.4-1build1_amd64.deb …
Unpacking libaprutil1-ldap:amd64 (1.5.4-1build1) …
Selecting previously unselected package liblua5.1-0:amd64.
Preparing to unpack …/liblua5.1-0_5.1.5-8ubuntu1_amd64.deb …
Unpacking liblua5.1-0:amd64 (5.1.5-8ubuntu1) …
Selecting previously unselected package apache2-bin.
Preparing to unpack …/apache2-bin_2.4.18-2ubuntu3_amd64.deb …
Unpacking apache2-bin (2.4.18-2ubuntu3) …
Selecting previously unselected package apache2-utils.
Preparing to unpack …/apache2-utils_2.4.18-2ubuntu3_amd64.deb …
Unpacking apache2-utils (2.4.18-2ubuntu3) …
Selecting previously unselected package apache2-data.
Preparing to unpack …/apache2-data_2.4.18-2ubuntu3_all.deb …
Unpacking apache2-data (2.4.18-2ubuntu3) …
Selecting previously unselected package apache2.
Preparing to unpack …/apache2_2.4.18-2ubuntu3_amd64.deb …
Unpacking apache2 (2.4.18-2ubuntu3) …
Processing triggers for libc-bin (2.23-0ubuntu10) …
Processing triggers for man-db (2.7.5-1) …
Processing triggers for systemd (229-4ubuntu21.1) …
Processing triggers for ureadahead (0.100.0-19) …
Processing triggers for ufw (0.35-0ubuntu2) …
Setting up libapr1:amd64 (1.5.2-3) …
Setting up libaprutil1:amd64 (1.5.4-1build1) …
Setting up libaprutil1-dbd-sqlite3:amd64 (1.5.4-1build1) …
Setting up libaprutil1-ldap:amd64 (1.5.4-1build1) …
Setting up liblua5.1-0:amd64 (5.1.5-8ubuntu1) …
Setting up apache2-bin (2.4.18-2ubuntu3) …
Setting up apache2-utils (2.4.18-2ubuntu3) …
Setting up apache2-data (2.4.18-2ubuntu3) …
Setting up apache2 (2.4.18-2ubuntu3) …
Enabling module mpm_event.
Enabling module authz_core.
Enabling module authz_host.
Enabling module authn_core.
Enabling module auth_basic.
Enabling module access_compat.
Enabling module authn_file.
Enabling module authz_user.
Enabling module alias.
Enabling module dir.
Enabling module autoindex.
Enabling module env.
Enabling module mime.
Enabling module negotiation.
Enabling module setenvif.
Enabling module filter.
Enabling module deflate.
Enabling module status.
Enabling conf charset.
Enabling conf localized-error-pages.
Enabling conf other-vhosts-access-log.
Enabling conf security.
Enabling conf serve-cgi-bin.
Enabling site 000-default.
Processing triggers for libc-bin (2.23-0ubuntu10) …
Processing triggers for systemd (229-4ubuntu21.1) …
Processing triggers for ureadahead (0.100.0-19) …
Processing triggers for ufw (0.35-0ubuntu2) …
vskumar@ubuntu:~$
=== Apaches is installed ===>

Let us check its status:

== Status of apache2 ===>
vskumar@ubuntu:~$
vskumar@ubuntu:~$ service status apache2
status: unrecognized service
vskumar@ubuntu:~$ service apache2 status
? apache2.service – LSB: Apache2 web server
Loaded: loaded (/etc/init.d/apache2; bad; vendor preset: enabled)
Drop-In: /lib/systemd/system/apache2.service.d
+-apache2-systemd.conf
Active: active (running) since Thu 2018-02-22 02:30:24 PST; 1min 6s ago
Docs: man:systemd-sysv-generator(8)
CGroup: /system.slice/apache2.service
+-12680 /usr/sbin/apache2 -k start
+-12683 /usr/sbin/apache2 -k start
+-12684 /usr/sbin/apache2 -k start

Feb 22 02:30:22 ubuntu systemd[1]: Starting LSB: Apache2 web server…
Feb 22 02:30:22 ubuntu apache2[12651]: * Starting Apache httpd web server apach
Feb 22 02:30:23 ubuntu apache2[12651]: AH00558: apache2: Could not reliably dete
Feb 22 02:30:24 ubuntu apache2[12651]: *
Feb 22 02:30:24 ubuntu systemd[1]: Started LSB: Apache2 web server.
lines 1-16/16 (END)
================>

Now, let us check the status for Jenkins:

===== Jenkins status ===>

vskumar@ubuntu:~$ service jenkins status
? jenkins.service – LSB: Start Jenkins at boot time
Loaded: loaded (/etc/init.d/jenkins; bad; vendor preset: enabled)
Active: active (exited) since Thu 2018-02-22 02:13:57 PST; 23min ago
Docs: man:systemd-sysv-generator(8)

Feb 22 02:13:51 ubuntu systemd[1]: Starting LSB: Start Jenkins at boot time…
Feb 22 02:13:51 ubuntu jenkins[10140]: * Starting Jenkins Automation Server jen
Feb 22 02:13:52 ubuntu su[10168]: Successful su for jenkins by root
Feb 22 02:13:52 ubuntu su[10168]: + ??? root:jenkins
Feb 22 02:13:52 ubuntu su[10168]: pam_unix(su:session): session opened for user
Feb 22 02:13:57 ubuntu jenkins[10140]: …done.
Feb 22 02:13:57 ubuntu systemd[1]: Started LSB: Start Jenkins at boot time.
lines 1-12/12 (END)
==== Jenkins is running ======>

How to check on browser in Ubuntu for Jenkins web page ?:

You can also check the ubuntu browser with the below
url:http://localhost:8080/login?from=%2F
There should be a web page displayed with the message:
“Unlock Jenkins”.

It means Jenkins is available to use.

Step6:
Now, we need to setup the admin password.
Read the content on the web page.
You are advised to use the initial password from:
/var/lib/jenkins/secrets/initialAdminPassword

Let us go to that directory to get copy and paste it on
web page.

In my case I got the below:
==== PWD display ===>
vskumar@ubuntu:~$ sudo cat /var/lib/jenkins/secrets/initialAdminPassword
711a4d7d01244651a490cfd4a61439e2
vskumar@ubuntu:~$
========>

I have pasted it on web page.
Till you change the pwd, this will be the default one.

==== List of the files in jenkins dir ===>
vskumar@ubuntu:/var/lib/jenkins$ ls -l
total 60
-rw-r–r– 1 jenkins jenkins 1820 Feb 22 02:17 config.xml
-rw-r–r– 1 jenkins jenkins 156 Feb 22 02:15 hudson.model.UpdateCenter.xml
-rw——- 1 jenkins jenkins 1712 Feb 22 02:15 identity.key.enc
-rw-r–r– 1 jenkins jenkins 94 Feb 22 02:16 jenkins.CLI.xml
-rw-r–r– 1 jenkins jenkins 6 Feb 22 02:16 jenkins.install.UpgradeWizard.state
drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 02:15 jobs
drwxr-xr-x 3 jenkins jenkins 4096 Feb 22 02:16 logs
-rw-r–r– 1 jenkins jenkins 907 Feb 22 02:16 nodeMonitors.xml
drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 02:15 nodes
drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 02:15 plugins
-rw-r–r– 1 jenkins jenkins 64 Feb 22 02:15 secret.key
-rw-r–r– 1 jenkins jenkins 0 Feb 22 02:15 secret.key.not-so-secret
drwx—— 4 jenkins jenkins 4096 Feb 22 02:16 secrets
drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 02:18 updates
drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 02:16 userContent
drwxr-xr-x 3 jenkins jenkins 4096 Feb 22 02:16 users
vskumar@ubuntu:/var/lib/jenkins$ cd jobs
vskumar@ubuntu:/var/lib/jenkins/jobs$ ls
vskumar@ubuntu:/var/lib/jenkins/jobs$ pwd
/var/lib/jenkins/jobs
vskumar@ubuntu:/var/lib/jenkins/jobs$
==================>
We need to remember the above directories.

By default we can install ‘suggested plugins’ for now.
It shows the plugins updates.
Once they are installed, you will be prompted for a uid/pwd/name/e-mail.
You can fill them, and start using jenkins.

That is all the installation of Jenkins 2.9.

This video is made to motivate the new DevOps engineers to learn and do a kind of trouble shooting, while doing Jenkins installation on a Virtual machine of Ubuntu.

To try one job build you can go through my another blog:

https://vskumar.blog/2017/11/26/2-devops-jenkins2-9-how-to-create-and-build-the-job/

Good luck!! and you can start practicing Jenkins. 

Please leave your feedback!!

Vcard-Shanthi Kumar V-v3