autoDevops,CI,CD
CentOS7/RHEL7最小化安装系统并制作openssh8.4p1的RPM安装包使用rpmbuild将tar包打成rpm包,不喜欢编译升级的,使用RPM升级就方便多了。1,安装依赖环境[root@centos7-31 ~]#  yum install rpm-build zlib-devel openssl-devel gcc perl-devel pam-devel unzip -y[root@centos7-31 ~]#  mkdir -p /root/rpmbuild/{SOURCES,SPECS}[root@centos7-31 ~]#  cd /root/rpmbuild/SOURCES/2,下载相关软件。[root@centos7-31 ~]#  wget https://src.fedoraproject.org/repo/pkgs/openssh/x11-ssh-askpass-1.2.4.1.tar.gz/8f2e41f3f7eaa8543a2440454637f3c3/x11-ssh-askpass-1.2.4.1.tar.gz[root@centos7-31 ~]#    tar zxvf openssh-8.4p1.tar.gz[root@centos7-31 ~]#   cd openssh-8.4p1/3,修改源码包的ssh配置文件,以免系统中安装RPM后还要再修改配置文件。[root@centos7-31 ~]#   vi sshd_configPermitRootLogin yesPasswordAuthentication yes4,将pam信息写到源码包中。[root@centos7-31 ~]#    cat /etc/pam.d/sshd > contrib/redhat/sshd.pam[root@centos7-31 ~]# &nbs...
本文介绍使用Firewall进行端口转发。如果安装过iptables的机器,需要先停止,然后设置开机禁用:[root@localhost ~]#servcie iptables stop --临时关闭防火墙 [root@localhost ~]#chkconfig iptables off --永久关闭防火墙特别注意:请勿使用yum remove iptables来卸载防火墙,因为iptables附带了很多依赖文件,这样卸载会导致机器SSH丢失。安装firewall防火墙yum install firewalld -y设置开机自启systemctl enable --now firewalld开启路由转发echo 'net.ipv4.ip_forward = 1' >> /etc/sysctl.conf sysctl -p开启防火墙的流量伪装功能firewall-cmd --zone=public --permanent --add-masquerade开启TCP流量转发firewall-cmd --add-forward-port=port=8080:proto=tcp:toaddr=2.2.2.2:toport=666 --permanent #将本地8080端口,转发到2.2.2.2的tcp666端口。开启UDP流量转发firewall-cmd --add-forward-port=port=8080:proto=udp:toaddr=2.2.2.2:toport=666 --permanent #将本地8080端口,转发到2.2.2.2的udp666端口。重载配置文件firewall-cmd --reload如何开放端口?开启TCP流量端口firewall-cmd --add-port=8080/tcp --per...
Centos8/RHEL8系统使用nmcli与nmtui配置bridge桥接网卡 在系统中编译安装了qemu5.4-RISCV最新版本,但是模拟机网卡不能访问外网, 在eth1网卡上面配置一个桥接网卡,这样就比较方面了。 1,查看网卡设备信息。 [root@k8s-30 ~]# nmcli device showGENERAL.DEVICE:                         eth0GENERAL.TYPE:                           ethernetGENERAL.HWADDR:                         00:15:5D:5D:94:01GENERAL.MTU:                            1500GENERAL.STATE:      &n...
最近在帮一个研究生弄一个虚拟化环境下的基于Innodb的日志文件的读写优化的实验,实验的具体详细内容就不说了,其中有一个步骤需要将MySQL的日志文件放置在一块单独的硬盘里面,这块硬盘要么是ext2,要么是ext4,ext4的性能据说比前面的ext系列的要高,所以选择了ext4。但是ext4具备有日志的功能,如果开启了这个日志功能的话,到时又会有多个虚拟机同时跑,那么这个ext4的日志功能会对我们的实验数据产生一定的影响,并且我们在实验中并不需要到这个日志功能,所以需要将这个日志功能关闭。具体如下步骤:  下面的vda便是虚拟机所导入的硬盘,我们先对这个硬盘格式化一下: [root@centos7_vm_1 ~]# mkfs.ext4 /dev/vda  mke2fs 1.42.9 (28-Dec-2013) Filesystem label=OS type: Linux Block size=1024 (log=0) Fragment size=1024 (log=0) Stride=0 blocks, Stripe width=0 blocks65536 inodes, 262144 blocks13107 blocks (5.00%) reserved for the super user First data block=1Maximum filesystem ...
 
0

服务器RAID硬盘故障处理

