Latest Entries »

PES2020手游刷熟练度教练列表

管理值 阵型 姓名 国籍
750 4231 拉斯洛*伯勒尼 罗马尼亚
730 532 马里乌斯*舒穆迪卡 罗马尼亚
730 4222 艾库特*科贾曼 土耳其
720 4213 伯纳德*沙朗德 瑞士
720 433 卡莱*英厄布里格森 挪威
710 3223 贝尼亚特*圣何塞 西班牙
700 3232 安德烈*加斯帕尔 巴西
700 433 马克*布里斯 比利时
700 4231 埃罗尔*布卢特 土耳其
700 4321 肯特*涅尔森 丹麦
690 4222 金钟夫 韩国
690 4231 迪奥尼西奥*博松 阿根廷
690 4321 胡利奥*里瓦斯 乌拉圭
690 4312 罗伯托*文图拉托 意大利
690 5212 哈基姆*沙克尔 伊拉克
680 4222 热尔松*古斯芒 巴西
670 4321 贝恩德*霍勒巴赫 德国
670 4231 伊斯梅尔*卡塔尔 土耳其
660 4231 胡伦*皮纳塔尔 哥伦比亚
660 4231 阿德里安*洛伦索 哥伦比亚
650 433 克里斯蒂安*尼尔森 丹麦
640 433 彼得*瑟伦森 丹麦
600 3232 赫尔曼*科明 罗马尼亚
600 5221 素拉蓬I*空贴 泰国
590 4231 巴勇*坤南 泰国
580 3241 差萨克*西里普姆 泰国

先试更改用户所有者
takeown /f 111/ /r /a

再试授权
icacls 111/ /grant “administrators:(f)" /t /c

然后就可以完全删掉了。

Centos7安装openmeetings4

vi /etc/selinux/config
selinux=disable

# epel repo
yum install -y epel-release

# rpmfusion repo
sudo yum localinstall –nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-7.noarch.rpm https://download1.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-7.noarch.rpm

# nux repo
rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm

# Adobe repo 64-bit x86_64 For Flash player
rpm -ivh http://linuxdownload.adobe.com/adobe-release/adobe-release-x86_64-1.0-1.noarch.rpm
rpm –import /etc/pki/rpm-gpg/RPM-GPG-KEY-adobe-linux

# JDK11. icedtea-web for can access to record and share desktop
yum install -y java-11-openjdk-devel icedtea-web wget

# 选择JDK版本
update-alternatives –config java

# OpenMeetings will need LibreOffice to convert to pdf the uploaded office files
yum -y install libreoffice libreoffice-headless

# Installation of Ghostscript, necessary packages and libraries
yum install -y ghostscript libjpeg libjpeg-devel freetype freetype-devel unzip gcc gcc-c++ ncurses ncurses-devel make zlib zlib-devel libtool bison bison-devel openssl-devel bzip2 bzip2-devel file-roller git autoconf automake pkgconfig tomcat-native nmap vlc

# ImageMagick, work the images files jpg, png, gif. Sox, work the sound
yum install -y ImageMagick sox giflib giflib-devel giflib-utils

# OpenMeetings even need Adobe Flash Player for cam and audio
yum install -y flash-plugin

# FFmpeg work with video
yum install -y glibc alsa-lib-devel faac faac-devel faad2 faad2-devel gsm gsm-devel imlib2 imlib2-devel lame-devel vorbis-tools theora-tools libvpx-devel vlc autoconf automake cmake freetype-devel gcc gcc-c++ git libtool make mercurial pkgconfig zlib-devel curl

# Installation MariaDB data server
yum install -y mariadb-server
# 启动,设置
systemctl start mariadb.service
mysqladmin -u root password YOUR-password
mysql -u root -p
# create a user with all permission on this meetdb database. name of the database:meetdb; user for that database:meetuser; password of that user:meetuser
> CREATE DATABASE meetdb DEFAULT CHARACTER SET ‘utf8’;
> CREATE USER meetuser;
> GRANT ALL PRIVILEGES ON meetdb.* TO ‘meetuser’@’localhost’ IDENTIFIED BY ‘1a2B3c4D’ WITH GRANT OPTION;
> FLUSH PRIVILEGES;
> \q

