这篇文章将为大家详细讲解有关天环境下Openssh-7.9p1升级以及系统调优,文章内容质量较高,因此小编分享给大家做个参考,希望大家阅读完这篇文章后对相关知识有一定的了解。
Openssh-7.9p1-Openssl1.0.2q-zlib-1.2.11升级+系统调优
Last login: Tue Nov 27 00:55:36 2018[root@localhost ~]#[root@localhost ~]# mkdir -p /soft[root@localhost ~]#[root@localhost ~]#[root@localhost ~]# cat /etc/redhat-releaseCentOS Linux release 7.4.1708 (开发云主机域名Core)[root@localhost ~]#关闭防火墙[root@localhost ~]# systemctl stop firewalld.service[root@localhost ~]#[root@localhost ~]# systemctl disable firewalld.serviceRemoved symlink /etc/systemd/system/multi-user.target.wants/firewalld.service.Removed symlink /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service.查看防火墙[root@localhost ~]#[root@localhost ~]# systemctl status firewalld.service● firewalld.service – firewalld – dynamic firewall daemon Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; v活动:慈云数据爆款香港服务器,CTG+CN2高速带宽、快速稳定、平均延迟10+ms 速度快,免备案,每月仅需19元!! 点击查看endor preset: enabled) Active: inactive (dead) Docs: man:firewalld(1)Nov 27 00:52:26 localhost.localdomain systemd[1]: Starting firewalld – dynamic firewall daemon…Nov 27 00:52:26 localhost.localdomain systemd[1]: Started firewalld – dynamic firewall daemon.Nov 27 00:52:27 localhost.localdomain firewalld[828]: WARNING: ICMP type ‘beyond-scope’ is not supported by the kernel for ipv6.Nov 27 00:52:27 localhost.localdomain firewalld[828]: WARNING: beyond-scope: INVALID_ICMPTYPE: No supported ICMP type., ignoring for run-time.Nov 27 00:52:27 localhost.localdomain firewalld[828]: WARNING: ICMP type ‘failed-policy’ is not supported by the kernel for ipv6.Nov 27 00:52:27 localhost.localdomain firewalld[828]: WARNING: failed-policy: INVALID_ICMPTYPE: No supported ICMP type., ignoring for run-time.Nov 27 00:52:27 localhost.localdomain firewalld[828]: WARNING: ICMP type ‘reject-route’ is not supported by the kernel for ipv6.Nov 27 00:52:27 localhost.localdomain firewalld[828]: WARNING: reject-route: INVALID_ICMPTYPE: No supported ICMP type., ignoring for开发云主机域名 run-time.Nov 27 01:15:45 localhost.localdomain systemd[1]: Stopping firewalld – dynamic firewall daemon…Nov 27 01:15:47 localhost.localdomain systemd[1]: Stopped firewalld – dynamic firewall daemon.[root@localhost ~]#[root@localhost ~]#配置YUM源[root@localhost ~]# vi /etc/yum.conf[centosdvd]name=centosdvdbaseurl=file:///mntenabled=1gpgcheck=0[main]cachedir=/var/cache/yum/$basearch/$releaseverkeepcache=0debuglevel=2logfile=/var/log/yum.logexactarch=1obsoletes=1gpgcheck=1plugins=1installonly_limit=5bugtracker_url=http://bugs.centos.org/set_project.php?project_id=23&ref=http://bugs.centos.org/bug_report_page.php?category=yumdistroverpkg=centos-release# This is the default, if you make this bigger yum won’t see if the metadata# is newer on the remote and so you’ll “gain” the bandwidth of not having to# download the new metadata and “pay” for it by yum not having correct# information.# It is esp. important, to have correct metadata, for distributions like# Fedora which don’t keep old packages around. If you don’t like this checking# interupting your command line usage, it’s much better to have something# manually check the metadata once an hour (yum-updatesd will do this).# metadata_expire=90m# PUT YOUR REPOS HERE OR IN separate files named file.repo# in /etc/yum.repos.d备份系统自带YUM[root@localhost ~]#[root@localhost ~]#yum/ yum.conf yum.repos.d/[root@localhost ~]# mkdir -p /etc/yum.repos.d/bak20181127[root@localhost ~]# [root@localhost ~]# mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/bak20181127/[root@localhost ~]#[root@localhost ~]# ls -l /etc/yum.repos.d/total 0drwxr-xr-x. 2 root root 187 Nov 27 01:17 bak20181127[root@localhost ~]#挂接系统镜像文件[root@localhost ~]# mkdir -p /mnt[root@localhost ~]#[root@localhost ~]# mount -o loop /soft/CentOS-7.4-x86_64-Everything-1708.iso /mnt/mount: /dev/loop0 is write-protected, mounting read-only[root@localhost ~]#清除YUM缓存[root@localhost ~]# yum clean allLoaded plugins: fastestmirrorCleaning repos: centosdvdCleaning up everythingMaybe you want: rm -rf /var/cache/yum, to also free up space taken by orphaned data from disabled or removed repos[root@localhost ~]#制作YUM缓存[root@localhost ~]# yum makecacheLoaded plugins: fastestmirrorcentosdvd | 3.6 kB 00:00:00 (1/4): centosdvd/group_gz | 156 kB 00:00:00 (2/4): centosdvd/primary_db | 5.7 MB 00:00:00 (3/4): centosdvd/filelists_db | 6.7 MB 00:00:00 (4/4): centosdvd/other_db | 2.5 MB 00:00:00 Determining fastest mirrorsMetadata Cache Created[root@localhost ~]#查看YUM[root@localhost ~]# yum listLoaded plugins: fastestmirrorLoading mirror speeds from cached hostfileInstalled PackagesGeoIP.x86_64 1.5.0-11.el7 @anacondaNetworkManager.x86_64 1:1.8.0-9.el7 @anacondaNetworkManager-libnm.x86_64 1:1.8.0-9.el7 @anacondaNetworkManager-team.x86_64 1:1.8.0-9.el7 @anacondaNetworkManager-tui.x86_64 1:1.8.0-9.el7 @anacondaNetworkManager-wifi.x86_64 1:1.8.0-9.el7 @anacondaacl.x86_64 2.2.51-12.el7 @anacondaaic94xx-firmware.noarch 30-6.el7 @anacondaalsa-firmware.noarch 1.0.28-2.el7 @anacondaalsa-lib.x86_64 1.1.3-3.el7 @anacondaalsa-tools-firmware.x86_64 1.1.0-1.el7 @anacondaaudit.x86_64 2.7.6-3.el7 @anacondaaudit-libs.x86_64 2.7.6-3.el7 @anacondaauthconfig.x86_64 6.2.8-30.el7 开发云主机域名 @anacondabasesystem.noarch 10.0-7.el7.centos @anacondabash.x86_64 4.2.46-28.el7 @anacondabind-libs-lite.x86_64 32:9.9.4-50.el7 @anacondabind-license.noarch 32:9.9.4-50.el7 @anacondabinutils.x86_64 2.25.1-31.base.el7 @anacondabiosdevname.x86_64 0.7.2-2.el7 @anaconda…………………………………………………………省略…………………………………………………………………………………………………zsh-html.x86_64 5.0.2-28.el7 centosdvdzziplib.i686 0.13.62-5.el7 centosdvdzziplib.x86_64 0.13.62-5.el7 centosdvdzziplib-devel.i686 0.13.62-5.el7 centosdvdzziplib-devel.x86_64 0.13.62-5.el7 centosdvdzziplib-utils.x86_64 0.13.62-5.el7 centosdvd[root@localhost ~]#[root@localhost ~]# ifconfig -aens33: flags=4163
mtu 1500
inet 192.168.95.11 netmask 255.255.255.0 broadcast 192.168.95.255 inet6 fe80::56ae:158f:89dd:b662 prefixlen 64 scopeid 0x20 ether 00:0c:29:df:9e:6b txqueuelen 1000 (Ethernet) RX packets 37952144 bytes 11893770589 (11.0 GiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 11114198 bytes 790613626 (753.9 MiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0lo: flags=73
mtu 65536
inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1 (Local Loopback) RX packets 448 bytes 38976 (38.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 448 bytes 38976 (38.0 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0安装telnet服务并启用因升级OpenSSH过程中需要卸载现有OpenSSH, 因此为了保持服务器的远程连接可用,需要启用telnet服务作为替代,如升级出现问题,也可通过telnet登录服务器进行回退。同时安装telnet守护进程:xinetd安装telnet服务[root@localhost ~]#[root@localhost ~]# yum install telnet* xinetd yLoaded plugins: fastestmirrorLoading mirror speeds from cached hostfileResolving Dependencies–> Running transaction check—> Package telnet.x86_64 1:0.17-64.el7 will be installed—> Package xinetd.x86_64 2:2.3.15-13.el7 will be installed—> Package telnet-server.x86_64 1:0.17-64.el7 will be installed–> Finished Dependency ResolutionDependencies Resolved================================================================================================================================================================Package Arch Version Repository Size================================================================================================================================================================Installing:telnet-server x86_64 1:0.17-64.el7 centosdvd 41 kDependencies Resolved================================================================================================================================================================Package Arch Version Repository Size================================================================================================================================================================Installing:telnet x86_64 1:0.17-64.el7 centosdvd 64 kxinetd x86_64 2:2.3.15-13.el7 centosdvd 128 kTransaction Summary================================================================================================================================================================Install 3 PackagesTotal download size: 192 kInstalled size: 374 kIs this ok [y/d/N]: yDownloading packages:————————————————————————————————————————————————————–Total 1.5 MB/s | 192 kB 00:00:00 Running transaction checkRunning transaction testTransaction test succeededRunning transaction Installing : 2:xinetd-2.3.15-13.el7.x86_64 1/2 Installing : 1:telnet-0.17-64.el7.x86_64 Installing : 3:telnet-server-0.17-64.el7.x86_64 1/1 Verifying : 3:telnet-server-0.17-64.el7.x86_64 2/2 Verifying : 1:telnet-0.17-64.el7.x86_64 1/2 Verifying : 2:xinetd-2.3.15-13.el7.x86_64 2/2Installed: telnet.x86_64 1:0.17-64.el7 &
本文从转载,原作者保留一切权利,若侵权请联系删除。
《天环境下Openssh-7.9p1升级以及系统调优》来自互联网同行内容,若有侵权,请联系我们删除!
还没有评论,来说两句吧...