Bash
ShellShock - 無法更新 CentOS 5.7
[user@server1 ~]$ wget http://mirror.centos.org/centos-5/5/updates/x86_64/RPMS/bash-3.2-33.el5.1.x86_64.rpm [user@server1 ~]$ sudo rpm -Uvh bash-3.2-33.el5.1.x86_64.rpm warning: bash-3.2-33.el5.1.x86_64.rpm: Header V3 DSA signature: NOKEY, key ID e8562897 Preparing... ########################################### [100%] package bash-3.2-33.el5.1.x86_64 is installed [user@server1 ~]$ exit [user@server1 ~]$ rpm -q bash bash-3.2-32.el5 bash-3.2-33.el5.1 [user@server1 ~]$ bash --version GNU bash, version 3.2.25(1)-release (x86_64-redhat-linux-gnu) Copyright (C) 2005 Free Software Foundation, Inc. [user@server1 ~]$ foo='() { echo not patched; }' bash -c foo not patched [user@server1 ~]$
請幫忙….
用於
yum
更新您的系統。yum update bash
如果它告訴您“沒有標記為更新的軟體包”,請嘗試重建 yum 記憶體然後更新:
yum clean all yum makecache fast yum update bash
如果這仍然不起作用,則可能是您使用的鏡子有問題。嘗試將您的 yum 配置直接指向 ‘/etc/yum.repos.d/CentOS-Base.repo’ 文件中的 “mirror.centos.org”:
sudo sed -i -e 's/^mirrorlist=/#mirrorlist=/' -e 's/^#baseurl=/baseurl=/' /etc/yum.repos.d/CentOS-Base.repo
注意:我提供這個
sed
命令是假設你的 ‘CentOS-Base.repo’ 文件有 “baseurl” 被註釋掉並且它指向 “mirror.centos.org”。然後執行
yum clean all
,yum makecache fast
, 並yum update bash
再次執行。