# Installation of OpenMeetings
mkdir /opt/meeting
cd /opt/meeting
wget http://archive.apache.org/dist/openmeetings/4.0.10/bin/apache-openmeetings-4.0.10.tar.gz
tar xzvf apache-openmeetings-4.0.10.tar.gz
mv apache-openmeetings-4.0.10.tar.gz /opt

# Download and install the connector between OpenMeetings and MariaDB:
cd /opt
wget https://repo1.maven.org/maven2/mysql/mysql-connector-java/5.1.48/mysql-connector-java-5.1.48.jar
cp /opt/mysql-connector-java-5.1.48.jar /opt/meeting/webapps/openmeetings/WEB-INF/lib

# Script to launch red5-OpenMeetings
cd /opt
wget https://cwiki.apache.org/confluence/download/attachments/27838216/red5-2
cp red5-2 /etc/init.d/
chmod +x /etc/init.d/red5-2
vi /etc/init.d/red5-2
RED5_HOME=/opt/red54010
…to
RED5_HOME=/your-path-installation

# Run red5-OpenMeetings
systemctl restart mariadb.service
/etc/init.d/red5-2 start

# go with your browser to:
http://localhost:5080/openmeetings

# 配置openmeetings
打开的网页,下一步,
第2页配置 Choose DB type to MySQL
mysql
localhost
3306
meetdb
meetuser
your-password
第3页,创建管理员用户
第4页,下一步,
第5页,配置IMAGEMAGICK,FFMPEG,SOX,LIBREOFFICE路径
ImageMagick Path == /usr/bin
FFMPEG Path == /usr/bin
FFMPEG Path == /usr/bin
OpenOffice/LibreOffice Path for
jodconverter == /usr/lib64/libreoffice
第6页,下一步,
第7页,Finish
# 重启应用
/etc/init.d/red5-2 restart
第8页,Enter the Application

# 防火墙开启如下端口
1935 5080

=========================
# 编译安装Ghostscript 9.27
cd /opt
wget https://cwiki.apache.org/confluence/download/attachments/27838216/ghostscript.sh
chmod +x ghostscript.sh
…and run it:
./ghostscript.sh
…when be finished will announce it: GhostScript compilation is Finished!
rm -Rf /opt/ghostscript-9.27

# 编译安装SOX
wget http://ftp.icm.edu.pl/packages/sox/14.4.2/sox-14.4.2.tar.gz
tar xzvf sox-14.4.2.tar.gz
cd /opt/sox-14.4.2
./configure
make && make install
cd /op

# 编译安装FFMPEG
https://trac.ffmpeg.org/wiki/CompilationGuide/Centos
cd /opt
wget https://cwiki.apache.org/confluence/download/attachments/27838216/ffmpeg_centos7.sh
…concede execution permission to it:
chmod +x ffmpeg_centos7.sh
…and run it (be connected to Internet). The compilation will spend about 30 minutes:
./ffmpeg_centos7.sh
All the compiled files will be installed in: /usr/local/bin

windows打补丁后无法引导

针对挂起补丁进行清理卸载去除:
dism /image:e:\ /cleanup-image /revertpendingactions

查看挂起的补丁:
dism /image:e:\ /get-packages /format:table

卸载某补丁:
32位系统:
dism /Image:C:\ /Remove-Package /PackageName:Package_for_KB3146706~31bf3856ad364e35~x86~~6.1.1.2

64位系统:
dism /Image:C:\ /Remove-Package /PackageName:Package_for_KB3146706~31bf3856ad364e35~amd64~~6.1.1.2

一、环境介绍
UEFI-GPT
arch linux
/dev/sdb

BIOS-MBR
win7
/dev/sda

