报错代码:
GnuTLS: No or insufficient priorities were set.
Unable to establish SSL connection.
分析:
如果客户端和服务端的 TLS 版本不匹配,就会出现此类报错
解决方法:
# wget --secure-protocol=TLSv1 <URL>
GnuTLS: No or insufficient priorities were set.
Unable to establish SSL connection.
如果客户端和服务端的 TLS 版本不匹配,就会出现此类报错
# wget --secure-protocol=TLSv1 <URL>
在启用或禁用 SLES 的软件库前,要先注册此 SLES
# SUSEConnect --list-extensions
# SUSEConnect -p sle-module-live-patching/15.3/x86_64
(补充:这里以启用 sle-module-live-patching/15.3/x86_64 软件库为例)
# SUSEConnect -d -p sle-module-basesystem/15.3/x86_64
(补充:这里以禁用用 sle-module-live-patching/15.3/x86_64 软件库为例)
# SUSEConnect -r <ActivationCode> -e <EmailAddress>
(补充:这里的 <ActivationCode> 和 <EmailAddress> 是在注册了 SUSE 账号并购买了对应的的订阅以后获得)
# SUSEConnect –de-register
或者:
# SUSEConnect -d
# SUSEConnect --cleanup
# rm -f /etc/SUSEConnect
# rm -rf /etc/zypp/credentials.d/*
# rm -rf /etc/zypp/repos.d/*
# rm -f /etc/zypp/services.d/*
https://www.suse.com/support/kb/doc/?id=000018564
# cat /etc/*release*
NAME="openSUSE Leap"
VERSION="15.4"
ID="opensuse-leap"
ID_LIKE="suse opensuse"
VERSION_ID="15.4"
PRETTY_NAME="openSUSE Leap 15.4"
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:leap:15.4"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://www.opensuse.org/"
(注意:确保显示的系统版本是 openSUSE Leap 15.4)
# zypper ls -d
# | Alias | Name | Enabled | GPG Check | Refresh | Priority | Type | URI
---+---------------------------+------------------------------------+---------+-----------+---------+----------+--------+---------------------------------------------------------------------------------------------
1 | repo-non-oss | Non-OSS Repository | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/distribution/leap/15.4/repo/non-oss/
2 | repo-oss | Main Repository | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/distribution/leap/15.4/repo/oss/
3 | repo-update | Main Update Repository | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.4/oss/
4 | repo-update-non-oss | Update Repository (Non-Oss) | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.4/non-oss/
5 | repo-backports-update | Update repository of openSUSE Backports | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.4/backports/
6 | repo-sle-update | Update repository with updates from SUSE Linux Enterprise 15 | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.4/sle/
(
补充:
1) 确保以上软件库已处于 Enabled 状态
2) 手动启动这些软件库的命令如下
# zypper ar -fcg http://download.opensuse.org/distribution/leap/${releasever}/repo/non-oss/ Non-OSS Repository
# zypper ar -fcg http://download.opensuse.org/distribution/leap/${releasever}/repo/oss/ Main Repository
# zypper ar -fcg http://download.opensuse.org/update/leap/${releasever}/oss/ Main Update Repository
# zypper ar -fcg http://download.opensuse.org/update/leap/${releasever}/non-oss/ Update Repository (Non-Oss)
# zypper ar -fcg http://download.opensuse.org/update/leap/${releasever}/backports/ Update repository of openSUSE Backports
# zypper ar -fcg http://download.opensuse.org/update/leap/${releasever}/sle/ Update repository with updates from SUSE Linux Enterprise 15
3) 其中,Main Repository、Main Update Repository、Update repository of openSUSE Backports 和 Update repository with updates from SUSE Linux Enterprise 15 软件库是必须要有的,其他的软件库可以去掉
)
# zypper ref
(注意:确保刷新成功,否则请检查网络)
# zypper -n update
# sed -i 's/15.4/${releasever}/g' /etc/zypp/repos.d/*.repo
# zypper --releasever=15.5 refresh
# zypper --releasever=15.5 dup --download-in-advance
# zypper --releasever=15.5 dup
# reboot
# cat /etc/*release*
NAME="openSUSE Leap"
VERSION="15.5"
ID="opensuse-leap"
ID_LIKE="suse opensuse"
VERSION_ID="15.5"
PRETTY_NAME="openSUSE Leap 15.5"
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:leap:15.5"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://www.opensuse.org/"
# zypper ls -d
# | Alias | Name | Enabled | GPG Check | Refresh | Priority | Type | URI
---+---------------------------+------------------------------------+---------+-----------+---------+----------+--------+---------------------------------------------------------------------------------------------
1 | repo-non-oss | Non-OSS Repository | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/distribution/leap/15.5/repo/non-oss/
2 | repo-oss | Main Repository | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/distribution/leap/15.5/repo/oss/
3 | repo-update | Main Update Repository | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.5/oss/
4 | repo-update-non-oss | Update Repository (Non-Oss) | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.5/non-oss/
5 | repo-backports-update | Update repository of openSUSE Backports | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.5/backports/
6 | repo-sle-update | Update repository with updates from SUSE Linux Enterprise 15 | Yes | (r ) Yes | Yes | 99 | rpm-md | http://download.opensuse.org/update/leap/15.5/sle/
(补充:其中,Main Repository、Main Update Repository、Update repository of openSUSE Backports 和 Update repository with updates from SUSE Linux Enterprise 15 软件库是必须要有的,其他的软件库可以去掉)
supportconfig 是一个 SLES 系统搜集系统整体情况的命令,我们可以选择搜集哪些信息
# supportconfig -C
# sed -i 's\OPTION_AUDIT=1\OPTION_AUDIT=0\g' /etc/supportconfig.conf
(补充:这里使 supportconfig 命令不搜集 audit 日志为例)