trusty WA for dhcp client core-dump

Closes-Bug: PROD-21514 (PROD:21514)

Change-Id: I9426e348d7d1056632332090f7c372c74018d297
diff --git a/common/ubuntu_trusty_base.sh b/common/ubuntu_trusty_base.sh
index f7ae78c..b065455 100644
--- a/common/ubuntu_trusty_base.sh
+++ b/common/ubuntu_trusty_base.sh
@@ -5,7 +5,19 @@
   echo "INFO: ubuntu_base already finished.Skipping.."
   exit 0
 fi
-#
+
+function prod_21514_wa() {
+  echo 'Apply WA for https://mirantis.jira.com/browse/PROD-20751'
+  echo 'Installing isc-dhcp from xenial'
+  echo "deb [arch=amd64] ${UBUNTU_BASEURL} xenial main restricted universe" > /etc/apt/sources.list.d/xenial.list
+  echo "deb [arch=amd64] ${UBUNTU_BASEURL} xenial-updates main restricted universe" >> /etc/apt/sources.list.d/xenial.list
+  echo "deb [arch=amd64] ${UBUNTU_BASEURL} xenial-security main restricted universe" >> /etc/apt/sources.list.d/xenial.list
+  apt-get update
+  apt-get install -y isc-dhcp-client isc-dhcp-common
+  rm -v /etc/apt/sources.list.d/xenial.list || true
+}
+
+### Body
 UBUNTU_BASEURL="${UBUNTU_BASEURL:-mirror://mirrors.ubuntu.com/mirrors.txt}"
 ## Base packages and setup
 export DEBIAN_FRONTEND=noninteractive
@@ -31,8 +43,7 @@
 echo "deb [arch=amd64] ${UBUNTU_BASEURL} trusty main restricted universe" > /etc/apt/sources.list
 echo "deb [arch=amd64] ${UBUNTU_BASEURL} trusty-updates main restricted universe" >> /etc/apt/sources.list
 echo "deb [arch=amd64] ${UBUNTU_BASEURL} trusty-security main restricted universe" >> /etc/apt/sources.list
-echo "deb [arch=amd64] ${UBUNTU_BASEURL} trusty-backports main restricted universe" >> /etc/apt/sources.list
-
+prod_21514_wa
 apt-get clean
 apt-get update
 
@@ -42,7 +53,6 @@
 EXTRA_PKGS="${EXTRA_PKGS} byobu htop tmux tree vim-nox mc"
 # Common prerequisites
 EXTRA_PKGS="${EXTRA_PKGS} apt-transport-https libmnl0 python-apt python-m2crypto python-psutil acpid"
-apt-get -y install ${EXTRA_PKGS}
 
 # Cleanup old kernels, ensure latest is installed via virtual package
 if [ ! -f /tmp/no_install_kernel ]; then
@@ -55,12 +65,9 @@
     sed -i 's|GRUB_CMDLINE_LINUX=.*|GRUB_CMDLINE_LINUX="console=tty0 console=ttyS0,115200n8"|g' /etc/default/grub
     update-grub
 fi
-
 apt-get -y upgrade
 apt-get -y dist-upgrade
 
-apt-get autoremove --purge
-
 # Tmux fixes
 cat << 'EOF' >> /etc/tmux.conf
 set -g default-terminal "screen-256color"