二、GHOST WIN7后现象:
ARCH LINUX已无法引导,无法找到系统。哪怕是把安装WIN7的SATA硬盘禁用掉,ARCH LINUX也无法引导启动。
WIN7系统无论从哪块硬盘都可以引导启动。(非常奇怪。GHOST的时候是在BIOS里面禁用ARCH LINUX所在SATA硬盘的)

三、排错过程
1、用ARCH LINUX安装U盘引导UEFI模式,进入arch emergency shell
查看磁盘分区信息
lsblk -f
直接挂载
mount /dev/sdb3 new_root
mount /dev/sdb1 /boot
安装GRUB
grub-install –target=x86_64-efi –efi-directory=/boot –bootloader-id=GRUB
grub-mkconfig -o /boot/grub/grub.cfg

2、如果进入的是GRUB>提示符模式,请按如下操作恢复引导
find (hd1,0)/vmlinuz-(找到内核所在分区。按TAB键补齐命令,若能补齐命令,则内核在此分区)
root (hd1,0)
kernel /vmlinuz-按TAB键补齐命令
initrd /initramfs-按TAB键补齐命令
boot
或者
set root=(hd1,2)
linux (hd1,0)/vmlinuz-按TAB键补齐命令 root=/dev/sdb3
initrd (hd1,0)/initramfs-按TAB键补齐命令
boot

进入系统后
查看磁盘分区信息
lsblk -f
mount /dev/sdb3 /mnt/
mount /dev/sdb1 /mnt/boot
arch-chroot /mnt
重装GRUB
grub-install –target=x86_64-efi –efi-directory=/boot –bootloader-id=GRUB
grub-mkconfig -o /boot/grub/grub.cfg
reboot

—————-
错误的步骤:
EASYbcd安装WINPE双系统引导程序
a、添加新条目——操作系统——LINUX/BSD——添加条目
b、编辑引导菜单——USE METRO BOOTloader(去掉打勾选项)——保存设置
重启电脑,卡在GRUB>提示符,因为BIOS未强制使用UEFI引导,所以efivar-tester的时候报错UEFI variables not supported on this machine
截止此处已无解。毕竟ARCH LINUX是在UEFI+GTP下面安装使用的,而WINDOWS是BIOS+MBR。

===========================
PS:创建ARCH安装U盘
1、找到U盘的盘符
lsblk -f
2、若U盘自动挂载了,请卸载
umount /xxx/udisk
3、做启动U盘
sudo dd bs=4M if=/home/xxx/Downloads/archlinux-2020.02.01-x86_64.iso of=/dev/sdc status=progress && sync

————-
BTW:双系统引导菜单
所有版本的 Windows 都不支持 BIOS 引导 GPT 分区上的 Windows 或 UEFI 引导 MBR 分区上的 Windows.目前官方 (Microsoft) 没有在 UEFI-MBR 或 BIOS-GPT 上运行 Windows 的方法.因此 Windows 只支持 UEFI-GPT 或 BIOS-MBR 启动.参阅 http://support.microsoft.com/kb/2581408
安装在 BIOS 模式下的 Arch Linux 的启动管理器也无法加载位于另一个 UEFI-GPT 硬盘上的 Windows.反之亦然

win7菜单引导archlinux
arch linux shell
dd if=/dev/sdb1 of=/mnt/archboot.bin bs=512 count=1

win7 cmd
新建启动菜单,生成{ID}
bcdedit /create /d “arch” /application bootsector
bcdedit /set {ID} device partition=c:
bcdedit /set {ID} path c:\archboot.bin
加入启动菜单
bcdedit /displayorder {ID} /addlast
bcdedit /timeout 3
删除启动菜单项
bcdedit /delete {ID}

————-
若想ARCH自动生产GRUB双系统引导菜单,就使用如下命令
pacman -S os-prober
mount /dev/sda1 /mnt
os-prober
grub-mkconfig -o /boot/grub/grub.cfg

若不想安装os-prober,那么就直接编辑GRUB菜单
vi /boot/grub/custom.cfg

