From c053d40aa159c8866485962bf21b948815b0200b Mon Sep 17 00:00:00 2001 From: Francois B Date: Tue, 5 Jun 2018 10:11:13 +0200 Subject: [PATCH] microcode fct upd --- install_functions_ub1604.sh | 6 +++--- install_functions_ub1804.sh | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/install_functions_ub1604.sh b/install_functions_ub1604.sh index 77edb3e..728a4de 100644 --- a/install_functions_ub1604.sh +++ b/install_functions_ub1604.sh @@ -373,16 +373,16 @@ function installCardReaderMenu () { # function updateMicrocode () { msg "CPU Microcode updating" - oldMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1` + oldMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1 | awk -F': ' '{print $2}'` intel=`cat /proc/cpuinfo | grep -i Intel | wc -l` amd=`cat /proc/cpuinfo | grep -i Amd | wc -l` if [ "$intel" -gt "0" ]; then installPackage apt intel-microcode - newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1` + newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1 | awk -F': ' '{print $2}'` printf "[INFO] Microcode updated from "$oldMicrocode" version to "$newMicrocode" version" elif [ "$amd" -gt "0" ]; then installPackage apt amd64-microcode - newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1` + newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1 | awk -F': ' '{print $2}'` printf "[INFO] Microcode updated from "$oldMicrocode" version to "$newMicrocode" version" else printf "[INFO] No Intel/AMD CPU found" diff --git a/install_functions_ub1804.sh b/install_functions_ub1804.sh index 9ce53a0..642347c 100644 --- a/install_functions_ub1804.sh +++ b/install_functions_ub1804.sh @@ -397,16 +397,16 @@ function installCardReaderMenu () { # function updateMicrocode () { msg "CPU Microcode updating" - oldMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1` + oldMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1 | awk -F': ' '{print $2}'` intel=`cat /proc/cpuinfo | grep -i Intel | wc -l` amd=`cat /proc/cpuinfo | grep -i Amd | wc -l` if [ "$intel" -gt "0" ]; then installPackage apt intel-microcode - newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1` + newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1 | awk -F': ' '{print $2}'` printf "[INFO] Microcode updated from "$oldMicrocode" version to "$newMicrocode" version" elif [ "$amd" -gt "0" ]; then installPackage apt amd64-microcode - newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1` + newMicrocode=`cat /proc/cpuinfo | grep -i --color microcode -m 1 | awk -F': ' '{print $2}'` printf "[INFO] Microcode updated from "$oldMicrocode" version to "$newMicrocode" version" else printf "[INFO] No Intel/AMD CPU found"