一个懒散的博客

Linux VPS一键安装锐速(LotServer)脚本,可与BBR共存

说明:最近萌咖大佬的锐速脚本更新了,支持的锐速版本差不多到最新的了,与之前的版本比较,修复了崩溃等众多问题,而且支持的内核更高了(包括4.9+内核),也就意味着我们在锐速和BBR之间切换安装的时候不需要重复更换内核了,貌似锐速和BBR还能共存,但博主感觉效果提升并不大,反而流量可能会爆增,具体的就需要人去探究了,这里只大概说下脚本。

安装

Github地址:https://github.com/MoeClub/lotServer
备份地址:https://github.com/iiiiiii1/LotServer

锐速目前支持的操作系统和内核查看→传送门

1、更换内核

#CentOS 6 32位系统更换内核为2.6.32-504.el6
rpm -ivh http://vault.centos.org/6.6/centosplus/i386/Packages/kernel-firmware-2.6.32-504.el6.centos.plus.noarch.rpm
rpm -ivh http://vault.centos.org/6.6/centosplus/i386/Packages/kernel-2.6.32-504.el6.centos.plus.i686.rpm --force

#CentOS 6 64位系统更换内核为2.6.32-504.3.3.el6.x86_64
rpm -ivh http://vault.centos.org/6.6/centosplus/x86_64/Packages/kernel-firmware-2.6.32-504.3.3.el6.centos.plus.noarch.rpm
rpm -ivh http://vault.centos.org/6.6/centosplus/x86_64/Packages/kernel-2.6.32-504.3.3.el6.centos.plus.x86_64.rpm --force

#CentOS 7系统更换内核为3.10.0-229.1.2.el7.x86_64
rpm -ivh http://dev.centos.org/c7.01.u/kernel/20150327030147/3.10.0-229.1.2.el7.x86_64/kernel-3.10.0-229.1.2.el7.x86_64.rpm --force

查看内核是否更换成功,使用命令:

rpm -qa | grep kernel

如果成功,重启VPS即可。

2、安装锐速

#常规自动安装
bash <(wget --no-check-certificate -qO- https://github.com/iiiiiii1/lotServer/raw/master/Install.sh) install

#指定内核安装
bash <(wget --no-check-certificate -qO- https://github.com/iiiiiii1/lotServer/raw/master/Install.sh) install <Kernel Version>

#完全卸载
bash <(wget --no-check-certificate -qO- https://github.com/iiiiiii1/lotServer/raw/master/Install.sh) uninstall

3、使用命令

#启动命令
/appex/bin/lotServer.sh start 

#状态查询
/appex/bin/lotServer.sh status

#停止加速
/appex/bin/lotServer.sh stop

#更新许可,使用ifconfig查看网卡mac地址,替换00:00:00:00:00:00 
wget -qO /appex/etc/apx.lic 'https://api.moeclub.org/lotServer?mac=00:00:00:00:00:00'

最后就说下Debian 9同时开启BBR和锐速的方法,但只建议随便玩玩。

更换内核:

#安装4.9.0-4-amd64内核
apt update
wget https://debian.sipwise.com/debian-security/pool/main/l/linux/linux-image-4.9.0-4-amd64_4.9.65-3+deb9u1_amd64.deb
dpkg -i linux-image-4.9.0-4-amd64*.deb
#查看所有内核
dpkg -l|grep linux-image
#卸载其他内核
apt-get purge <旧内核名称>
#内核更新
update-grub
#重启
reboot

安装锐速:

bash <(wget --no-check-certificate -qO- https://github.com/iiiiiii1/lotServer/raw/master/Install.sh) install 4.9.0-4-amd64

开启BBR

echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf
sysctl -p
赞(0)