if [ “${grub_platform}" == “pc" ]; then
menuentry “Microsoft Windows Vista/7/8/8.1/10 BIOS/MBR" {
insmod part_msdos
insmod ntfs
insmod ntldr
search –no-floppy –fs-uuid –set=root –hint-bios=hd0,msdos1 –hint-efi=hd0,msdos1 –hint-baremetal=ahci0,msdos1 XXXXXXXXXXXXXXXX
ntldr /bootmgr
}
fi

XXXXXXXXXXXXXXXX是指文件系统的 UUID,可以通过 lsblk –fs 命令查看,或者用blkid查看

grafana与prometheus安装部署

1、prometheus安装
# 新建用户,下载GO语言的2进制执行软件包
useradd prometheus; passwd prometheus
wget https://github.com/prometheus/prometheus/releases/download/v2.15.2/prometheus-2.15.2.linux-amd64.tar.gz
wget https://github.com/prometheus/node_exporter/releases/download/v0.18.1/node_exporter-0.18.1.linux-amd64.tar.gz
tar -xvzf prometheus*.tar.gz
tar -xvzf node_exporter*.tar.gz

# 编辑监控本机自启动配置文件
vi /etc/systemd/system/node_exporter.service
[Unit]
Description=Node Exporter
Wants=network-online.target
After=network-online.target

[Service]
User=prometheus
Group=prometheus
Type=simple
ExecStart=/home/prometheus/node_exporter/node_exporter

[Install]
WantedBy=multi-user.target

# 设置成为自启动
systemctl enable node_exporter

————————-
# 文件尾部添加node_exporter本机监控模块
vi home/prometheus/prometheus.yml
– job_name: ‘node_exporter’
scrape_interval: 15s
static_configs:
– targets: [‘localhost:9100’]

# 编辑时序DB自启动配置文件
vi /etc/systemd/system/prometheus.service
[Unit]
Description=Prometheus Monitoring
Wants=network-online.target
After=network-online.target

[Service]
User=prometheus
Group=prometheus
Type=simple
ExecStart=/home/prometheus/prometheus/prometheus \
–config.file /home/prometheus/prometheus/prometheus.yml \
–storage.tsdb.path /home/prometheus/prometheus/ \
–web.console.templates=/home/prometheus/prometheus/consoles \
–web.console.libraries=/home/prometheus/prometheus/console_libraries
ExecReload=/bin/kill -HUP $MAINPID

[Install]
WantedBy=multi-user.target

# 设置成为自启动
systemctl enable prometheus

2、安装Grafana
# 编辑源
vi /etc/yum.repos.d/grafana.repo
[grafana]
name=grafana
baseurl=https://packages.grafana.com/oss/rpm
repo_gpgcheck=1
enabled=1
gpgcheck=1
gpgkey=https://packages.grafana.com/gpg.key
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt

# 在线安装
yum install grafana

# 设置成为自启动
systemctl enable grafana-server.service

