How Do You Install an Older Version of Jenkins (e.g., 1.x) on Ubuntu Linux?

Problem scenario
Your enterprise’s policies are to install a version of Jenkins that is lower than the latest.  How do you install Jenkins 1.651.1 on Ubuntu 16.04?

Solution
1.  Install Java.  See this posting if you do not know how.
2.  Run these three commands to install Jenkins 1.651.1 (but you can chance the version whichever one is available):

curl -L https://pkg.jenkins.io/debian-stable/binary/jenkins_1.651.1_all.deb /tmp/jenkins_1.651.1_all.deb
sudo apt-get -y install daemon
sudo dpkg -i /tmp/jenkins_1.651.1_all.deb

How Do You Install Maven, openjdk, libssl-dev, build-essential, and pkgconf on a RedHat 7.X or CentOS 6.X Linux Server?

Problem scenario
You are using a RedHat derivative distribution of Linux (e.g., CentOS/RHEL/Fedora).  To eliminate a Hadoop error, you need to install a variety of packages.  How do you install Maven, openjdk, libssl-Dev, build-Essential, and pkgconf?

Solution
To install Maven, see this article.

For the rest of the packages, run these commands:

sudo yum -y install java-1.8.0-openjdk-devel openssl-devel cmake protobuf

sudo yum -y groupinstall ‘Development Tools’

curl ftp://rpmfind.net/linux/fedora/linux/updates/25/x86_64/p/pkgconf-1.3.7-1.fc25.x86_64.rpm pkgconf-1.3.7-1.fc25.x86_64.rpm

curl ftp://rpmfind.net/linux/fedora/linux/updates/25/x86_64/l/libpkgconf-1.3.7-1.fc25.x86_64.rpm libpkgconf-1.3.7-1.fc25.x86_64.rpm

sudo rpm -ivh *.rpm …

How Do You Troubleshoot a Chef Client That Has the Results of “knife client list” as “404 not found”?

Problem scenario
You set up Chef server and Chef client on Linux servers.  On the Chef client server you run this command:

knife client list

You get this as the output:

ERROR: The object you are looking for could not be found
Response: <!DOCTYPE html>
<html xmlns=”http://www.w3.org/1999/xhtml”>
<head>
  <meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″ />
  <meta http-equiv=”X-UA-Compatible” content=”IE=EmulateIE7″ />

How Do You Create a Certificate Signing Request (CSR) File and Set up an HTTPS Server for Basic Testing?

Problem scenarios
This is a two-in-one posting.  The same solution works for two different problem scenarios.

Problem scenario A
You want to create a certificate signing request permissions file (a csr.pem) to learn more about it.  You also want to try to use HTTPS as a test.  How do you do these things?

Problem scenario B
You want to implement a solution with TLS. 

To Use Chef’s Basic Features, How Do You Register a Chef Client with Your Chef Server?

Problem scenario
You have installed Chef server on a RedHat Enterprise Linux (RHEL) server in AWS.  You have installed Chef client on another RHEL instance in  AWS.  You simply want your Chef client to receive configuration management changes (e.g., you want Chef recipes to work).  The command “chef node list” on your Chef client server returns no servers.  You ran this command from the Chef client:

sudo chef-client -S https://<FQDN of Chef server>/organization/contint

But you received an error like this:

Chef encountered an error attempting to create the client “<FQDN of Chef Client computer>”
================================================================================

System Info:
————
chef_version=13.4.19
ruby=ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux]
program_name=chef-client worker: ppid=5156;start=14:10:31;

How Do You Find What Resource Groups You Have with Azure PowerShell?

Problem scenario
You want to find the resource groups in your Azure account.  Either you have already installed Azure PowerShell on Windows 7 or on Windows 10 you have installed the Azure modules.  You have connected to an Azure account (e.g., with this command Login-AzureRMAccount). What is the PowerShell command to list the resource groups in the Azure account?

Solution
Run this command:
Find-AzureRmResourceGroup

# It will work with the Azure Cloud Shell too.

How Do You Write a Python Program That Can Run Linux Bash Commands?

Problem scenario
You want to use Python to run Linux commands.  You have been told to not use the “import os” for this task.  You want to manipulate the text and output of Bash commands for sophisticated processing and automation with Python.  How can a Python program run Bash commands?

Solution
Use “from subprocess import check_output” as the first line.  Then encapsulate the Bash command inside double quotes,

How Do You Troubleshoot the Problem “ImportError: Entry Point (‘console_scripts’, ‘Parquet’) Not Found”?

Problem scenario
You are trying to run Apache Parquet commands.  But each command gives this error:

Traceback (most recent call last):
  File “/usr/local/bin/parquet”, line 11, in <module>
    load_entry_point(‘parquet==1.2’, ‘console_scripts’, ‘parquet’)()
  File “/home/ubuntu/.local/lib/python2.7/site-packages/pkg_resources/__init__.py”, line 570, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File “/home/ubuntu/.local/lib/python2.7/site-packages/pkg_resources/__init__.py”, line 2750, in load_entry_point
    raise ImportError(“Entry point %r not found” % ((group, name),))
ImportError: Entry point (‘console_scripts’,