Skip to content

Commit

Permalink
Update kernel version to 4.14.158
Browse files Browse the repository at this point in the history
  • Loading branch information
Yuk1n0 committed Dec 12, 2019
1 parent ee04f2b commit 3f6f9ca
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 12 deletions.
10 changes: 5 additions & 5 deletions Centos7/README.md
Expand Up @@ -9,20 +9,20 @@
```bash
wget --no-check-certificate https://raw.githubusercontent.com/Yuk1n0/Shadowsocks-Install/master/bbrplus-centos.sh && chmod +x bbrplus-centos.sh && ./bbrplus-centos.sh
```
安装后,执行uname -r,显示4.14.154则切换内核成功
安装后,执行uname -r,显示4.14.158则切换内核成功
执行lsmod | grep bbr,显示有tcp_bbrplus则开启成功

## 手动安装方法:
1. 卸载本机的锐速(如果有)

2. 下载内核
wget --no-check-certificate https://github.com/Yuk1n0/Shadowsocks-Install/raw/master/Centos7/x86_64/kernel-4.14.154.rpm
wget --no-check-certificate https://github.com/Yuk1n0/Shadowsocks-Install/raw/master/Centos7/x86_64/kernel-4.14.158.rpm

3. 安装内核
yum install -y kernel-4.14.154.rpm
yum install -y kernel-4.14.158.rpm

4. 切换启动内核
grub2-set-default 'CentOS Linux (4.14.154) 7 (Core)'
grub2-set-default 'CentOS Linux (4.14.158) 7 (Core)'

5. 设置fq
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
Expand All @@ -33,7 +33,7 @@ echo "net.ipv4.tcp_congestion_control=bbrplus" >> /etc/sysctl.conf
reboot

7. 检查内核版本 uname -r
显示4.14.154则成功
显示4.14.158则成功

8. 检查bbrplus是否已经启动
lsmod | grep bbrplus 显示有tcp_bbrplus则成功
Expand Down
Binary file not shown.
Binary file removed Centos7/x86_64/kernel-headers-4.14.154.rpm
Binary file not shown.
Binary file added Centos7/x86_64/kernel-headers-4.14.158.rpm
Binary file not shown.
10 changes: 5 additions & 5 deletions bbrplus-centos.sh
Expand Up @@ -7,7 +7,7 @@ red='\033[0;31m'
green='\033[0;32m'
yellow='\033[0;33m'
plain='\033[0m'
kernel_version="4.14.154"
kernel_version="4.14.158"

if [[ ! -f /etc/redhat-release ]]; then
echo -e "[${red}Error${plain}] Only support Centos..."
Expand All @@ -33,8 +33,8 @@ echo -e "[${green}Info${plain}] Downloading bbrplus kernel..."
wget --no-check-certificate https://github.com/Yuk1n0/Shadowsocks-Install/raw/master/Centos7/x86_64/kernel-${kernel_version}.rpm
wget --no-check-certificate https://github.com/Yuk1n0/shadowsocks-Install/raw/master/Centos7/x86_64/kernel-headers-${kernel_version}.rpm
echo -e "[${green}Info${plain}] Installing bbrplus kernel..."
yum install -y kernel-${kernel_version}.rpm kernel-headers-${kernel_version}.rpm
echo -e "[${green}Info${plain}] Installing bbrplus kernel complete..."
yum install -y kernel-headers-${kernel_version}.rpm
yum install -y kernel-${kernel_version}.rpm

#Check
list="$(awk -F\' '$1=="menuentry " {print i++ " : " $2}' /etc/grub2.cfg)"
Expand All @@ -55,13 +55,13 @@ rm -f kernel-${kernel_version}.rpm
rm -f kernel-headers-${kernel_version}.rpm

while true; do
read -p "bbrplus installation completed,reboot server now ? [Y/n] :" answer
read -p "bbrplus installation completed,reboot server now ? [Y/y] :" answer
[ -z "${answer}" ] && answer="y"
if [[ $answer == [Yy] ]]; then
echo -e "[${green}Info${plain}] Rebooting..."
break
else
echo -e "[${red}Error${plain}] Please enter [Y/n] !"
echo -e "[${red}Error${plain}] Please enter [Y/y] !"
echo
fi
done
Expand Down
5 changes: 3 additions & 2 deletions v2ray/v2ray-prepare.sh
Expand Up @@ -16,7 +16,7 @@ red='\033[0;31m'
green='\033[0;32m'
yellow='\033[0;33m'
plain='\033[0m'
kernel_version="4.19.154"
kernel_version="4.14.158"

[[ $EUID -ne 0 ]] && echo -e "[${red}Warning${plain}] This script must be run as root!" && exit 0

Expand Down Expand Up @@ -219,7 +219,8 @@ install_bbrplus() {
wget --no-check-certificate https://github.com/Yuk1n0/Shadowsocks-Install/raw/master/Centos7/x86_64/kernel-${kernel_version}.rpm
wget --no-check-certificate https://github.com/Yuk1n0/Shadowsocks-Install/raw/master/Centos7/x86_64/kernel-headers-${kernel_version}.rpm
echo -e "[${green}Info${plain}] Installing bbrplus Kernel..."
yum install -y kernel-${kernel_version}.rpm kernel-headers-${kernel_version}.rpm
yum install -y kernel-headers-${kernel_version}.rpm
yum install -y kernel-${kernel_version}.rpm
echo -e "[${green}Info${plain}] Installing bbrplus kernel complete..."

#Check
Expand Down

0 comments on commit 3f6f9ca

Please sign in to comment.