# 添加数据源
点击Grafana logo打开侧边栏
点击 “Data Sources”
选择 “Add New”
选择 “Prometheus” 作为数据源
设置Prometheus服务的URL (例如本机: http://localhost:9090/)
点击 “Add” 测试连通性并保存数据源

pacman使用技巧

查询已安装的软件包
pacman -Qs

显示软件包的详尽的信息
pacman -Si

获取已安装软件包所包含文件的列表
pacman -Ql

查询远程库中软件包包含的文件
pacman -Fl

显示软件包的依赖树
pactree

检查一个安装的软件包被那些包依赖
whoneeds

检查一个安装的软件包被那些包依赖
whoneeds
pactree -r

清除未安装软件包的缓存,会保留软件包的当前有效版本
pacman -Sc

清理所有缓存。除非空间不足,否则不应这么做
pacman -Scc

默认会删除近3个版本前的软件包
paccache -r

下载包而不安装它
pacman -Sw

安装一个本地包(不从源里下载)
pacman -U /path/xxx.pkg.tar.xz

同步文件数据库
pacman -Fy
查询包含某个文件的包名
pacman -Fs pacman

将所有软件包按占用空间大小排序
expac -H M ‘%m\t%n’ | sort -h

递归删除孤立软件包
pacman -Rs $(pacman -Qtdq)
如果没有孤立软件包,将显示错误 error: no targets specified. 这个是正常的,因为 pacman -Rns 没有收到任何参数.

删除孤立软件包
pacman -Rns xxx

删除base软件包组以外的所有软件包
pacman -Rs $(comm -23 <(pacman -Qeq|sort) <((for i in $(pacman -Qqg base); do pactree -ul $i; done)|sort -u|cut -d ' ' -f 1))

避免过度清理缓存
vi /etc/pacman.conf的[options]段
CleanMethod = KeepCurrent

备份已安装软件包列表
comm -23 <(pacman -Qeq|sort) pkglist

安装列表中所有软件包
pacman -S $(< pkglist)

要是备份的软件包列表包含非官方软件包(从AUR或其他什么地方下载的),就得使用下面这个吓人的命令了,不然pacman会出错:
pacman -S –needed $(diff <(cat badpkglist|sort) <(diff <(cat badpkglist|sort) <(pacman -Slq|sort)|grep \<|cut -f2 -d' ')|grep \<|cut -f2 -d' ')

要是你的系统遭到了大规模破坏(比如rm -rf什么的),可以通过pacman重新安装所有软件包来挽救。
pacman -Qeq | pacman -S –
pacman -Qdq | pacman -S –asdeps –
如果安装了外来软件包,使用上面的命令会出错。下面的命令先生成所有软件包列表,再用pacman -Qmq剔除外来软件包,即重新安装所有仓库中可以找到的软件包,同时保留依赖安装、手动安装标志:
comm -23 <(pacman -Qeq) <(pacman -Qmq) | pacman -S –
comm -23 <(pacman -Qdq) “$db"

find /bin /etc /lib /sbin /usr \
! -name lost+found \
\( -type d -printf ‘%p/\n’ -o -print \) | sort > “$fs"

comm -23 “$fs" “$db"

要生成不属于任何软件包的文件列表:
pacman-disowned.sh > non-db.txt

递归删除孤立软件包:
pacman -Rs $(pacman -Qtdq)

列出所有不属于base或base-devel的已安装软件包
comm -23 <(pacman -Qeq|sort) <(pacman -Qgq base base-devel|sort)

———————–
回滚
cd /var/cache/pacman/pkg/
pacman -U networkmanager-qt-5.63.0-1-x86_64.pkg.tar.xz

以后不再更新此不稳定的软件组
vi /etc/pacman.conf
IgnoreGroup = networkmanager

添加第三方源
vi /etc/pacman.conf
[archlinuxcn]
Server = https://repo.archlinuxcn.org/$arch
倒入PGP密钥
sudo pacman -Syy && sudo pacman -S archlinuxcn-keyring

————————-
升级时遇到问题: "file exists in filesystem"(conflicting files)!
pacman -Qo 文件的完整路径 检查哪个软件包提供了文件

Signature from "User " is unknown trust, installation failed
更新已知密钥
pacman-key –refresh-keys
手动升级archlinux-keyring软件包
pacman -Sy archlinux-keyring && pacman -Su

“failed to commit transaction (invalid or corrupted package" 错误
find /var/cache/pacman/pkg/ -iname “*.part" -exec rm {} \;

“error: failed to init transaction (unable to lock database)" 错误
rm /var/lib/pacman/db.lck

升级系统重启后,出现"unable to find root device"错误,无法登陆
如果系统可以启动,运行如下命令可以生产原始内核 linux 的 initramfs:
# mkinitcpio -p linux
如果上面方法不行,请下载最新的安装程序进行启动,执行:
# mount /dev/sdxY /mnt #Your root partition.
# mount /dev/sdxZ /mnt/boot #If you use a separate /boot partition.
# arch-chroot /mnt
# pacman -Syu mkinitcpio systemd-tools linux
重新安装内核(linux 软件包)将会自动运行 mkinitcpio -p linux 重新生成 initramfs 镜像,不需要单独生成。
之后建议执行 exit, umount /mnt/{boot,} 然后 reboot.
Note: 如果无法进入 arch-chroot 或 chroot 环境,但是需要重新安装软件包,可以使用 pacman -r /mnt -Syu foo bar

PowerpillError: aria2c exited with 8
powerpill -Syyu

===========================
https://wiki.archlinux.org/index.php/Pacman
https://wiki.archlinux.org/index.php/Pacman/Tips_and_tricks

CentOS7部署PXE服务器

1、安装必须的软件包
yum -y install httpd xinetd syslinux tftp-server system-config-kickstart dhcp

2、将LINUX和ESXI的ISO镜像拷贝进/mnt/iso目录
mkdir -p /mnt/iso

3、挂载去apache里展示的目录
mkdir -p /var/www/html/centos75
mkdir -p /var/www/html/esxi67u3a
mkdir -p /var/www/html/clonezilla264
mkdir -p /var/www/html/gparted1005
mkdir -p /var/www/html/ks
mount -o loop /mnt/iso/CentOS-7-x86_64-DVD-1804.iso /var/www/html/centos75
mount -o loop /mnt/iso/VMware-VMvisor-Installer-6.7.0.update03-14320388.x86_64.iso /var/www/html/esxi67u3a
mount -o loop /mnt/iso/clonezilla-live-2.6.4-10-amd64.iso /var/www/html/clonezilla264
mount -o loop /mnt/iso/gparted-live-1.0.0-5-amd64.iso /var/www/html/gparted1005

4、创建PXE启动目录
mkdir /var/lib/tftpboot/pxelinux.cfg
cd /var/lib/tftpboot/pxelinux.cfg
mkdir centos75
mkdir esxi67u3a
mkdir clonezilla264
mkdir gparted1005
mkdir partedmagic2013
cp /usr/share/syslinux/{pxelinux.0,gpxelinux.0} /var/lib/tftpboot/
cp /var/www/html/centos75/isolinux/vesamenu.c32 /var/lib/tftpboot/
cp /var/www/html/centos75/isolinux/{vmlinuz,initrd.img} /var/lib/tftpboot/centos75/
cp /var/www/html/centos75/isolinux/isolinux.cfg /var/lib/tftpboot/pxelinux.cfg/default
cp /var/www/html/esxi67u3a/efi/boot/{boot.cfg,bootx64.efi} /var/lib/tftpboot/esxi67u3a/
ln -s /var/www/html/esxi67u3a/efi/boot/bootx64.efi /var/www/html/esxi67u3a/efi/boot/mboot.efi
cp /var/www/html/esxi67u3a/mboot.c32 /var/lib/tftpboot/esxi67u3a/
cp /var/www/html/clonezilla264/live/{vmlinuz,initrd.img} /var/lib/tftpboot/clonezilla264/
cp /var/www/html/gparted1005/live/{vmlinuz,initrd.img} /var/lib/tftpboot/gparted1005/
cp /mnt/iso/pmagic_2013_06_14_i586.iso /var/lib/tftpboot/partedmagic2013
mkdir -p /tmp/iso
mount /mnt/iso/pmagic_2013_06_14_i586.iso /tmp/iso
cp /tmp/iso/boot/syslinux/memdisk /var/lib/tftpboot/partedmagic2013

5、编辑启动文件
vi /var/lib/tftpboot/pxelinux.cfg/default
label 1
menu label ^Install CentOS 7.5mini
menu default
kernel centos75/vmlinuz
append initrd=centos75/initrd.img ks=http://172.16.10.1/ks/centos75.cfg

label 2
menu label ^Install esxi67u3a
kernel esxi67u3a/mboot.c32
append -c esxi67u3a/boot.cfg
ipappend 2

label 3
MENU LABEL Clonezilla Live
kernel clonezilla264/vmlinuz
append initrd=lonezilla264/initrd.img boot=live union=overlay live-config noswap nolocales edd=on nomodeset ocs_live_run="ocs-live-general" ocs_live_extra_param="" keyboard-layouts= ocs_live_batch="no" locales= vga=788 nosplash fetch=http://172.16.10.1/clonezilla264/live/filesystem.squashfs

label 4
menu label Parted Magic
#kernel partedmagic2013/bzImage
#append initrd=partedmagic2013/initrd.img fetch=http://172.16.10.1/partedmagic2013/pmagic/pmodules/PMAGIC_2013_06_14.SQFS
linux partedmagic2013/memdisk
initrd partedmagic2013/pmagic_2013_06_14_i586.iso
append iso

label 5
MENU LABEL GParted Live
kernel gparted1005/vmlinuz
append initrd=gparted1005/initrd.img boot=live config components union=overlay username=user noswap noeject ip= vga=788 fetch=http://172.16.10.1/gparted1005/live/filesystem.squashfs

# 去掉boot.cfg里面的/符号
sed -i ‘s/\///g’ /var/lib/tftpboot/esxi67u3a/boot.cfg

修改vsphere网络安装需要的引导内容
vi /var/lib/tftpboot/esxi67u3a/boot.cfg
prefix=http://172.16.10.1/esxi67u3a
kernelopt=ks=http://172.16.10.1/ks/esxi67u3a.cfg

6、开启tftp
vi /etc/xinetd.d/tftp
将disable = yes 改成 no

7、配置DHCP,使用 HTTP (IPv4) 引导。例如PXE服务器IP为172.16.10.1
cp /usr/share/doc/dhcp-4.2.5/dhcpd.conf.example /etc/dhcp/dhcpd.conf
vi /etc/dhcp/dhcpd.conf
default-lease-time 600;
max-lease-time 7200;
subnet 172.16.10.0 netmask 255.255.255.0 {
range 172.16.10.100 172.16.60.200;
option domain-name-servers 172.16.10.1;
option domain-name “localhost.local";
option routers 172.16.10.1;
option broadcast-address 172.16.10.255;
allow booting;
allow bootp;
option client-system-arch code 93 = unsigned integer 16;
class “pxeclients" {
match if substring(option vendor-class-identifier, 0, 9) = “PXEClient";
next-server 172.16.10.1;
if option client-system-arch = 00:07 or option client-system-arch = 00:09 {
if exists user-class and option user-class = “iPXE" {
# Instruct iPXE to load mboot.efi as secondary bootloader
filename = “mboot.efi";
} else {
# Load the snponly.efi configuration of iPXE as initial bootloader
filename = “snponly.efi";
}
} else {
filename “gpxelinux.0″;
}
}

8、配置Kickstart文件
vi /var/www/html/ks/entos75.cfg
#version=DEVEL
# X Window System configuration information
#xconfig –startxonboot
# License agreement
eula –agreed
# System authorization information
auth –enableshadow –passalgo=sha512
# Use CDROM installation media
#cdrom
# Use network installation
url –url="http://172.16.10.1/centos75″
# Use graphical install
graphical
# Run the Setup Agent on first boot
firstboot –enable
ignoredisk –only-use=sda
# Keyboard layouts
keyboard –vckeymap=cn –xlayouts=’cn’
# System language
lang zh_CN.UTF-8

# Network information
network –bootproto=dhcp –device=eth0 –onboot=on –ipv6=auto –no-activate
network –hostname=localhost.localdomain

# Root password
rootpw –iscrypted $6$N5iv1YnS1Y4rEIxd$pjbmVlcFmxX8oz81iF1VG71.g5QFZ2Yo4GPKkFFGjMbJ1
# System services
services –enabled="chronyd" –disable auditd,cups,atd
# 屏蔽selinux
selinux –disabled
# System timezone
timezone Asia/Shanghai –isUtc
# System bootloader configuration
bootloader –location=mbr –boot-drive=sda
autopart –type=lvm
# Partition clearing information
zerombr
clearpart –all –initlabel
# Disk partitioning information
#part /boot –fstype="xfs" –size=1024
#part pv.157 –fstype="lvmpv" –size=999999999 –grow
#volgroup centos –pesize=4096 pv.157
#logvol / –fstype="xfs" –size=99999999 –name=root –vgname=centos –grow
#logvol swap –fstype="swap" –size=8064 –name=swap –vgname=centos

%packages
@^minimal
@core
chrony
lrzsz
net-tools
sysstat

%end

%addon com_redhat_kdump –disable –reserve-mb=’auto’

%end

%anaconda
pwpolicy root –minlen=6 –minquality=1 –notstrict –nochanges –notempty
pwpolicy user –minlen=6 –minquality=1 –notstrict –nochanges –emptyok
pwpolicy luks –minlen=6 –minquality=1 –notstrict –nochanges –notempty
%end

—————–
vi /var/www/html/ks/esxi67u3a.cfg
# /etc/vmware/weasel/ks.cfg
# Accept the VMware End User License Agreement 按受VMware协议
vmaccepteula

# Set the root password for DCUI 设置密码sha512加密openssl passwd -1 yourPASSWORD
rootpw –iscrypted $6$N5iv1YnS1Y4rEIxd$pjb1VG71.g5QFZ2Yo4GPKkFFGjMbJ1

# Install on the first local disk available on machine 将ESXi安装在系统中的第一个磁盘上
install –firstdisk –overwritevmfs

# Set the keyboard
keyboard ‘US Default’

# Management Network Setting 配置IP地址
#network –bootproto=static –ip=192.168.0.22 –netmask=255.255.255.0 –gateway=192.168.0.1 –hostname=ESXi01 –nameserver=192.168.0.1 –addvmportgroup=1
network –bootproto=dhcp –device=vmnic0

# reboot the host after installation is completed
reboot

9、设置开机自动启动
systemctl enable {httpd,dhcpd,xinetd}

PS:
https://docs.vmware.com/cn/VMware-vSphere/6.7/com.vmware.esxi.install.doc/GUID-91E32FD0-A33C-4302-9FAB-B52B8A5CEFBC.html#GUID-91E32FD0-A33C-4302-9FAB-B52B8A5CEFBC

CentOS自动打重要安全补丁

# 安装自动打补丁软件
yum install yum-cron yum-plugin-security

————
CentOS7

vi /etc/yum/yum-cron.conf
# 只适用于风险级别Critical
update_cmd = minimal-security-severity:Critical
# 自动打补丁
apply_updates = yes
# 主机名
system_name = centos7
# 邮件发送源/收件人地址
email_from = root@localhost
email_to = root

systemctl enable yum-cron && systemctl start yum-cron

———–
CentOS6

vi /etc/sysconfig/yum-cron
# 只适用于风险级别Critical
YUM_PARAMETER="–sec-severity=Critical update-minimal"
# 邮件收件人
MAILTO=root
# 主机名
SYSTEMNAME= centos6

chkconfig yum-cron on && servie yum-cron start

====================
PS:
default 默认的更新,类似yum upgrade
security 安全更新, 类似yum –security upgrade
security-severity:Critical 重要的安全更新,类似yum –sec-severity=Critical upgrade
minimal 最小化更新,类似yum –bugfix update-minimal
minimal-security 最小化安全更新,类似yum –security update-minimal
minimal-security-severity:Critical 最小化重要安全更新,类似yum –sec-severity=Critical update-minimal

vi /etc/NetworkManager/NetworkManager.conf
[device]
wifi.scan-rand-mac-address=no

特别坑,莫名其妙的powerpill -Syu以后无线网卡就不停的尝试重连WIFI。只能换回有线网卡用,看报错日志,百思不得其解。原来是DEEPIN的BUG。

https://wiki.archlinux.org/index.php/Deepin_Desktop_Environment