发表者:admin分类:Devops2020-08-18 09:05:30 阅读[2020]
1. 写在前头2. 简介3. 硬盘故障处理流程3.1 故障定位及分析3.1.1 名词解释3.1.2 收集日志及阵列穿孔3.1.3 查看物理磁盘信息3.1.4 物理磁盘故障分析3.1.5 查看磁盘阵列信息3.1.6 磁盘阵列故障分析3.2 业务定位3.3 设备定位3.4 故障处理标签:PC服务器, 硬盘故障1. 写在前头一直以来都想写一些关于服务器硬盘维护的文档,但是由于各种原因,就一直搁置了。而且还有一个原因,我这语文不及格呢,语言该怎么组织?还想着找度娘学习借鉴一下高人写的文档,可惜都没找到我想要的,好吧不多扯,进入正题吧2. 简介大数据时代,如何保证数据安全性,显得更加重要。从简单的定期备份,到备份系统、到灾备解决方案等等,都是为了确保数据安全。而不论何种方案,都必须将数据存放在底层的物理设备(硬盘、磁带等),今天我们主要讲服务器硬盘故障时该如何维护。3. 硬盘故障处理流程一直以来都在一线处理各类设备故障,我把硬盘的故障流程整理成如下五个步骤,四个都缺一不可。故障定位及分析业务定位设备定位故障处理3.1 故障定位及分析3.1.1 名词解释- DSA :IBM日志收集工具- DSET :DELL日志收集工具- TTY :硬盘日志收集工具- Slot Number&n...
服务器RAID硬盘与日志主要检测方法1:对于 Dell 的机器并且配备了 LSI 的 raid 卡,那么 Megacli 自带的命令是最直观最可靠的硬盘检测方法。 #/opt/MegaRAID/MegaCli/MegaCli64 -pdlist -aall  以其中的一块硬盘为例。 Enclosure Device ID: 32  Slot Number: 2  Enclosure position: 0  Device Id: 2 //ID 号 Sequence Number: 2  Media Error Count: 0 // 如果 error 数值较多 , 那么需要更换硬盘 Other Error Count: 0  Predictive Failure Count: 0 // 可理解为预知性的错误 , 这个数值较多意味着硬盘即将坏 掉, 现场会黄绿灯交叉闪烁 Last Predictive Failure Event Seq Number: 0  PD Type: SAS  Raw Size: 136.732 GB [0x Sectors]  Non Coerced Size: 136.232 GB [0x Sectors]  Coerced Size: 136.125 GB [0x Sectors]  Firmware state: Online, Spun Up // 如 果 硬 盘 坏 了 那 么 会 出 现 Failed 或 者 是 unconfigured(bad) SAS Addres...
ubuntu18.04,ubuntu20.04 安装gnome-desktop桌面环境方法 Instructions Gnome Vanilla Installation on Ubuntu Gnome vanilla installation on Ubuntu 18.04 will leave you with a basic Gnome shell features and minimal pre-installed applications.To perform a vanilla installation of Gnome desktop execute the following linux command: sudo apt install gnome-session gdm3 ...
如何仅在 CentOS/RHEL 8 中使用 dnf 列出或安装安全更新问:是否可能限制 dnf 以便仅列出或安装安全更新?如何仅使用安全勘误表修补系统?本文介绍如何使用 CentOS/RHEL 8 上的 dnf 列出和安装安全更新。列出安全更新1. 列出有关已安装软件包的较新版本(默认) 的建议:# dnf updateinfo list --security或# dnf updateinfo list --security --available2. 要列出有关已安装软件包任何版本的建议:# dnf updateinfo list --security --all3. 要列出有关相同和较旧版本的已安装软件包的建议:# dnf updateinfo list --security --installed4. 根据严重性列出安全更新(严重、重要、中等、低):# dnf updateinfo list --security --sec-severity [Severity]安装安全更新1. 在更新中包括与安全相关的包:# dnf upgrade --security2. 在更新中包括修复给定咨询或建议所需的包:# dnf upgrade --advisory ELSA-xxxx-xxxx或# dnf upgrade --advisories ELSA-xxxx-xxxx,ELSA-yyyy-yyyy3....
How to add a Custom Script to systemd in CentOS/RHEL 7如何在CentOS / RHEL 7中将自定义脚本添加到systemdThe systemd facility replaces the older System-V initialization scripts from earlier releases. The systemd is an event-driven facility which allows non-dependent subsystems to be started, controlled, or stopped in parallel. Here we explain how to add a custom script to the systemd facility.1. Write And Debug The Custom ScriptTypically a systemd script is written as a shell script. Begin by writing your custom script using the normal conventions. We will call our script my-custom-script.sh and is straightforward:#!/bin/sh echo I am a custom script2. The script must be executableLets make the script executable:# chmod 0755 my-custom-script.sh3. Describe The Custom Script To systemdWith the script written and tested manually, the script is ready to be described to the systemd system. To do this, a [name].service file is needed. The syntax uses the INI format commonly used for configurat...
轻量级运维利器pssh、pdsh和mussh的使用以及区别 区别:pssh有5个程序 pssh:执行命令 pscp:上传文件 pslurp:下载文件到本机 prsync:将本地文件同步到远程主机  pnuke杀死远程主机的某个进程(如httpd) pdsh有两个方法:pdsh:执行命令,类似pssh,但增加了命令交互模式以及正则表达式,更灵活。pdcp:上传文件到远程主机,与pscp类似,但管理主机和远程主机都要安装pdsh包。 mussh:mussh:批量执行远程管理命令,主要是比pssh,pdsh增加了一个可执行脚本的功能。(shell,Perl,Python脚本)  指定的参数作用跟pssh 有很大区别。  原理:基于ssh秘钥认证建立信任,在本管理主机上运行pssh、pdsh和mussh工具命令将shell命令发送至管理远程主机(单主机或主机群),相当于登陆到远程主机上执行了同样的shell命令。由于条件限制,只有两台虚拟机,一台用于模拟管理,一台用于模拟远程主机。管理主机IP:192.168.1.106   (master1)远程主机IP:192.168.1.108   (master2) 一、在本地主机上创建RSA密钥和公钥。以本地普通用户soul用户登陆为例。本管理主机以及所有远程主机的普通账户密码均设置为s...
    总共67页,当前第7页 | 页数:
  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. 14
  15. 15
  16. 16
  17. 17